I currently use freefem++3.6 and with it I can generate a .txt file that I run with the gnuplot software.
And there I see that the curve drawn decreases exponentially.
Yes, well, in my point of view.
My theory said that Energy decreases exponentially.
Please How can i define the maximum absolute error (linifinality) for vector functions?
You really need to look through more examples probably.
Iβm just curious if my solving code was right. Most of the other stuff will make
sense on a little reflection.
Vectors can be tricky if the components have different weights or units.
I guess just taking the max magnitude of the difference would work.
Good evening Professor.
Good evening to all
I did the same thing for this equation system.
Here the solution is a vector function.
Here is the .edp file
I hope for your corrections and comments.
Thanks in advance.
\begin{equation}
\left{
\begin{array}{lll}
\frac{1}{\mu_1} ~rot~ rot ~\mathbf{ A} = 0 & \mbox{in}& \Omega \times [0,T]\\
rot ~\mathbf{ A} \wedge \mathbf{ n} = -|rot \mathbf{A}|^2_{L^2} \mathbf{A} &\mbox{on}& \Sigma_N \\
\mathbf{A}=0 &\mbox{on}& \Sigma_D
\end{array}
\right.
\end{equation}
%
\paragraph{ }
\Omega ouvert bornΓ© de \mathbb{R}^3.
\mathbf{A} \in (H(rot))^3 is vector function.\
The variationnal formulation is:
\frac{1}{\mu_1} \displaystyle\int_\Omega rot ~ \mathbf{A}\cdot rot~ \tilde{\mathbf{A}}~ =~ -\|rot \mathbf{A}\|^2_{L^2} \displaystyle\int_{\Gamma_N} \mathbf{A} \cdot \tilde{\mathbf{A}}
edp.edp (2.68 KB)
I will try to look at this tomorrow but Iwas curious if this started out as soemthing
like rot(rot(E)) - E*conj(E) j omega J ; with J being a sheet current on the bottom
surface? Is there a factor of i floating around and is E divergence free? Not
sure if there are any materials properties that vary making the intergration by
parts more complicated and if the identity to the vector laplacian has any
benefits or drawbacks.
it is an evolution of the magnetic field I took just the static case
As written it looks like zero is a good result which is what happens if you
increase your grid density - I used nx=ny=nz=10.
Were you trying to get some other answer? Is the surface value fixed or something?
The value of the area is not fixed.
I just took an example.
Is my way of defining the error err= un1
is correct?
Error metrics are more of art than science I guess I would
say that Iβve had a lot of issues understanding the ways to
deal with vector fespaces. I guess I would check some sizes,
u.n and do some other sanity checks just to become familiar with
the meanings of the FF code.
Still, I donβt see a forcing function or anything to prevent
a zero solution. I guess if you do some fixed point / self consistent
iteration maybe you could find a non-zero solution but how do
expect to get there? If div(A)==0, AFACIT you have
-laplacian(A)= |int3d(rot(A) dot rot(A)) A.
when I implement the evolution problem this is what I get.
where the fixed point method does not converge
β Build Nodes/DF on mesh : n.v. 24, n. elmt. 30, n b. elmt. 44
nb of Nodes 75 nb of DoF 75 DFon=0100
β FESpace: Nb of Nodes 75 Nb of DoF 75
β FESpace: Nb of Nodes 24 Nb of DoF 72
β FESpace: Nb of Nodes 24 Nb of DoF 24
β Build Nodes/DF on mesh : n.v. 24, n. elmt. 30, n b. elmt. 44
nb of Nodes 99 nb of DoF 465 DFon=10300
β Solve :
min -1.71564e-027 max 1.4276e+007
min -0.975333 max 0.51875
min -1.45476e+011 max -4.58353e+010
min -4e+006 max 3.14952e+006
min -2.90952e+013 max -9.16705e+012
min -8e+008 max 6.29904e+008
min -8.43568e-028 max 9.94656e-028
0 ENERGIE 5.62035e-017 err = 7.2738e+008
β Solve :
min -1.18077e+009 max 1
min -29561.6 max 26269.1
min -9.61894e+010 max 1.45476e+011
min -3.14952e+006 max 4e+006
min 1.21114e+013 max 8.72856e+013
min -1.88971e+009 max 2.4e+009
min -1.51847e-025 max 1.7034e-025
1 ENERGIE 1.62877e+011 err = 1.19455e+009
β Solve :
min -6.57424e+012 max 8.15231e+012
min -54149.9 max 32620.1
min -4.59652e+014 max 1.73209e+015
min -7.54704e+006 max 1.33138e+007
min -3.41063e+017 max 3.11247e+017
min -3.6456e+009 max 3.82766e+009
min -4.41425e-022 max 3.38377e-022
2 ENERGIE 1.03994e+015 err = 8.15261e+012
β Solve :
min -1.64464e+015 max 8.15356e+014
min -1.40366e+009 max 3.12579e+008
min -2.26348e+013 max 2.95305e+013
min -2.26779e+011 max 9.15676e+010
min -1.08668e+020 max 2.1298e+020
min -6.79346e+014 max 4.46508e+013
min -7.90645e-020 max 2.31968e-020
3 ENERGIE 3.6604e+022 err = 1.64456e+015
β Solve :
min -1.6437e+015 max 8.86668e+014
min -4.29581e+010 max 1.44262e+010
min -5.67108e+008 max 7.7429e+008
min -5.9711e+012 max 1.91591e+012
min -2.16891e+020 max 1.15359e+020
min -8.98396e+015 max 2.51346e+015
min -3.91314e-020 max 2.92578e-020
4 ENERGIE 3.28325e+026 err = 7.13123e+013
β Solve :
min -1.6437e+015 max 8.86668e+014
min -3.7694e+011 max 2.10747e+012
min -2786.63 max 2223.46
min -1.92009e+014 max 3.09468e+014
min -1.15359e+020 max 2.16891e+020
min -6.67084e+017 max 6.23891e+016
min -2.79905e-020 max 2.92697e-020
5 ENERGIE 6.83905e+026 err = 1.3282e+009
β Solve :
min -1.6437e+015 max 8.86668e+014
min -9.88204e+011 max 5.20688e+012
min -0.000251871 max 0.000124458
min -6.88325e+014 max 3.39197e+014
min -2.16891e+020 max 1.15359e+020
min -8.66066e+016 max 9.49683e+017
min -2.79905e-020 max 2.92697e-020
6 ENERGIE 6.92766e+029 err = 3.44026e+006
β Solve :
min -1.6437e+015 max 8.86668e+014
min -1.49139e+015 max 1.96442e+015
min -0.00285194 max 0.0022221
min -6.91322e+017 max 4.59869e+017
min -1.15359e+020 max 2.16891e+020
min -1.3653e+021 max 2.05069e+020
min -2.79905e-020 max 2.92697e-020
7 ENERGIE 3.5806e+030 err = 4.35546e+007
β Solve :
min -1.6437e+015 max 8.86668e+014
min -2.41882e+016 max 2.9685e+016
min -5.31298e-012 max 6.41931e-012
min -3.45531e+014 max 5.48897e+013
min -2.16891e+020 max 1.15359e+020
min -6.56342e+020 max 9.8171e+021
min -2.79905e-020 max 2.92697e-020
8 ENERGIE 9.42146e+035 err = 63182.8
β Solve :
min -1.6437e+015 max 8.86668e+014
min -1.12619e+021 max 1.38374e+021
min -2.33956e-010 max 1.87048e-010
min -1.28148e+017 max 4.23826e+016
min -1.15359e+020 max 2.16891e+020
min -5.85554e+026 max 1.16752e+026
min -2.79905e-020 max 2.92697e-020
9 ENERGIE 1.50944e+038 err = 1.40811e+007
β Solve :
min -1.6437e+015 max 8.86668e+014
min -8.08008e+023 max 9.93891e+023
min -4.173e-025 max 3.38333e-025
min -9.91323e+009 max 7.49105e+009
min -2.16891e+020 max 1.15359e+020
min -1.06673e+029 max 1.01357e+029
min -2.79905e-020 max 2.92697e-020
10 ENERGIE 6.00013e+047 err = 2345.77
β Solve :
min -1.#IND max -1.#IND
min 1.#INF max 1.#INF
min -1.#IND max -1.#IND
min -1.#INF max -1.#INF
min -1.#IND max -1.#IND
min -1.#IND max -1.#IND
min -1.#IND max -1.#IND
11 ENERGIE 1.75086e+053 err = 1.#QNAN
-1.#IND != -1.#IND => Sorry error in Optimization (a) add: int2d(Th,optimize=0)(β¦)
current line = 153
Exec error : In Optimized version
β number :1
Exec error : In Optimized version
β number :1
err code 7 , mpirank 0
FreeFem++ returned error 7
did you post the code as attach?
I guess if you think the solver is having problems and canβt identify a coding issue
you can look at the equation.
If you extend the RHS into the volume, and convert rot()rot() into a vector
laplacian ( assuming constant divergence of A ) it looks like
you can put in a plane wave solution ( or exponential depending on the actual
sign ) For example, A_y=aSin(kx) both terms end up with a k^2
factor but the amplitude is fixed with something like 1/sqrt(int(cose^2(kx)).
I guess if you can find a k that satisfies boundary conidtions you have
non-zero modesβ¦
Hello to all.
I implemented in freefem ++ the displacement of a plate of dimension (0.1 0.010.012) that I stabilized with a control so the energy decreases.
With gnuplot I plotted the energy curve versus time from a file recorded with freefem++.
Here is the obtained curve.
The decay is so extreme that I wonder if there is instability or my control does not exist.
Is this the thing you posted before? IIRC it varied with your time step by a
lot and I posted some alternative code that decayed more slowly
and was more or less insensitive to the time step.
Yes, when I correct, this is what I get.
min -6088.65 max 3162.48
min -3.0201e-34 max 3.02049e-34
t=0 E(t) 1.28526e+10
current line = 182
Exec error : Try to get unset x,y, β¦
β number :1
Exec error : Try to get unset x,y, β¦
β number :1
err code 8 , mpirank 0
try getConsole C:\Users\ADMIN\Documents\dddd
save log in : βC:\Users\ADMIN\Documents\dddd.logβ
wait enter ?
is another work.
if you want i can add a file.log
I donβt know why the compilation stop like this
- Square mesh : nb vertices =4 , nb triangles = 2 , nb boundary edges 4
β Square mesh : nb vertices =4 , nb triangles = 2 , nb boundary edges 4
β Build Nodes/DF on mesh : n.v. 8, n. elmt. 6, n b. elmt. 12
nb of Nodes 19 nb of DoF 19 DFon=0100
β FESpace: Nb of Nodes 19 Nb of DoF 19
β FESpace: Nb of Nodes 8 Nb of DoF 24
β FESpace: Nb of Nodes 8 Nb of DoF 8
β Build Nodes/DF on mesh : n.v. 8, n. elmt. 6, n b. elmt. 12
nb of Nodes 27 nb of DoF 137 DFon=10300
GC: converge in 1 g=-6.25924e+10 rho= 0.100665 gamma= -0.371759
β Solve :
min -0.0131588 max 0.998097
min -1.51003e-25 max 0.0205185
min 0 max 1.00673e+08
min -1.43024e-07 max 1.97691e-07
min -1.11413e+07 max 2.65812e+11
min -6088.65 max 3162.48
min -3.0201e-34 max 3.02049e-34
t=0 E(t) 1.28526e+10
current line = 182
Exec error : Try to get unset x,y, β¦
β number :1
Exec error : Try to get unset x,y, β¦
β number :1
err code 8 , mpirank 0
try getConsole C:\Users\ADMIN\Documents\dddd
Good evening professor
good evening to all
Please, I would like someone to send me a code example of a 3D elasticity evolution problem.
Thank you in advance.
3dexample.edp (6.45 KB)