First, You use 2D finite element for 1d problem,
secondly, you use P2 finite element to compute third derivative
third: you vationnal form is crazy if v = 1 then you have 0 = 6 => system not invertible .
A code in 1d (wrong ) the formulation is wrong pb of Boundary condition
you have 3 constants unknown and you set only 2 …
I have some setbacks. Your code does’nt work on my machine, is it abnormal or voluntary ?
The error code is :
Build Nodes/DF on mesh : n.v. 101, n. elmt. 100, n b. elmt. 2
nb of Nodes 201 nb of DoF 201 DFon=1100
– FESpace: Nb of Nodes 201 Nb of DoF 201
current line = 11
Assertion fail : (0)
line :245, in file …/femlib/P012_3dCurve.cpp
Assertion fail : (0)
line :245, in file …/femlib/P012_3dCurve.cpp
err code 6 , mpirank 0
I have ever tried to reinstall 2 times from the binaries, version 4.6 and to compile from the source , version 4.10.
Before that, i used freefem 4.4 which don’t use 1 D element, it’s why my code use 2 D element.
I’m much more used to finite difference method , sorry for my dumb question. I don’t understand why P2 finite element is bad in this case ? Because I need dxx so second order ?
3 constants is needed, now i see that, x³+1 is not the only solution without enough constraints.
About the third remark, did you want to say that we have a conflict between int1d(Th)(6*v) and on(2,u=xxx ) (xxx=0) if v=1 at x=0 ?
But applying the integration by parts :
y’’ =6 => y’‘*v =6 *v <=> int2d -y’‘*v’ + int1d y’‘v = int2d 6v <=> int2d y’*v’’ - int1d y’*v’ + int1d y’'v = int2d 6v
I suppose that a factor is missing ? I tried several patchs but nothing work.