Algorithm Search⌘K

Algorithmadvanced

Return mapping algorithm

Also called radial return algorithm, radial return mapping.

Integrates elastoplastic laws at each quadrature point by an elastic trial stress followed by a projection back to the yield surface.

Time
Θ(n q) worst
Space
Θ(q) extra
Where
n = the number of strain increments; q = the number of quadrature points
Properties
closed form for linear hardeningconsistent tangentdeterministicexact for backward euler equationsnot iterative
Origin
M. L. Wilkins, R. D. Krieg, J. C. Simo, R. L. Taylor, T. J. R. Hughes, 1964

The return mapping algorithm computes the stress at one quadrature point of a finite element model with elastoplastic material. It gets the total strain at the end of a load step and the plastic state at the start of the step. First it assumes that the step is elastic and computes a trial stress. If the trial stress is inside the yield surface, the step is elastic and the trial stress is the answer. If not, it moves the stress back onto the yield surface and updates the plastic strain and the hardening variables. The result is the exact solution of the backward Euler equations of the flow rule for this step. For von Mises (J2) plasticity with linear hardening the projection is along the radius of the yield cylinder, so the map is in closed form. The derivative of the map is the consistent tangent. With it, the global Newton iteration converges quadratically.

In plain words

Think of a metal bar that you stretch in small steps. In each step, first pretend that the bar is a spring and compute the force from the stretch. If this force is below what the metal can carry, it is the right answer. If it is above, the metal must have flowed. Then pull the force back down to what the metal can carry, and record how much of the stretch became permanent. In three dimensions, the pull back goes straight toward the centre of a circle of allowed stresses, so one division gives the answer. The method also tells the solver how the force changes when the stretch changes. This lets the solver of the whole structure converge in very few steps.

The problem

Input. At one quadrature point: the total strain εn+1\varepsilon_{n+1} at the end of the step, the plastic state at the start of the step (plastic strain εnp\varepsilon^p_n, equivalent plastic strain αn\alpha_n, back stress βn\beta_n), the bulk modulus κ\kappa, the shear modulus μ\mu, the initial yield stress σy>0\sigma_y > 0, the isotropic hardening modulus K≥0K \ge 0 and the kinematic hardening modulus H≥0H \ge 0.

Output. The stress σn+1\sigma_{n+1}, the new state (εn+1p,αn+1,βn+1)(\varepsilon^p_{n+1}, \alpha_{n+1}, \beta_{n+1}) and the tangent Cn+1=∂σn+1/∂εn+1C_{n+1} = \partial \sigma_{n+1} / \partial \varepsilon_{n+1}, such that the backward Euler equations hold:

σn+1=κ (tr εn+1) I+2μ (dev εn+1−εn+1p),εn+1p=εnp+Δγ n^,\sigma_{n+1} = \kappa\,(\mathrm{tr}\,\varepsilon_{n+1})\,I + 2\mu\,(\mathrm{dev}\,\varepsilon_{n+1} - \varepsilon^p_{n+1}), \qquad \varepsilon^p_{n+1} = \varepsilon^p_n + \Delta\gamma\,\hat n,
αn+1=αn+2/3 Δγ,βn+1=βn+23H Δγ n^,n^=ξn+1∣ξn+1∣,ξn+1=dev σn+1−βn+1,\alpha_{n+1} = \alpha_n + \sqrt{2/3}\,\Delta\gamma, \qquad \beta_{n+1} = \beta_n + \tfrac23 H\,\Delta\gamma\,\hat n, \qquad \hat n = \frac{\xi_{n+1}}{|\xi_{n+1}|}, \quad \xi_{n+1} = \mathrm{dev}\,\sigma_{n+1} - \beta_{n+1},

with the yield function f=∣ξ∣−2/3 (σy+Kα)f = |\xi| - \sqrt{2/3}\,(\sigma_y + K\alpha) and the loading conditions

Δγ≥0,fn+1≤0,Δγ fn+1=0.\Delta\gamma \ge 0, \qquad f_{n+1} \le 0, \qquad \Delta\gamma\,f_{n+1} = 0.

Here ∣⋅∣|\cdot| is the Frobenius norm. The flow rule is a differential equation with an inequality constraint in time. Backward Euler replaces it by the equations above, which have one unknown scalar Δγ\Delta\gamma after the elimination of the others. The one-dimensional model is the same with σ=E(ε−εp)\sigma = E(\varepsilon - \varepsilon^p), f=∣σ−q∣−(σy+Kα)f = |\sigma - q| - (\sigma_y + K\alpha) and no factors 2/3\sqrt{2/3} and 23\tfrac23.

The algorithm

  1. RADIAL-RETURN(eps, eps_p, alpha, beta, kappa, mu, sigma_y, K, H)
  2. 1s_tr <- 2 mu (dev eps - eps_p); xi_tr <- s_tr - beta ▷ elastic trial stress
  3. 2f_tr <- |xi_tr| - sqrt(2/3) (sigma_y + K alpha)
  4. 3if f_tr <= 0 then
  5. 4return sigma = s_tr + kappa (tr eps) I, the old state, the elastic tangent
  6. 5dgamma <- f_tr / (2 mu + 2/3 (K + H)); n <- xi_tr / |xi_tr|
  7. 6sigma <- s_tr - 2 mu dgamma n + kappa (tr eps) I ▷ radial return
  8. 7eps_p <- eps_p + dgamma n; alpha <- alpha + sqrt(2/3) dgamma; beta <- beta + 2/3 H dgamma n
  9. 8C <- kappa I (x) I + 2 mu theta I_dev - 2 mu theta_bar n (x) n; return sigma, the new state, C

In line L8, θ=1−2μ Δγ/∣ξtr∣\theta = 1 - 2\mu\,\Delta\gamma/|\xi_{\rm tr}| and θˉ=1/(1+(K+H)/(3μ))−(1−θ)\bar\theta = 1/(1 + (K + H)/(3\mu)) - (1 - \theta), I⊗II \otimes I maps a strain to its trace times II, and IdevI_{\rm dev} maps a symmetric strain to its deviator.

