Skip to content
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

Support variable order spaces #219

Open
rw-anderson opened this issue Feb 2, 2022 · 7 comments
Open

Support variable order spaces #219

rw-anderson opened this issue Feb 2, 2022 · 7 comments

Comments

@rw-anderson
Copy link
Contributor

A gridfunction on a p-refined space does not visualize properly - it appears the enriched elements show up as their original order. How difficult would it be to visualize a variable order space?

@tzanio tzanio changed the title variable order spaces Variable order spaces Feb 2, 2022
@tzanio tzanio changed the title Variable order spaces Support variable order spaces Feb 2, 2022
@dylan-copeland
Copy link

There is some code to deal with this, not in the main MFEM or glvis library, see ProlongToMaxOrder for example in miniapps/gslib/findpts.cpp:
https://github.com/mfem/mfem/blob/a96065ed1802ee95e7a33ee749b2ae4a6e4a6de6/miniapps/gslib/findpts.cpp#L46

@tzanio
Copy link
Member

tzanio commented Feb 2, 2022

Can we add this ☝️ to mfem proper and call it automatically in glvis when needed?

@dylan-copeland
Copy link

We thought about it in the recent PR mfem/mfem#2766 which added this code. This "experimental" function is for L2 or H1 spaces. It would need to be generalized for arbitrary spaces, so we would need to think about whether that can be done in general. If there are spaces (e.g. ND, RT) that do not work, we may need to check the type with MFEM_VERIFY to prevent misuse.

@rw-anderson
Copy link
Contributor Author

Projecting to max order seems like a workaround, but expensive if the space is highly locally enriched. Would rendering each element in its native order be too difficult?

@v-dobrev
Copy link
Member

v-dobrev commented Feb 2, 2022

The first issue is that FiniteElementSpace::Save (which is used to send data to GLVis) does not support variable orders yet -- it is probably not too hard to add this. This also needs to be supported in FiniteElementSpace::Load.

With these two methods implemented properly we can try GLVis and see if there are any issues there.

@kmittal2
Copy link

Did anyone tried making this work? cc: @rw-anderson @dylan-copeland
I need it for another project so figured I would check before I work on it.

@dylan-copeland
Copy link

@kmittal2 I am not aware of any work to support this, aside from ProlongToMaxOrder in miniapps/gslib/findpts.cpp, which has always worked for the examples I've seen so far but could be expensive for large enough meshes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants