Hi everyone,
I’m trying to implement a space-time HDG method but I’m having trouble specifying the space-time finite element space.
I’m trying the following:
# Define the finite element spaces
Vh = L2(mesh, order=space_order)
Mh = FacetFESpace(mesh, order=space_order)
tfe = ScalarTimeFE(time_order)
stV = tfe*Vh
stM = tfe*Mh
st_fes = FESpace([stV, stM])
# space-time grid function, space gridfunction and space-time trial and test functions
gf = GridFunction(st_fes)
print("created gfu")
u_last = CreateTimeRestrictedGF(gf, 1)
print("created u_last")
The last print that is obtained is “created gfu”, meaning that there is a problem in the creation of CreateTimeRestrictedGF. The error that arises is “Segmentation fault: 11”
Any hints on how to proceed? Attached is the full code that I’m working on.
adv-diff-hdg.py (4.8 KB)
Hi Joaquín, interesting, I think this might be one of the first instances where a FacetFESpace is combined with the Space-Time-FE framework of xfem. If it was just about the CreateTimeRestrictedGF statement, one could easily just create the GridFunction with GridFunction( … spatial space …) and then RestrictGFInTime later as you also do. But upon a first look, it seems to me that there is some more general issue with a spatial FacetFESpace inside a SpaceTimeFE (in files such as SpaceTimeFE[Space].*pp in xfem/spacetime there are some dynamic_casts performed and we might get mistakenly the nullpointer somewhere…) Would need to look at this with some more time… For the moment let me ask: Would it be interesting as well for you to consider a discretisation without a Space-Time FE containing a FacetFESpace such as plain DG? This might be more straightforward in the current software version. Best, Fabian
Hi Fabian,
Sadly, I am more interested in the possibility of using HDG methods instead of pure DG for space-time.
Best,
Joaquín
Ok, I see. We will put this on the list of feature requests for xfem, but it seems to me that due to the different data structures involved relating to surface / volume elements, the required changes would probably be more than just a few lines of bug fixes. There is also the alternative paradigm of implementing space-time methods for 2D in space + time as a spatial 3D problem, with time corresponding to e.g. z., which might be worth consideration depending on the scope of your computations.