Dear all,
I want to solve coupled equation for two function (u1, u2), one in 1D, the other one in 2D. I wanted to start by solving basically two non-coupled problems simultaneously, following the tutorials mixed.py and compound.py, but the code crashes with a segfault… Am I approaching this correctly in the first place?
Best, welahi
Code:
from ngsolve import *
from netgen.occ import unit_square
from ngsolve.meshes import Make1DMesh
mesh1 = Make1DMesh(10)
mesh2 = Mesh(unit_square.GenerateMesh(maxh=0.2))
fes1 = H1(mesh1, order=2, dirichlet=“left”)
fes2 = H1(mesh2, order=2, dirichlet=“left|right|bottom|top”)
fes = fes1*fes2
u1, u2 = fes.TrialFunction()
v1, v2 = fes.TestFunction()
a = BilinearForm(fes)
a1, a2 = a.components
a1 += grad(u1)*grad(v1)*dx
a2 += grad(u2)*grad(v2)*dx
a.Assemble() # Crashes here