The pressure κ tr ε\kappa\,\mathrm{tr}\,\varepsilon is always elastic, because the plastic strain is deviatoric. In the one-dimensional map (return_map_1d), line L5 is Δγ=ftr/(E+K+H)\Delta\gamma = f_{\rm tr}/(E + K + H), line L6 is σ=σtr−E Δγ sign(ξtr)\sigma = \sigma_{\rm tr} - E\,\Delta\gamma\,\mathrm{sign}(\xi_{\rm tr}) and the tangent of line L8 is E(K+H)/(E+K+H)E(K + H)/(E + K + H).

The finite element code calls this map at every quadrature point in every global Newton iteration. Each call starts from the state of the last converged load step, never from the state of the last iteration. The state is stored only when the global iteration converges.

Example

One dimension, exact numbers. Take E=100E = 100, σy=1\sigma_y = 1, K=10K = 10, H=0H = 0, the virgin state and the strain ε=0.03\varepsilon = 0.03. Line L1 gives σtr=3\sigma_{\rm tr} = 3 and line L2 gives ftr=3−1=2>0f_{\rm tr} = 3 - 1 = 2 > 0, so the step is plastic. Line L5 gives Δγ=2/110=1/55\Delta\gamma = 2/110 = 1/55. Line L6 gives σ=3−100/55=13/11\sigma = 3 - 100/55 = 13/11. The new state is εp=α=1/55\varepsilon^p = \alpha = 1/55, and the new yield stress is 1+10/55=13/111 + 10/55 = 13/11, so the stress is on the yield surface. The tangent is 100⋅10/110=100/11100 \cdot 10/110 = 100/11. The bilinear stress strain curve has yield strain 0.010.01 and slope 100/11100/11 after yield, so it gives σ=1+(100/11)(0.02)=13/11\sigma = 1 + (100/11)(0.02) = 13/11. The reference code returns exactly these fractions (test_1d_exact_fractions). For monotone loading the one-dimensional map gives the exact curve for any number of steps.

Kinematic hardening and the Bauschinger effect. With K=0K = 0 and H>0H > 0, the elastic range keeps its width 2σy2\sigma_y and moves with the back stress. After loading to σmax⁡\sigma_{\max} the bar unloads elastically until σmax⁡−2σy\sigma_{\max} - 2\sigma_y and then yields in compression. The tests check this.

Three dimensions, a path that turns. Take κ=160\kappa = 160, μ=80\mu = 80, σy=0.25\sigma_y = 0.25, K=10K = 10 and H=5H = 5. The strain has the fixed normal part diag(0.004,−0.002,−0.002)\mathrm{diag}(0.004, -0.002, -0.002) and a shear part ε12=0.006 t\varepsilon_{12} = 0.006\,t, and it is sampled at t=k/mt = k/m for k=1,…,mk = 1, \ldots, m, starting from the virgin state. The direction of the deviatoric stress turns during the path, so the result depends on the number of steps mm. The table gives the largest stress error against m=20480m = 20480 steps, where σ12=0.20929\sigma_{12} = 0.20929.

steps mm σ12\sigma_{12} largest error
1 0.17412 0.10
20 0.20778 1.75×10−31.75 \times 10^{-3}
40 0.20852 7.91×10−47.91 \times 10^{-4}
80 0.20890 3.91×10−43.91 \times 10^{-4}
160 0.20909 1.96×10−41.96 \times 10^{-4}

The error halves when the step halves, so the map is first order on this path. On a proportional path, where the direction n^\hat n stays fixed, one step and 40 steps give the same stress to 10−1210^{-12}.

A bar in series. Four bar elements with areas 1,0.8,1.2,11, 0.8, 1.2, 1 and length 1 are fixed at one end and pulled 0.020.02 at the other, with E=200E = 200 and the same yield data. All four yield. Newton's method with the consistent tangent converges in 2 iterations: the response is piecewise linear, so one iteration finds the right branch in every element and the next is exact. With the elastic modulus as the tangent the same tolerance needs 361 iterations.

Correctness

The proofs are in the correctness proof.

  • The map solves the backward Euler equations, and the solution is unique (theorem). Elimination shows that ξn+1\xi_{n+1} is a positive multiple of ξtr\xi_{\rm tr}, so n^=ξtr/∣ξtr∣\hat n = \xi_{\rm tr}/|\xi_{\rm tr}| and fn+1=ftr−(2μ+23(K+H))Δγf_{n+1} = f_{\rm tr} - (2\mu + \tfrac23(K + H))\Delta\gamma. The loading conditions then leave one choice: Δγ=0\Delta\gamma = 0 if ftr≤0f_{\rm tr} \le 0 and line L5 if not.
  • The stress is the closest point (theorem, perfect plasticity). For K=H=0K = H = 0 the deviatoric stress of line L6 is the point of the ball ∣s−β∣≤2/3 σy|s - \beta| \le \sqrt{2/3}\,\sigma_y that is closest to strs_{\rm tr}.
  • The tangent of line L8 is the exact derivative of the map (theorem). At a plastic point with ftr>0f_{\rm tr} > 0, differentiating lines L1, L5 and L6 gives CC. A finite difference test in the reference code agrees with it.
  • This is exactness for the discrete equations, not for the flow rule. The backward Euler equations differ from the continuum law on paths where n^\hat n turns. Then the error is first order in the step (measured above). On proportional paths and for monotone loading in one dimension, the map is exact for the continuum law.
Proof: Radial return solves the backward Euler equations of J2 plasticity uniquely, and line L8 is its derivativefull

