Just a quick question (mainly for those who are also familiar with ABAQUS or other comparable FEM programs and non-linear modelling of mechanical behavior, e.g., plasticity). Is there any module in the FEM environment in Mathematica in which you can set a general material behavior like in the UMATs of ABAQUS? I am just thinking of a standard von Mises plasticity model with ideal plastic behavior and homogeneous isotropic elastic behavior for small deformations. Or would you just write the evolution equations of the state variables in the field equations for the FEM solver and that's it? Thank you!
EDIT (2016-02-04):
If this is getting to far or I just express my question way to unclear, I would understand if closing the question is better for the community. These
Google drive link to hand written pdf
are the main ideas I know of on how a UMAT works, e.g., in ABAQUS. They are used in order to evolve internal variables locally at each integration point of each element independently of the rest. The internal variables do not exist at the FEM nodes but only locally on the integration points. For a sequential global Newton interation, the tangent at each integration point must be calculated in the UMAT (user defined material, this comes from mechanics), which are then used in the chosen quadrature method for computing the integrals and the global Jacobian. The example given below could be treated with a UMAT by considering the field $\varepsilon_p$ as an internal variable and careful treating of the corresponding cases.
EDIT1 (2015-05-10):
Ok, I should have given a minimal problem, sorry for that. Here is the simplest 1D problem from mechanics I can come up with, see pictures below or the online pdf (link below). In ABAQUS for example the in general non-linear material model is called up as an external program. How would you treat this problem with the FEM of Mathematica?
EDIT2 (2015-05-11):
I just added the section "Complete system", in order to clarify the problem.
EDIT3 (2016-01-14):
I just edited the pdf and introduced the complete solution for a simpler case.
@user21: I am tried the WhenEvent
but I am not sure on how to combine it with the field equations (see code below, I actually already had problems without any evolution of $\varepsilon_p$). Sorry for leaving this thing hanging around for so long. I will try to work on the description of an UMAT in the next weeks.
pdf: Google drive
Pictures:
Code (purely elastic):
Needs["NDSolve`FEM`"]
(*Domain*)
xmin = 0;
xmax = 10;
reg = ImplicitRegion[xmin <= x <= xmax, {x}];
(*Field equation*)
sig[x_, t_] := Ef[x, t]*eps[x, t];
eps[x_, t_] := D[u[x, t], x];
phi[x_, t_] := Abs[sig[x, t]] - sig0;
feq = D[Af[x, t]*sig[x, t], x] + nf[x, t];
(*Paremeters*)
E0 = 3;
Ef[x_, t_] := E0;
A0 = 7;
Af[x_, t_] := A0;
sig0 = 2;
(*Inhomogeneity*)
nf[x_, t_] := 0;
F[t_] := A0*sig0*3*t;
(*Conditions*)
iconds = u[x, 0] == 0;
bconds = {
DirichletCondition[u[x, t] == 0, x == xmin]
(*,DirichletCondition[u[x,t]==1*t,x==xmax]*)
};
nconds = NeumannValue[-F[t], x == xmax];
(*Fem solution*)
ufem = NDSolveValue[{feq == nconds, iconds, bconds}, u,
Element[x, reg], {t, 0, 1}];
(*Plot*)
Plot[Table[u[x, ti] /. u -> ufem, {ti, 0, 1, 0.2}], {x, xmin, xmax},
AxesLabel -> {"x", "u(x,t)"}]
Evolution of displacement
Defective Code (attempt for use of WhenEvent
):
Needs["NDSolve`FEM`"]
(*Domain*)
xmin = 0;
xmax = 10;
reg = ImplicitRegion[xmin <= x <= xmax, {x}];
(*Field equation*)
sig[x_, t_] := Ef[x, t]*(eps[x, t] - epsp[x, t]);
eps[x_, t_] := D[u[x, t], x];
phi[x_, t_] := Abs[sig[x, t]] - sig0;
feq = {
D[Af[x, t]*sig[x, t], x] + nf[x, t]
, D[epsp[x, t], t]
(*,WhenEvent[phi[x,t]==0,D[epsp[x,t],t]->D[eps[x,t],
t]]*)
};
(*Paremeters*)
E0 = 3;
Ef[x_, t_] := E0;
A0 = 7;
Af[x_, t_] := A0;
sig0 = 2;
(*Inhomogeneity*)
nf[x_, t_] := 0;
F[t_] := 7*sig0*3*t;
(*Conditions*)
iconds = {u[x, 0] == 0, epsp[x, 0] == 0};
bconds = {
DirichletCondition[u[x, t] == 0, x == xmin]
(*,DirichletCondition[u[x,t]==1*t,x==xmax]*)
};
nconds = NeumannValue[-F[t], x == xmax];
(*Fem solution*)
fem = NDSolveValue[{feq == {nconds, 0}, iconds, bconds}, {u, epsp},
Element[x, reg], {t, 0, 1}];
(*Plot*)
Plot[Table[u[x, ti] /. u -> fem[[1]], {ti, 0, 1, 0.2}], {x, xmin,
xmax}, AxesLabel -> {"x", "u(x,t)"}]
Plot[Table[epsp[x, ti] /. epsp -> fem[[2]], {ti, 0, 1, 0.2}], {x,
xmin, xmax}, AxesLabel -> {"x", "epsp(x,t)"}]
Plot[epsp[x, 1] /. epsp -> fem[[2]], {x, xmin, xmax},
PlotRange -> {-1, 1}, AxesLabel -> {"x", "epsp(x,t)"}]
Weird results for $\varepsilon_p$ (it should stay at zero, since no evolution is given in the code above, WhenEvent
is not active since I dont know how to properly use it in this example)