Visualizing FacetFESpace

More
2 years 7 months ago #4321 by alex.v
I am having trouble exporting a GridFunction from a FacetFESpace using VTKOutput.

I am calling it as:VTKOutput(ma=mesh,
coefs=[gfu],
names=,
filename='val').Do()

Where gfu is a GridFuntion on a FacetFESpace with some values on it.
What is the correct way to get this exported for visualization in Paraview?

Alex
More
2 years 7 months ago #4323 by walker_tr9
Replied by walker_tr9 on topic Visualizing FacetFESpace
You will need to extend the function to the bulk, then export that.  For example:

fes_BDY = FacetFESpace(mesh, order=0, definedon="", definedonbound=BDY_name)
gf_u_bdy = GridFunction(fes_BDY)
fes_BULK = H1(mesh, order=1)

gf_u_bdy_ext = GridFunction(fes_BULK)
gf_u_bdy_ext.Set(gf_u_bdy, definedon=mesh.Boundaries(BDY_name))

Then try:  Draw(gf_u_bdy_ext, mesh, "u_bdy_ext")   in the netgen gui.

If that works, then you could just export that.
Time to create page: 0.094 seconds