Setting. The data are κ>0\kappa > 0, μ>0\mu > 0, σy>0\sigma_y > 0, K≥0K \ge 0, H≥0H \ge 0, the state (εnp,αn,βn)(\varepsilon^p_n, \alpha_n, \beta_n) with εnp\varepsilon^p_n and βn\beta_n symmetric and deviatoric, and the strain ε=εn+1\varepsilon = \varepsilon_{n+1}. Write r=2/3r = \sqrt{2/3}, e=dev εe = \mathrm{dev}\,\varepsilon, str=2μ(e−εnp)s_{\rm tr} = 2\mu(e - \varepsilon^p_n), ξtr=str−βn\xi_{\rm tr} = s_{\rm tr} - \beta_n, ftr=∣ξtr∣−r(σy+Kαn)f_{\rm tr} = |\xi_{\rm tr}| - r(\sigma_y + K\alpha_n) and c=2μ+23(K+H)>0c = 2\mu + \tfrac23(K + H) > 0. The backward Euler equations are those of the section "The problem". A solution is a scalar Δγ\Delta\gamma and a deviatoric unit tensor n^\hat n that satisfy them; when Δγ=0\Delta\gamma = 0 the tensor n^\hat n plays no role.

Lemma 1 (reduction to one scalar). For any Δγ≥0\Delta\gamma \ge 0 and unit deviatoric n^\hat n, the equations for εn+1p\varepsilon^p_{n+1}, αn+1\alpha_{n+1}, βn+1\beta_{n+1} and σn+1\sigma_{n+1} give

ξn+1=ξtr−(2μ+23H) Δγ n^,fn+1=∣ξn+1∣−r(σy+Kαn)−23K Δγ.\xi_{n+1} = \xi_{\rm tr} - (2\mu + \tfrac23 H)\,\Delta\gamma\,\hat n, \qquad f_{n+1} = |\xi_{n+1}| - r(\sigma_y + K\alpha_n) - \tfrac23 K\,\Delta\gamma.

Proof. The deviator of σn+1\sigma_{n+1} is 2μ(e−εnp−Δγ n^)=str−2μ Δγ n^2\mu(e - \varepsilon^p_n - \Delta\gamma\,\hat n) = s_{\rm tr} - 2\mu\,\Delta\gamma\,\hat n, because n^\hat n is deviatoric. Subtract βn+1=βn+23H Δγ n^\beta_{n+1} = \beta_n + \tfrac23 H\,\Delta\gamma\,\hat n. For fn+1f_{n+1} use Kαn+1=Kαn+rK ΔγK\alpha_{n+1} = K\alpha_n + rK\,\Delta\gamma and r⋅r=23r \cdot r = \tfrac23. □\square

Theorem 1 (existence and uniqueness). The backward Euler equations with the loading conditions have exactly one solution for (σn+1,εn+1p,αn+1,βn+1)(\sigma_{n+1}, \varepsilon^p_{n+1}, \alpha_{n+1}, \beta_{n+1}). It is the output of lines L1 to L7: Δγ=0\Delta\gamma = 0 if ftr≤0f_{\rm tr} \le 0, and Δγ=ftr/c\Delta\gamma = f_{\rm tr}/c with n^=ξtr/∣ξtr∣\hat n = \xi_{\rm tr}/|\xi_{\rm tr}| if ftr>0f_{\rm tr} > 0.

Proof. Case Δγ=0\Delta\gamma = 0. Then every quantity at n+1n + 1 equals its trial value and fn+1=ftrf_{n+1} = f_{\rm tr}, so the conditions hold if and only if ftr≤0f_{\rm tr} \le 0.

Case Δγ>0\Delta\gamma > 0. The loading conditions force fn+1=0f_{n+1} = 0, so ∣ξn+1∣=r(σy+Kαn+1)>0|\xi_{n+1}| = r(\sigma_y + K\alpha_{n+1}) > 0 and n^=ξn+1/∣ξn+1∣\hat n = \xi_{n+1}/|\xi_{n+1}| is defined. Lemma 1 gives

ξtr=ξn+1+(2μ+23H) Δγ ξn+1∣ξn+1∣=(1+(2μ+23H)Δγ∣ξn+1∣) ξn+1.\xi_{\rm tr} = \xi_{n+1} + (2\mu + \tfrac23 H)\,\Delta\gamma\,\frac{\xi_{n+1}}{|\xi_{n+1}|} = \Big(1 + \frac{(2\mu + \tfrac23 H)\Delta\gamma}{|\xi_{n+1}|}\Big)\,\xi_{n+1}.

The factor is larger than 1, so ξn+1\xi_{n+1} is a positive multiple of ξtr\xi_{\rm tr}. Hence ξtr≠0\xi_{\rm tr} \ne 0, n^=ξtr/∣ξtr∣\hat n = \xi_{\rm tr}/|\xi_{\rm tr}| and ∣ξn+1∣=∣ξtr∣−(2μ+23H)Δγ|\xi_{n+1}| = |\xi_{\rm tr}| - (2\mu + \tfrac23 H)\Delta\gamma. With Lemma 1, fn+1=ftr−c Δγf_{n+1} = f_{\rm tr} - c\,\Delta\gamma, and fn+1=0f_{n+1} = 0 gives Δγ=ftr/c\Delta\gamma = f_{\rm tr}/c. This is positive if and only if ftr>0f_{\rm tr} > 0.

The two cases exclude each other: if ftr≤0f_{\rm tr} \le 0 the second case has no solution, and if ftr>0f_{\rm tr} > 0 the first case has none. In each case the solution is unique, and lines L5 to L7 compute it. Line L4 returns the first case. □\square

Corollary 1. After a plastic step fn+1=0f_{n+1} = 0, the plastic strain increment is deviatoric and parallel to ξn+1\xi_{n+1} (normality), and the pressure is κ tr ε\kappa\,\mathrm{tr}\,\varepsilon. After an elastic step the state does not change. The reference tests check these facts on random strains.

