-
Notifications
You must be signed in to change notification settings - Fork 65
Initial implementation of support for complex fields #234
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
wrtobin
wants to merge
17
commits into
develop
Choose a base branch
from
wrt/complex
base: develop
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
17 commits
Select commit
Hold shift + click to select a range
e72dfe2
changing and adding underlying types, at a point where a decision nee…
c8ac116
adding complex field files and accomodating complex field freezing/un…
dc9324c
remove template function from API, add some type-checking to various …
1f09105
closing parenthesis, gotta squash this one for sure
246a843
enforcing a small amount of type safety to get/set calls in the API, …
80c1c68
adding an ElementBase class and an intermediate ElementT class simila…
07965d0
implementation of the initial complex fields API, including extension…
97a6412
quite a bit of work, reverting the type-checks on the API get/set fun…
b587a25
reverting accidental change of pField->apf::Field inside of pumi
91f67a9
adding apfComplexType.h to public interface
99423cc
adding new public headers to the pkg_tribits.cmake file
63744be
adding CMake option to determine compex type, C-complex is the defaul…
0b151f8
forgot a file
e8c761b
removing reference to an unneeded file not in the repo
5624ba1
fixing include issue caused by resolving unneeded intermediate file
3aa1ebe
addining a public header to the install list as it is needed downstream
a9ebda5
removing commented line of code, propogating the complex decision dow…
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,58 @@ | ||
#ifndef APFCOMPLEX_H_ | ||
#define APFCOMPLEX_H_ | ||
|
||
#include "apfComplexType.h" | ||
#include "apfElementType.h" | ||
|
||
namespace apf | ||
{ | ||
|
||
// forward decls for the interface | ||
class ComplexField; | ||
class Mesh; | ||
class FieldShape; | ||
class MeshEntity; | ||
class VectorElement; | ||
typedef VectorElement MeshElement; | ||
class Vector3; | ||
template <class T> | ||
class NewArray; | ||
|
||
ComplexField* createComplexPackedField(Mesh* m, | ||
const char* name, | ||
int components, | ||
FieldShape* shape = NULL); | ||
|
||
void freeze(ComplexField* f); | ||
void unfreeze(ComplexField* f); | ||
bool isFrozen(ComplexField* f); | ||
|
||
/** \brief Return the contiguous array storing this field. | ||
\details This function is only defined for fields | ||
which are using array storage, for which apf::isFrozen | ||
returns true. | ||
\note If the underlying field data type is NOT double_complex, | ||
this will cause an assert fail in all compile modes. | ||
*/ | ||
double_complex* getComplexArrayData(ComplexField * f); | ||
void zeroField(ComplexField* f); | ||
|
||
void setComponents(ComplexField* f, MeshEntity* e, int node, double_complex const * components); | ||
void getComponents(ComplexField* f, MeshEntity* e, int node, double_complex * components); | ||
|
||
ComplexElement* createElement(ComplexField* f, MeshElement* e); | ||
ComplexElement* createElement(ComplexField* f, MeshEntity* e); | ||
void destroyElement(ComplexElement* e); | ||
|
||
MeshElement* getMeshElement(ComplexElement* e); | ||
MeshEntity* getMeshEntity(ComplexElement* e); | ||
|
||
void getComponents(ComplexElement* e, Vector3 const& param, double_complex* components); | ||
int countNodes(ComplexElement* e); | ||
void getShapeValues(ComplexElement* e, Vector3 const& local, NewArray<double>& values); | ||
void getShapeGrads(ComplexElement* e, Vector3 const& local, NewArray<double>& grades); | ||
void getPackedNodes(ComplexElement* e, NewArray<double_complex>& values); | ||
wrtobin marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
||
} | ||
|
||
#endif |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.