Hello,
I came across a segmentation fault when trying to run membrane program in the documentation. I have compiled Freefem++ 4.6 on Xubuntu 20.04.
Any ideas on how to solve this?
Thank you.
real theta = 4.*pi/3.;
real a = 2.; //The length of the semimajor axis
real b = 1.; //The length of the semiminor axis
func z = x;
// Mesh
border Gamma1(t=0., theta){x=a*cos(t); y=b*sin(t);}
border Gamma2(t=theta, 2.*pi){x=a*cos(t); y=b*sin(t);}
mesh Th = buildmesh(Gamma1(100) + Gamma2(50));
// Fespace
fespace Vh(Th, P2); //P2 conforming triangular FEM
Vh phi, w, f=1;
// Solve
solve Laplace(phi, w)
= int2d(Th)(
dx(phi)*dx(w)
+ dy(phi)*dy(w)
)
- int2d(Th)(
f*w
)
+ on(Gamma1, phi=z);
// Plot
plot(phi, wait=true, ps="membrane2.eps"); //Plot phi
plot(Th, wait=true, ps="membraneTh2.eps"); //Plot Th
// Save mesh
savemesh(Th,"Th2.msh");