Theorem 2 (closest point, perfect plasticity). Let K=H=0K = H = 0, R=rσyR = r\sigma_y and B={s:∣s−βn∣≤R}B = \{s : |s - \beta_n| \le R\}. The deviatoric stress sn+1s_{n+1} of lines L1 to L6 is the point of BB closest to strs_{\rm tr} in the Frobenius norm.

Proof. If ftr≤0f_{\rm tr} \le 0 then str∈Bs_{\rm tr} \in B and sn+1=strs_{n+1} = s_{\rm tr}. If not, ∣ξtr∣>R|\xi_{\rm tr}| > R and sn+1=βn+R ξtr/∣ξtr∣s_{n+1} = \beta_n + R\,\xi_{\rm tr}/|\xi_{\rm tr}|, since 2μ Δγ=∣ξtr∣−R2\mu\,\Delta\gamma = |\xi_{\rm tr}| - R. For any s∈Bs \in B, the triangle inequality gives ∣str−s∣≥∣str−βn∣−∣s−βn∣≥∣ξtr∣−R=∣str−sn+1∣|s_{\rm tr} - s| \ge |s_{\rm tr} - \beta_n| - |s - \beta_n| \ge |\xi_{\rm tr}| - R = |s_{\rm tr} - s_{n+1}|. Equality in the first step needs s−βns - \beta_n to be a nonnegative multiple of ξtr\xi_{\rm tr}, and in the second ∣s−βn∣=R|s - \beta_n| = R, so the closest point is unique. □\square

Theorem 3 (consistent tangent). At a strain with ftr>0f_{\rm tr} > 0, the map ε↦σn+1\varepsilon \mapsto \sigma_{n+1} is differentiable, and for symmetric increments dεd\varepsilon,

dσn+1=(κ I⊗I+2μ θ Idev−2μ θˉ n^⊗n^) dε,θ=1−2μ Δγ∣ξtr∣,θˉ=11+(K+H)/(3μ)−(1−θ).d\sigma_{n+1} = \big(\kappa\,I \otimes I + 2\mu\,\theta\,I_{\rm dev} - 2\mu\,\bar\theta\,\hat n \otimes \hat n\big)\,d\varepsilon, \qquad \theta = 1 - \frac{2\mu\,\Delta\gamma}{|\xi_{\rm tr}|}, \quad \bar\theta = \frac{1}{1 + (K + H)/(3\mu)} - (1 - \theta).

Proof. The set ftr>0f_{\rm tr} > 0 is open, and there ξtr≠0\xi_{\rm tr} \ne 0, so all maps below are smooth. The state at nn is fixed. Then dstr=2μ Idev dεd s_{\rm tr} = 2\mu\,I_{\rm dev}\,d\varepsilon, so dξtr=2μ Idev dεd\xi_{\rm tr} = 2\mu\,I_{\rm dev}\,d\varepsilon. The derivative of the norm is d∣ξtr∣=n^:dξtr=2μ n^:dεd|\xi_{\rm tr}| = \hat n : d\xi_{\rm tr} = 2\mu\,\hat n : d\varepsilon, because n^\hat n is deviatoric. So

d(Δγ)=2μc n^:dε=11+(K+H)/(3μ) n^:dε.d(\Delta\gamma) = \frac{2\mu}{c}\,\hat n : d\varepsilon = \frac{1}{1 + (K + H)/(3\mu)}\,\hat n : d\varepsilon.

The derivative of the unit tensor is dn^=∣ξtr∣−1(Idev−n^⊗n^) dξtrd\hat n = |\xi_{\rm tr}|^{-1}(I_{\rm dev} - \hat n \otimes \hat n)\,d\xi_{\rm tr} on deviatoric increments, which gives dn^=2μ∣ξtr∣(Idev−n^⊗n^) dεd\hat n = \frac{2\mu}{|\xi_{\rm tr}|}(I_{\rm dev} - \hat n \otimes \hat n)\,d\varepsilon. Line L6 is σn+1=str−2μ Δγ n^+κ(tr ε)I\sigma_{n+1} = s_{\rm tr} - 2\mu\,\Delta\gamma\,\hat n + \kappa(\mathrm{tr}\,\varepsilon) I, so

dσn+1=2μ Idev dε−2μ n^ d(Δγ)−2μ Δγ dn^+κ I (I:dε).d\sigma_{n+1} = 2\mu\,I_{\rm dev}\,d\varepsilon - 2\mu\,\hat n\,d(\Delta\gamma) - 2\mu\,\Delta\gamma\,d\hat n + \kappa\,I\,(I : d\varepsilon).

Collect the terms. The coefficient of IdevI_{\rm dev} is 2μ(1−2μΔγ/∣ξtr∣)=2μθ2\mu(1 - 2\mu\Delta\gamma/|\xi_{\rm tr}|) = 2\mu\theta. The coefficient of n^⊗n^\hat n \otimes \hat n is −2μ(1/(1+(K+H)/(3μ))−2μΔγ/∣ξtr∣)=−2μθˉ-2\mu\big(1/(1 + (K + H)/(3\mu)) - 2\mu\Delta\gamma/|\xi_{\rm tr}|\big) = -2\mu\bar\theta. □\square

Remark 1 (one dimension). The same steps with EE in place of 2μ2\mu and without the factors rr and 23\tfrac23 give Theorem 1 for return_map_1d: Δγ=ftr/(E+K+H)\Delta\gamma = f_{\rm tr}/(E + K + H) if ftr>0f_{\rm tr} > 0. Then dσ=E dε−E sign(ξtr) d(Δγ)d\sigma = E\,d\varepsilon - E\,\mathrm{sign}(\xi_{\rm tr})\,d(\Delta\gamma) with d(Δγ)=E sign(ξtr) dε/(E+K+H)d(\Delta\gamma) = E\,\mathrm{sign}(\xi_{\rm tr})\,d\varepsilon/(E + K + H), so dσ/dε=E(K+H)/(E+K+H)d\sigma/d\varepsilon = E(K + H)/(E + K + H), which is line L8 of the one-dimensional code.

Remark 2 (exactness for the continuum law). Let the continuum strain path be ε(t)\varepsilon(t) with dev ε(t)−εp(t)−β(t)/(2μ)\mathrm{dev}\,\varepsilon(t) - \varepsilon^p(t) - \beta(t)/(2\mu) along a fixed unit tensor n^\hat n for all tt in the step, and let the point stay plastic. Then the continuum flow rule ε˙p=γ˙ n^\dot\varepsilon^p = \dot\gamma\,\hat n integrates to εn+1p=εnp+Δγ n^\varepsilon^p_{n+1} = \varepsilon^p_n + \Delta\gamma\,\hat n with Δγ=∫γ˙ dt\Delta\gamma = \int\dot\gamma\,dt, and the consistency condition at tn+1t_{n+1} is the scalar equation of Theorem 1. So the backward Euler solution is the continuum solution. This covers monotone loading in one dimension and proportional loading in three. When n^\hat n turns, the integral of γ˙ n^\dot\gamma\,\hat n is not Δγ n^n+1\Delta\gamma\,\hat n_{n+1}, and the map has a first order error, which the reference tests measure.

Complexity

In the real-RAM model, one call does a fixed number of operations: a deviator, one norm, one division and the 81 entries of the tangent. So nn strain increments at qq quadrature points cost Θ(nq)\Theta(n q) calls of constant cost, if each increment needs one global iteration. With jj global Newton iterations per increment the cost is Θ(nqj)\Theta(n q j), and the consistent tangent keeps jj small. The history is three tensors and one scalar per point, so the extra space is Θ(q)\Theta(q).

Properties

  • No local iteration for linear hardening. The scalar equation for Δγ\Delta\gamma is linear. With nonlinear isotropic hardening it is a scalar nonlinear equation, which local Newton iterations solve.
  • Unconditionally stable. Any step size gives a stress on or inside the yield surface, and the loading conditions hold exactly.
  • The consistent tangent is symmetric for associative J2 plasticity, and it differs from the continuum elastoplastic tangent by the factor θ<1\theta < 1 on the deviatoric part. The two agree only as Δγ→0\Delta\gamma \to 0.
  • The volume change is elastic. The pressure never needs a correction.

Variants and improvements

  • Closest point projection. For a general convex yield function, the same backward Euler equations need a local Newton iteration on (σ,Δγ)(\sigma, \Delta\gamma), with the second derivatives of the yield function.
  • Cutting plane (Ortiz and Simo 1986). Iterate with explicit corrections that need only the gradient of the yield function. It is cheaper per iteration, but its tangent is not consistent.
  • Generalized midpoint rule. Evaluate the flow direction at εn+ϑ\varepsilon_{n+\vartheta}. With ϑ=12\vartheta = \tfrac12 it is second order on smooth paths, but each step needs a local iteration even for linear hardening.
  • Finite strain. With a multiplicative split of the deformation gradient and logarithmic strains, the same radial return applies to the logarithms of the principal elastic stretches.
  • Viscoplasticity. For the overstress law γ˙=f/η\dot\gamma = f/\eta of Perzyna type, backward Euler adds η/Δt\eta/\Delta t to the denominator of line L5. As η→0\eta \to 0 the plastic map comes back.

When to use it

Use it in every implicit finite element code for metal plasticity, and as the model for other constitutive updates with an inequality constraint, such as damage, friction and Drucker Prager or Mohr Coulomb soil plasticity. With J2 plasticity and linear hardening the closed form is the standard choice. Use a closest point projection with local iterations for curved or anisotropic yield surfaces. In explicit dynamics the consistent tangent is not needed, but the return map itself is the same.

Pitfalls

  • Updating the history during the global iteration. The map must start every iteration from the converged state of the last step. If not, the plastic strain accumulates spurious increments and the solution depends on the number of iterations.
  • Using the continuum tangent. It drops the factor θ\theta and destroys quadratic convergence. With the elastic tangent the global iteration converges only linearly, as in the bar example.
  • Engineering shear strains. Codes in Voigt notation store 2ε122\varepsilon_{12}. The norm and the tangent then need factors of 2, and a missing factor changes the yield point in shear.
  • A zero trial deviator. If ξtr=0\xi_{\rm tr} = 0 the direction is not defined. The step is then elastic, because ftr=−2/3(σy+Kα)<0f_{\rm tr} = -\sqrt{2/3}(\sigma_y + K\alpha) < 0, so the code never divides by zero as long as σy>0\sigma_y > 0.
  • Large steps on turning paths. The map is stable for any step, but the stress after a nonproportional path has a first order error. Exactness for the discrete equations does not mean accuracy for the material law.

Implementations

Each implementation follows the pseudocode above. A comment @line links a line of code to a line of the pseudocode. Point at a line of the pseudocode to see the matching code. The build runs the native tests of each language.

return_mapping_algorithm.pyI0RawGitHub
# SPDX-License-Identifier: MIT
# Part of https://algorithm.tamnd.com/return-mapping-algorithm/. The authors are listed in prov/PD9SMC.jsonl.

"""Return mapping for rate-independent plasticity with linear hardening.

return_map_1d: one-dimensional plasticity with isotropic and kinematic hardening.
radial_return: three-dimensional J2 (von Mises) plasticity, closed form radial
return and the consistent tangent of Simo and Taylor (1985).

Both solve the backward Euler equations of the flow rule exactly for one strain
increment. Tensors are 3 by 3 lists; a fourth order tangent is a 9 by 9 list
indexed by (3 i + j, 3 k + l). With Fraction data the 1D map is exact.
"""

import math


def return_map_1d(eps, state, E, sy, K=0, H=0):
    """Return (sigma, new_state, tangent) for the total strain eps.

    state = (eps_p, alpha, q): plastic strain, equivalent plastic strain and
    back stress at the end of the last converged step. K is the isotropic and
    H the kinematic hardening modulus.
    """
    eps_p, alpha, q = state
    sig_tr = E * (eps - eps_p)  # @line L1
    xi = sig_tr - q
    f_tr = abs(xi) - (sy + K * alpha)  # @line L2
    if f_tr <= 0:  # @line L3
        return sig_tr, state, E  # @line L4
    dgam = f_tr / (E + K + H)  # @line L5
    sgn = 1 if xi > 0 else -1
    sig = sig_tr - E * dgam * sgn  # @line L6
    new = (eps_p + dgam * sgn, alpha + dgam, q + H * dgam * sgn)  # @line L7
    tangent = E * (K + H) / (E + K + H)  # @line L8
    return sig, new, tangent


def _trace(a):
    return a[0][0] + a[1][1] + a[2][2]


def dev(a):
    """Return the deviatoric part of a 3 by 3 tensor."""
    t = _trace(a) / 3
    return [[a[i][j] - (t if i == j else 0) for j in range(3)] for i in range(3)]


def tnorm(a):
    """Return the Frobenius norm sqrt(a : a)."""
    return math.sqrt(sum(a[i][j] ** 2 for i in range(3) for j in range(3)))


def zero_state():
    """Return the virgin state (eps_p, alpha, beta) for radial_return."""
    z = [[0.0] * 3 for _ in range(3)]
    return (z, 0.0, [row[:] for row in z])


def radial_return(eps, state, kappa, mu, sy, K=0.0, H=0.0):
    """Return (sigma, new_state, tangent, dgamma) for J2 plasticity at total strain eps.

    state = (eps_p, alpha, beta): plastic strain tensor, equivalent plastic
    strain and back stress. The yield function is
    f = |dev(sigma) - beta| - sqrt(2/3) (sy + K alpha),
    with linear isotropic (K) and kinematic (H) hardening.
    """
    eps_p, alpha, beta = state
    e = dev(eps)
    s_tr = [[2 * mu * (e[i][j] - eps_p[i][j]) for j in range(3)] for i in range(3)]  # @line L1
    xi = [[s_tr[i][j] - beta[i][j] for j in range(3)] for i in range(3)]
    nxi = tnorm(xi)
    r = math.sqrt(2 / 3)
    f_tr = nxi - r * (sy + K * alpha)  # @line L2
    p = kappa * _trace(eps)
    if f_tr <= 0:  # @line L3
        sig = [[s_tr[i][j] + (p if i == j else 0) for j in range(3)] for i in range(3)]
        return sig, state, elastic_tangent(kappa, mu), 0.0  # @line L4
    dgam = f_tr / (2 * mu + 2 / 3 * (K + H))  # @line L5
    n = [[xi[i][j] / nxi for j in range(3)] for i in range(3)]
    sig = [[s_tr[i][j] - 2 * mu * dgam * n[i][j] + (p if i == j else 0) for j in range(3)] for i in range(3)]  # @line L6
    new = (
        [[eps_p[i][j] + dgam * n[i][j] for j in range(3)] for i in range(3)],
        alpha + r * dgam,
        [[beta[i][j] + 2 / 3 * H * dgam * n[i][j] for j in range(3)] for i in range(3)],
    )  # @line L7
    theta = 1 - 2 * mu * dgam / nxi
    theta_bar = 1 / (1 + (K + H) / (3 * mu)) - (1 - theta)
    tangent = _tangent(kappa, mu, theta, theta_bar, n)  # @line L8
    return sig, new, tangent, dgam


def _delta(i, j):
    return 1.0 if i == j else 0.0


def _tangent(kappa, mu, theta, theta_bar, n):
    c = [[0.0] * 9 for _ in range(9)]
    for i in range(3):
        for j in range(3):
            for k in range(3):
                for l in range(3):
                    sym = 0.5 * (_delta(i, k) * _delta(j, l) + _delta(i, l) * _delta(j, k))
                    idev = sym - _delta(i, j) * _delta(k, l) / 3
                    c[3 * i + j][3 * k + l] = (
                        kappa * _delta(i, j) * _delta(k, l) + 2 * mu * theta * idev - 2 * mu * theta_bar * n[i][j] * n[k][l]
                    )
    return c


def elastic_tangent(kappa, mu):
    """Return the isotropic elastic tangent as a 9 by 9 list."""
    z = [[0.0] * 3 for _ in range(3)]
    return _tangent(kappa, mu, 1.0, 0.0, z)


def yield_value(sig, state, sy, K=0.0):
    """Return f(sigma, state) = |dev(sigma) - beta| - sqrt(2/3)(sy + K alpha)."""
    _, alpha, beta = state
    s = dev(sig)
    return tnorm([[s[i][j] - beta[i][j] for j in range(3)] for i in range(3)]) - math.sqrt(2 / 3) * (sy + K * alpha)


def bar_newton(areas, lengths, u_end, E, sy, K=0, H=0, consistent=True, tol=1e-12, maxit=50):
    """Solve a bar of elements in series, fixed at the left end, with a prescribed end displacement.

    Each element has one strain. The unknowns are the interior node displacements.
    Return (stresses, number of Newton iterations). With consistent=False the
    elastic modulus is used as the tangent, as in the initial stiffness method.
    """
    m = len(areas)
    states = [(0, 0, 0)] * m
    u = [u_end * sum(lengths[: i + 1]) / sum(lengths) for i in range(m)]  # node 1 .. m, last fixed
    for it in range(maxit):
        res = [0.0] * (m - 1)
        kt = [[0.0] * (m - 1) for _ in range(m - 1)]
        sig = []
        for e in range(m):
            left = u[e - 1] if e > 0 else 0.0
            strain = (u[e] - left) / lengths[e]
            s, _, tan = return_map_1d(strain, states[e], E, sy, K, H)
            sig.append(s)
            k = (tan if consistent else E) * areas[e] / lengths[e]
            # internal force of element e on its left node (e - 1) and right node (e)
            for a, sign in ((e - 1, -1), (e, 1)):
                if 0 <= a < m - 1:
                    res[a] += sign * s * areas[e]
                    for b, sign2 in ((e - 1, -1), (e, 1)):
                        if 0 <= b < m - 1:
                            kt[a][b] += sign * sign2 * k
        if max(abs(x) for x in res) <= tol * max(abs(x) * a for x, a in zip(sig, areas)):
            return sig, it
        du = _solve_dense(kt, res)
        for a in range(m - 1):
            u[a] -= du[a]
    raise RuntimeError("Newton did not converge")


def _solve_dense(a, b):
    n = len(b)
    a = [row[:] + [b[i]] for i, row in enumerate(a)]
    for k in range(n):
        p = max(range(k, n), key=lambda i: abs(a[i][k]))
        a[k], a[p] = a[p], a[k]
        for i in range(k + 1, n):
            f = a[i][k] / a[k][k]
            for j in range(k, n + 1):
                a[i][j] -= f * a[k][j]
    x = [0.0] * n
    for i in range(n - 1, -1, -1):
        x[i] = (a[i][n] - sum(a[i][j] * x[j] for j in range(i + 1, n))) / a[i][i]
    return x
test_return_mapping_algorithm.py 171 lines
# SPDX-License-Identifier: MIT
# Part of https://algorithm.tamnd.com/return-mapping-algorithm/. The authors are listed in prov/PD9SMC.jsonl.

import math
import random
from fractions import Fraction as Fr

from return_mapping_algorithm import (
    bar_newton,
    dev,
    radial_return,
    return_map_1d,
    tnorm,
    yield_value,
    zero_state,
)

E, SY, KI, HK = 200.0, 0.25, 10.0, 5.0
KAPPA, MU = 160.0, 80.0


def test_1d_exact_fractions():
    # E = 100, sy = 1, K = 10, H = 0: strain 0.03 from the virgin state.
    sig, (ep, al, q), tan = return_map_1d(Fr(3, 100), (Fr(0), Fr(0), Fr(0)), Fr(100), Fr(1), Fr(10), Fr(0))
    assert sig == Fr(1) + Fr(10) * al
    assert ep == al == Fr(2, 110)
    assert sig == Fr(13, 11)
    assert tan == Fr(1000, 110)


def test_1d_elastic_step_unchanged():
    state = (0.001, 0.001, 0.0)
    sig, new, tan = return_map_1d(0.002, state, E, SY, KI, HK)
    assert new == state and tan == E and sig == E * 0.001


def test_1d_monotone_loading_is_exact_for_any_step():
    # Bilinear exact response: sigma = sy + Et (eps - eps_y) after first yield.
    et = E * (KI + HK) / (E + KI + HK)
    eps_y = SY / E
    for nsteps in (1, 3, 50):
        state = (0.0, 0.0, 0.0)
        for k in range(1, nsteps + 1):
            eps = 0.01 * k / nsteps
            sig, state, _ = return_map_1d(eps, state, E, SY, KI, HK)
        assert abs(sig - (SY + et * (0.01 - eps_y))) < 1e-12


def test_1d_bauschinger_with_kinematic_hardening():
    # Pure kinematic hardening: the elastic range keeps its width 2 sy and moves with the back stress.
    state = (0.0, 0.0, 0.0)
    sig_max, state, _ = return_map_1d(0.01, state, E, SY, 0.0, HK)
    # unload elastically until the reverse yield stress sig_max - 2 sy
    eps = 0.01 - (2 * SY - 1e-9) / E
    sig, st2, tan = return_map_1d(eps, state, E, SY, 0.0, HK)
    assert st2 == state and tan == E
    sig, st3, tan = return_map_1d(eps - 1e-4, state, E, SY, 0.0, HK)
    assert st3 != state
    assert abs(sig - (sig_max - 2 * SY)) < 1e-3


def random_sym(rng, scale):
    a = [[rng.uniform(-scale, scale) for _ in range(3)] for _ in range(3)]
    return [[(a[i][j] + a[j][i]) / 2 for j in range(3)] for i in range(3)]


def test_3d_consistency_and_normality():
    rng = random.Random(1)
    for _ in range(20):
        state = zero_state()
        eps = random_sym(rng, 0.01)
        sig, new, _, dgam = radial_return(eps, state, KAPPA, MU, SY, KI, HK)
        assert dgam > 0
        # the new stress is on the new yield surface
        assert abs(yield_value(sig, new, SY, KI)) < 1e-12
        # the plastic strain increment is deviatoric and parallel to dev(sigma) - beta
        dep = new[0]
        assert abs(dep[0][0] + dep[1][1] + dep[2][2]) < 1e-14
        s = dev(sig)
        xi = [[s[i][j] - new[2][i][j] for j in range(3)] for i in range(3)]
        nx, nd = tnorm(xi), tnorm(dep)
        assert all(abs(xi[i][j] / nx - dep[i][j] / nd) < 1e-12 for i in range(3) for j in range(3))
        # the pressure is elastic
        assert abs((sig[0][0] + sig[1][1] + sig[2][2]) / 3 - KAPPA * (eps[0][0] + eps[1][1] + eps[2][2])) < 1e-12


def test_3d_elastic_steps_unchanged():
    rng = random.Random(2)
    state = zero_state()
    for _ in range(10):
        eps = random_sym(rng, 1e-4)
        sig, new, _, dgam = radial_return(eps, state, KAPPA, MU, SY, KI, HK)
        assert dgam == 0 and new is state
        assert yield_value(sig, state, SY, KI) <= 0


def test_3d_consistent_tangent_against_finite_differences():
    rng = random.Random(3)
    base_state = zero_state()
    # a plastic start state
    _, base_state, _, _ = radial_return(random_sym(rng, 0.005), base_state, KAPPA, MU, SY, KI, HK)
    eps = random_sym(rng, 0.01)
    sig, _, c, dgam = radial_return(eps, base_state, KAPPA, MU, SY, KI, HK)
    assert dgam > 0
    h = 1e-7
    worst = 0.0
    for k in range(3):
        for l in range(k, 3):
            ep = [row[:] for row in eps]
            em = [row[:] for row in eps]
            # a symmetric perturbation: add h to the (k, l) and (l, k) entries
            for (a, b) in {(k, l), (l, k)}:
                ep[a][b] += h
                em[a][b] -= h
            sp, _, _, _ = radial_return(ep, base_state, KAPPA, MU, SY, KI, HK)
            sm, _, _, _ = radial_return(em, base_state, KAPPA, MU, SY, KI, HK)
            for i in range(3):
                for j in range(3):
                    fd = (sp[i][j] - sm[i][j]) / (2 * h)
                    an = c[3 * i + j][3 * k + l] + (c[3 * i + j][3 * l + k] if k != l else 0)
                    worst = max(worst, abs(fd - an))
    assert worst < 1e-5 * (KAPPA + MU)


def test_3d_proportional_path_is_step_independent():
    # A proportional deviatoric strain path keeps n fixed; then one step equals many steps.
    e0 = [[0.004, 0.001, 0.0], [0.001, -0.003, 0.002], [0.0, 0.002, -0.001]]
    finals = []
    for nsteps in (1, 7, 40):
        state = zero_state()
        for k in range(1, nsteps + 1):
            eps = [[e0[i][j] * k / nsteps for j in range(3)] for i in range(3)]
            sig, state, _, _ = radial_return(eps, state, KAPPA, MU, SY, KI, HK)
        finals.append(sig)
    for s in finals[1:]:
        assert max(abs(s[i][j] - finals[0][i][j]) for i in range(3) for j in range(3)) < 1e-12


def test_3d_nonproportional_path_first_order():
    # Tension then shear: backward Euler is exact for the discrete equations, but the
    # stress after a nonproportional path depends on the step, with an O(dt) error.
    def run(nsteps):
        state = zero_state()
        for k in range(1, nsteps + 1):
            t = k / nsteps
            eps = [[0.004, 0.006 * t, 0.0], [0.006 * t, -0.002, 0.0], [0.0, 0.0, -0.002]]
            sig, state, _, _ = radial_return(eps, state, KAPPA, MU, SY, KI, HK)
        return sig

    ref = run(20480)
    errs = []
    for ns in (20, 40, 80, 160):
        s = run(ns)
        errs.append(max(abs(s[i][j] - ref[i][j]) for i in range(3) for j in range(3)))
    orders = [math.log2(errs[i] / errs[i + 1]) for i in range(len(errs) - 1)]
    assert all(abs(q - 1) < 0.2 for q in orders), orders


def test_bar_newton_quadratic_with_consistent_tangent():
    areas = [1.0, 0.8, 1.2, 1.0]
    lengths = [1.0, 1.0, 1.0, 1.0]
    sig_c, it_c = bar_newton(areas, lengths, 0.02, E, SY, KI, HK, consistent=True)
    sig_e, it_e = bar_newton(areas, lengths, 0.02, E, SY, KI, HK, consistent=False, maxit=2000)
    forces = [s * a for s, a in zip(sig_c, areas)]
    assert max(forces) - min(forces) < 1e-9
    assert all(abs(x - y) < 1e-8 for x, y in zip(sig_c, sig_e))
    # the response is piecewise linear: once every element is on the right branch,
    # Newton with the consistent tangent is exact in one more step
    assert it_c <= 3
    # the elastic tangent gives a linear rate with factor about 1 - Et / E
    assert it_e > 100

History

Wilkins in 1964 brought the stress back to the von Mises surface along the radius in his hydrodynamic codes, which gave radial return its name. Krieg and Krieg in 1977 compared the accuracy of radial return with other integration methods for perfect plasticity. Simo and Taylor in 1985 showed that the tangent must be the derivative of the discrete map, and that with this consistent tangent the global Newton method converges quadratically. Ortiz and Simo in 1986 analysed the cutting plane variant. Simo and Hughes in 1998 put the theory of return mapping, closest point projection and their tangents into one book.

References

  1. J. C. Simo and T. J. R. Hughes, Computational Inelasticity, Springer, 1998, Chapter 1 (the one-dimensional return mapping) and Chapter 3 (radial return for J2 flow theory and its consistent tangent)
  2. J. C. Simo and R. L. Taylor, Consistent tangent operators for rate-independent elastoplasticity, Computer Methods in Applied Mechanics and Engineering 48(1) (1985) 101-118, the tangent obtained by linearizing the discrete return map, and the quadratic convergence of the global Newton method
  3. R. D. Krieg and D. B. Krieg, Accuracies of numerical solution methods for the elastic-perfectly plastic model, Journal of Pressure Vessel Technology 99(4) (1977) 510-515, the accuracy of radial return and of other integration methods for von Mises plasticity
  4. M. Ortiz and J. C. Simo, An analysis of a new class of integration algorithms for elastoplastic constitutive relations, International Journal for Numerical Methods in Engineering 23(3) (1986) 353-366, the cutting plane variant, which needs no second derivatives of the yield function

About this page

The build computes these levels from the evidence in the repository. Each row says what the next level needs. Read what the levels mean.

LadderLevelWhat the next level needs
Human proofH1 sketch
  • a full proof of time.worst
  • a full proof of space.extra
LeanL0 no Lean part
  • name a Lean module in the lean field (07)
Code (python)I0 not checked yet
  • the tests did not run in this build
VisualV0 none
  • add viz/scene.ts or a figure (10)
WritingW2 basic
  • a scene preset for the example