From d02cb823eb4299460e7084cd8b466341a64e70f4 Mon Sep 17 00:00:00 2001 From: Jamal-dev <70589612+Jamal-dev@users.noreply.github.com> Date: Sat, 23 Sep 2023 22:19:25 +0200 Subject: [PATCH 01/18] Neo-Hok model example --- docs/examples/umat_neoHok_ttb.f | 123 ++++++++++++++++++++++++++++++++ 1 file changed, 123 insertions(+) create mode 100644 docs/examples/umat_neoHok_ttb.f diff --git a/docs/examples/umat_neoHok_ttb.f b/docs/examples/umat_neoHok_ttb.f new file mode 100644 index 0000000..b7d6d21 --- /dev/null +++ b/docs/examples/umat_neoHok_ttb.f @@ -0,0 +1,123 @@ + include 'ttb/ttb_library.f' + + SUBROUTINE UMAT(STRESS,STATEV,DDSDDE,SSE,SPD,SCD, + 1 RPL,DDSDDT,DRPLDE,DRPLDT, + 2 STRAN,DSTRAN,TIME,DTIME,TEMP,DTEMP,PREDEF,DPRED,CMNAME, + 3 NDI,NSHR,NTENS,NSTATV,PROPS,NPROPS,COORDS,DROT,PNEWDT, + 4 CELENT,DFGRD0,DFGRD1,NOEL,NPT,LAYER,KSPT,JSTEP,KINC) + + ! ABAQUS UMAT: Nearly-Incompressible Neo-Hookean Material + ! Example for usage of Tensor Toolbox + ! capability: 3D analysis, axisymmetric? + ! Formulation: Total Lagrange with push forward for Abaqus + ! Andreas Dutzler, 2018-07-22, Graz University of Technology + + + + use Tensor + !implicit none + INCLUDE 'ABA_PARAM.INC' + + + CHARACTER*80 CMNAME + DIMENSION STRESS(NTENS),STATEV(NSTATV), + 1 DDSDDE(NTENS,NTENS),DDSDDT(NTENS),DRPLDE(NTENS), + 2 STRAN(NTENS),DSTRAN(NTENS),TIME(2),PREDEF(1),DPRED(1), + 3 PROPS(NPROPS),COORDS(3),DROT(3,3),DFGRD0(3,3),DFGRD1(3,3), + 4 JSTEP(4) + + PARAMETER(ZERO=0.D0, ONE=1.D0, TWO=2.D0, THREE=3.D0, FOUR=4.D0) + + type(Tensor2) :: F1 + real(kind=8) :: J,kappa,C10 + + type(Tensor2) :: C1,invC1,S1,Eye, Cbar, Sbar, S_iso + type(Tensor4) :: C4, P4, CijklBar, Cijkl, Cijkl_iso, Cijkl_vol + type(Tensor4) :: Proj_tilda + + ! material parameters + C10=PROPS(2) + D1 =PROPS(1) + kappa = ONE/D1 + + + Eye = identity2(Eye) + F1 = dfgrd1(1:3,1:3) + + J = det(F1) + + ! right cauchy-green deformation tensor and it's inverse + C1 = transpose(F1)*F1 + + invC1 = inv(C1) ! faster method: invC1 = inv(C1,J**2) + dUdJ = kappa*(J-1)*TWO + ddUdJdJ = kappa*TWO + dUdI1bar = C10 + dUdI2bar = ZERO + ! double derivatives + ddUdI1bardI1bar = ZERO + ddUdI1bardI2bar = ZERO + ddUdI2bardI2bar = ZERO + invariance_I1 = tr(C1) + + Cbar = J**(-2./3.)*C1 + invariance_I1Bar = tr(Cbar) + gama1Bar = TWO * (dUdI1bar + invariance_I1Bar * dUdI2bar) + gama2Bar = -TWO * dUdI2bar + Sbar = gama1Bar * Eye + gama2Bar * Cbar + p = dUdJ + p_tilda = p + J * ddUdJdJ + P4 = identity4(Eye)-1./3.*(invC1.dya.C1) + S_iso = J**(-2./3.)*(P4**Sbar) + S1 = J * p * invC1 + S_iso + + + + ! push forward to cauchy stress used in abaqus + S1 = piola(F1,S1)/J + + + deltaBar1 = FOUR * (ddUdI1bardI1bar+ + * TWO*invariance_I1Bar*ddUdI1bardI2bar + + * dUdI2bar + + * invariance_I1Bar*invariance_I1Bar*ddUdI2bardI2bar) + deltaBar2 = -FOUR * (ddUdI1bardI2bar + + * invariance_I1Bar*ddUdI2bardI2bar) + deltaBar3 = FOUR * ddUdI2bardI2bar + deltaBar4 = -FOUR * dUdI2bar + CijklBar = deltaBar1 * (Eye.dya.Eye) + deltaBar2 *( (Eye.dya.Cbar) + * + (Cbar.dya.Eye)) + deltaBar3 * (Cbar.dya.Cbar) + * + deltaBar4 * identity4(Eye) + CijklBar = J**(-4./3.)*CijklBar + Proj_tilda = identity4(invC1) - 1./3.*(invC1.dya.invC1) + trace_withC = tr(SBar*CBar) + + Cijkl_iso = P4**CijklBar**transpose(P4) + 2./3.* + * trace_withC*Proj_tilda - 2./3.*( + * (invC1.dya.S_iso) + (S_iso.dya.invC1)) + Cijkl_vol = (J * p_tilda) * ((invC1.dya.invC1))-(2.*J*p) + * *(identity4(invC1)) + + Cijkl = Cijkl_iso + Cijkl_vol + + + + + + + + ! push forward to jaumann tangent of cauchy stress for abaqus + C4 = piola(F1,Cijkl)/J + (S1.cdya.Eye)+(Eye.cdya.S1) + + + + + + ! output as array + + STRESS(1:ntens) = asabqarray(voigt(S1),ntens) + DDSDDE(1:ntens,1:ntens) = asabqarray(voigt(C4),ntens,ntens) + + + return + end \ No newline at end of file From 59274513db38a0133a04b21110dc204e5ceb0a63 Mon Sep 17 00:00:00 2001 From: Jamal <70589612+Jamal-dev@users.noreply.github.com> Date: Sat, 23 Sep 2023 22:30:28 +0200 Subject: [PATCH 02/18] Update umat_nh_ttb_simple.f Removed typo error at line 60 and commented implicit none --- docs/examples/umat_nh_ttb_simple.f | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/docs/examples/umat_nh_ttb_simple.f b/docs/examples/umat_nh_ttb_simple.f index 93f7ac2..9b44ec6 100644 --- a/docs/examples/umat_nh_ttb_simple.f +++ b/docs/examples/umat_nh_ttb_simple.f @@ -13,7 +13,7 @@ SUBROUTINE UMAT(STRESS,STATEV,DDSDDE,SSE,SPD,SCD, ! Andreas Dutzler, 2018-07-22, Graz University of Technology use Tensor - implicit none + !implicit none INCLUDE 'ABA_PARAM.INC' @@ -57,11 +57,11 @@ SUBROUTINE UMAT(STRESS,STATEV,DDSDDE,SSE,SPD,SCD, * - 2.*kappa*(J-1)*J* (invC1.cdya.invC1) ! push forward to jaumann tangent of cauchy stress for abaqus - C4 = piola(F1,C4)/detF1 + (S1.cdya.Eye)+(Eye.cdya.S1) + C4 = piola(F1,C4)/J + (S1.cdya.Eye)+(Eye.cdya.S1) ! output as array STRESS(1:ntens) = asabqarray(voigt(S1),ntens) DDSDDE(1:ntens,1:ntens) = asabqarray(voigt(C4),ntens,ntens) return - end \ No newline at end of file + end From 3e7ed88eecf99c830c9cc056b0483f1fd09d0055 Mon Sep 17 00:00:00 2001 From: Andreas Dutzler Date: Sun, 24 Sep 2023 15:43:23 +0200 Subject: [PATCH 03/18] Ex. Abaqus Umat Neo-Hooke: Change author --- docs/examples/umat_neoHok_ttb.f | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/docs/examples/umat_neoHok_ttb.f b/docs/examples/umat_neoHok_ttb.f index b7d6d21..0e8f321 100644 --- a/docs/examples/umat_neoHok_ttb.f +++ b/docs/examples/umat_neoHok_ttb.f @@ -8,12 +8,12 @@ SUBROUTINE UMAT(STRESS,STATEV,DDSDDE,SSE,SPD,SCD, ! ABAQUS UMAT: Nearly-Incompressible Neo-Hookean Material ! Example for usage of Tensor Toolbox - ! capability: 3D analysis, axisymmetric? + ! capability: 3D analysis ! Formulation: Total Lagrange with push forward for Abaqus - ! Andreas Dutzler, 2018-07-22, Graz University of Technology - + ! Jamal Bhatti, 2023-09-23, Leibniz University Hannover + + - use Tensor !implicit none INCLUDE 'ABA_PARAM.INC' From 143e71ba191aaeaa5a79d369e6df06e14e0e60e2 Mon Sep 17 00:00:00 2001 From: Andreas Dutzler Date: Sun, 24 Sep 2023 15:46:09 +0200 Subject: [PATCH 04/18] Rename the Neo-Hookean Umat Ex. for Abaqus for consistent names with other examples --- docs/examples/{umat_neoHok_ttb.f => umat_nh_ttb.f} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename docs/examples/{umat_neoHok_ttb.f => umat_nh_ttb.f} (100%) diff --git a/docs/examples/umat_neoHok_ttb.f b/docs/examples/umat_nh_ttb.f similarity index 100% rename from docs/examples/umat_neoHok_ttb.f rename to docs/examples/umat_nh_ttb.f From f54406dc90446c245fafcc1d31fc1c99e72e88c4 Mon Sep 17 00:00:00 2001 From: Andreas Dutzler Date: Sun, 24 Sep 2023 16:28:18 +0200 Subject: [PATCH 05/18] Ex. Umat Neo-Hooke: Remove unused variables, change bulk modulus The Neo-Hookean material formulation does not depend on the second invariant. The bulk modulus is kappa=2/D1. --- docs/examples/umat_nh_ttb.f | 94 +++++++++++-------------------------- 1 file changed, 27 insertions(+), 67 deletions(-) diff --git a/docs/examples/umat_nh_ttb.f b/docs/examples/umat_nh_ttb.f index 0e8f321..4a71ba5 100644 --- a/docs/examples/umat_nh_ttb.f +++ b/docs/examples/umat_nh_ttb.f @@ -29,95 +29,55 @@ SUBROUTINE UMAT(STRESS,STATEV,DDSDDE,SSE,SPD,SCD, PARAMETER(ZERO=0.D0, ONE=1.D0, TWO=2.D0, THREE=3.D0, FOUR=4.D0) type(Tensor2) :: F1 - real(kind=8) :: J,kappa,C10 - - type(Tensor2) :: C1,invC1,S1,Eye, Cbar, Sbar, S_iso - type(Tensor4) :: C4, P4, CijklBar, Cijkl, Cijkl_iso, Cijkl_vol - type(Tensor4) :: Proj_tilda + type(Tensor4) :: P4 + real(kind=8) :: J,kappa,C10,D1,dUdI1bar,dUdJ,ddUdJdJ,p,ptilde + + ! also possible as types Tensor2s and Tensor4s + type(Tensor2) :: C1,invC1,S1,Eye,Cbar,Sbar,Siso + type(Tensor4) :: C4,P4tilde,C4iso,C4vol ! material parameters - C10=PROPS(2) - D1 =PROPS(1) - kappa = ONE/D1 - + C10 = PROPS(2) + D1 = PROPS(1) + kappa = TWO/D1 Eye = identity2(Eye) F1 = dfgrd1(1:3,1:3) - J = det(F1) ! right cauchy-green deformation tensor and it's inverse C1 = transpose(F1)*F1 - - invC1 = inv(C1) ! faster method: invC1 = inv(C1,J**2) - dUdJ = kappa*(J-1)*TWO - ddUdJdJ = kappa*TWO + invC1 = inv(C1) + + dUdJ = kappa*(J-1) + ddUdJdJ = kappa + dUdI1bar = C10 - dUdI2bar = ZERO - ! double derivatives - ddUdI1bardI1bar = ZERO - ddUdI1bardI2bar = ZERO - ddUdI2bardI2bar = ZERO - invariance_I1 = tr(C1) - + Cbar = J**(-2./3.)*C1 - invariance_I1Bar = tr(Cbar) - gama1Bar = TWO * (dUdI1bar + invariance_I1Bar * dUdI2bar) - gama2Bar = -TWO * dUdI2bar - Sbar = gama1Bar * Eye + gama2Bar * Cbar + Sbar = TWO*dUdI1bar*Eye + p = dUdJ - p_tilda = p + J * ddUdJdJ + ptilde = p + J * ddUdJdJ P4 = identity4(Eye)-1./3.*(invC1.dya.C1) - S_iso = J**(-2./3.)*(P4**Sbar) - S1 = J * p * invC1 + S_iso - - - - ! push forward to cauchy stress used in abaqus - S1 = piola(F1,S1)/J + Siso = J**(-2./3.)*(P4**Sbar) + ! push forward of pk2 stress to cauchy stress + S1 = piola(F1,J*p*invC1 + Siso)/J - deltaBar1 = FOUR * (ddUdI1bardI1bar+ - * TWO*invariance_I1Bar*ddUdI1bardI2bar + - * dUdI2bar + - * invariance_I1Bar*invariance_I1Bar*ddUdI2bardI2bar) - deltaBar2 = -FOUR * (ddUdI1bardI2bar + - * invariance_I1Bar*ddUdI2bardI2bar) - deltaBar3 = FOUR * ddUdI2bardI2bar - deltaBar4 = -FOUR * dUdI2bar - CijklBar = deltaBar1 * (Eye.dya.Eye) + deltaBar2 *( (Eye.dya.Cbar) - * + (Cbar.dya.Eye)) + deltaBar3 * (Cbar.dya.Cbar) - * + deltaBar4 * identity4(Eye) - CijklBar = J**(-4./3.)*CijklBar - Proj_tilda = identity4(invC1) - 1./3.*(invC1.dya.invC1) - trace_withC = tr(SBar*CBar) + P4tilde = identity4(invC1) - 1./3.*(invC1.dya.invC1) - Cijkl_iso = P4**CijklBar**transpose(P4) + 2./3.* - * trace_withC*Proj_tilda - 2./3.*( - * (invC1.dya.S_iso) + (S_iso.dya.invC1)) - Cijkl_vol = (J * p_tilda) * ((invC1.dya.invC1))-(2.*J*p) - * *(identity4(invC1)) + C4iso = 2./3.*tr(Sbar*Cbar)*P4tilde - 2./3.*( + * (invC1.dya.S_iso) + (S_iso.dya.invC1)) + C4vol = (J*ptilde) * ((invC1.dya.invC1))-(2.*J*p) + * *(identity4(invC1)) - Cijkl = Cijkl_iso + Cijkl_vol - - - - - - - ! push forward to jaumann tangent of cauchy stress for abaqus - C4 = piola(F1,Cijkl)/J + (S1.cdya.Eye)+(Eye.cdya.S1) + C4 = piola(F1,C4iso+C4vol)/J + (S1.cdya.Eye)+(Eye.cdya.S1) - - - - ! output as array - STRESS(1:ntens) = asabqarray(voigt(S1),ntens) DDSDDE(1:ntens,1:ntens) = asabqarray(voigt(C4),ntens,ntens) - return end \ No newline at end of file From ae57fec16ca72820670340249160ebcc6ed12c95 Mon Sep 17 00:00:00 2001 From: Andreas Dutzler Date: Sun, 24 Sep 2023 16:42:34 +0200 Subject: [PATCH 06/18] Update umat_nh_ttb.f --- docs/examples/umat_nh_ttb.f | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/examples/umat_nh_ttb.f b/docs/examples/umat_nh_ttb.f index 4a71ba5..4feba20 100644 --- a/docs/examples/umat_nh_ttb.f +++ b/docs/examples/umat_nh_ttb.f @@ -68,7 +68,7 @@ SUBROUTINE UMAT(STRESS,STATEV,DDSDDE,SSE,SPD,SCD, P4tilde = identity4(invC1) - 1./3.*(invC1.dya.invC1) C4iso = 2./3.*tr(Sbar*Cbar)*P4tilde - 2./3.*( - * (invC1.dya.S_iso) + (S_iso.dya.invC1)) + * (invC1.dya.Siso) + (S_iso.dya.invC1)) C4vol = (J*ptilde) * ((invC1.dya.invC1))-(2.*J*p) * *(identity4(invC1)) From a68c5e9828e58a64e0ebb65415487c052ef1a93a Mon Sep 17 00:00:00 2001 From: Andreas Dutzler Date: Sun, 24 Sep 2023 16:42:50 +0200 Subject: [PATCH 07/18] Update umat_nh_ttb.f --- docs/examples/umat_nh_ttb.f | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/examples/umat_nh_ttb.f b/docs/examples/umat_nh_ttb.f index 4feba20..d3fdbe7 100644 --- a/docs/examples/umat_nh_ttb.f +++ b/docs/examples/umat_nh_ttb.f @@ -68,7 +68,7 @@ SUBROUTINE UMAT(STRESS,STATEV,DDSDDE,SSE,SPD,SCD, P4tilde = identity4(invC1) - 1./3.*(invC1.dya.invC1) C4iso = 2./3.*tr(Sbar*Cbar)*P4tilde - 2./3.*( - * (invC1.dya.Siso) + (S_iso.dya.invC1)) + * (invC1.dya.Siso) + (Siso.dya.invC1)) C4vol = (J*ptilde) * ((invC1.dya.invC1))-(2.*J*p) * *(identity4(invC1)) From bab1cf79e427283e1b04d01a688ad7eb29f7a34c Mon Sep 17 00:00:00 2001 From: Andreas Dutzler Date: Sun, 24 Sep 2023 16:46:50 +0200 Subject: [PATCH 08/18] Update CHANGELOG.md --- CHANGELOG.md | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index e8b4d04..ba4d162 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -3,6 +3,12 @@ All notable changes to this project will be documented in this file. The format ## [Unreleased] +### Added +- Add a new example for a Neo-Hookean Abaqus Umat. + +### Fixed +- Fix typo in example for Abaqus Umat. + ## [2.0.0] - 2023-07-23 ### Added From 141c2ec24cb90478d7a54a269462fa0b1f066c61 Mon Sep 17 00:00:00 2001 From: Andreas Dutzler Date: Sun, 24 Sep 2023 16:46:59 +0200 Subject: [PATCH 09/18] Update CHANGELOG.md --- CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index ba4d162..abad8f0 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,7 +7,7 @@ All notable changes to this project will be documented in this file. The format - Add a new example for a Neo-Hookean Abaqus Umat. ### Fixed -- Fix typo in example for Abaqus Umat. +- Fix a typo in example for Abaqus Umat. ## [2.0.0] - 2023-07-23 From 299908945c7171791b5858adb96d49f929b5db5a Mon Sep 17 00:00:00 2001 From: Andreas Dutzler Date: Sun, 24 Sep 2023 16:47:39 +0200 Subject: [PATCH 10/18] Update CHANGELOG.md --- CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index abad8f0..9d11829 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,7 +7,7 @@ All notable changes to this project will be documented in this file. The format - Add a new example for a Neo-Hookean Abaqus Umat. ### Fixed -- Fix a typo in example for Abaqus Umat. +- Fix a typo in the Neo-Hooke example for Abaqus Umat. ## [2.0.0] - 2023-07-23 From f0c408f388d059a401aa19bcd42023f62bae1a13 Mon Sep 17 00:00:00 2001 From: Andreas Dutzler Date: Sun, 24 Sep 2023 23:26:15 +0200 Subject: [PATCH 11/18] Enforce `implicit none` --- docs/examples/umat_nh_ttb.f | 5 +---- docs/examples/umat_nh_ttb_simple.f | 2 +- 2 files changed, 2 insertions(+), 5 deletions(-) diff --git a/docs/examples/umat_nh_ttb.f b/docs/examples/umat_nh_ttb.f index d3fdbe7..b705eb1 100644 --- a/docs/examples/umat_nh_ttb.f +++ b/docs/examples/umat_nh_ttb.f @@ -12,13 +12,10 @@ SUBROUTINE UMAT(STRESS,STATEV,DDSDDE,SSE,SPD,SCD, ! Formulation: Total Lagrange with push forward for Abaqus ! Jamal Bhatti, 2023-09-23, Leibniz University Hannover - - use Tensor - !implicit none + implicit none INCLUDE 'ABA_PARAM.INC' - CHARACTER*80 CMNAME DIMENSION STRESS(NTENS),STATEV(NSTATV), 1 DDSDDE(NTENS,NTENS),DDSDDT(NTENS),DRPLDE(NTENS), diff --git a/docs/examples/umat_nh_ttb_simple.f b/docs/examples/umat_nh_ttb_simple.f index 9b44ec6..7b9c913 100644 --- a/docs/examples/umat_nh_ttb_simple.f +++ b/docs/examples/umat_nh_ttb_simple.f @@ -13,7 +13,7 @@ SUBROUTINE UMAT(STRESS,STATEV,DDSDDE,SSE,SPD,SCD, ! Andreas Dutzler, 2018-07-22, Graz University of Technology use Tensor - !implicit none + implicit none INCLUDE 'ABA_PARAM.INC' From 196d5ae7d678f58e58888fc0a7ed7830c49e757d Mon Sep 17 00:00:00 2001 From: Andreas Dutzler Date: Mon, 25 Sep 2023 22:15:34 +0200 Subject: [PATCH 12/18] Docs: Ex. Umat Neo-Hooke - disable implicit none --- docs/examples/umat_nh_ttb.f | 7 ++++++- docs/examples/umat_nh_ttb_simple.f | 8 ++++++-- 2 files changed, 12 insertions(+), 3 deletions(-) diff --git a/docs/examples/umat_nh_ttb.f b/docs/examples/umat_nh_ttb.f index b705eb1..80684dc 100644 --- a/docs/examples/umat_nh_ttb.f +++ b/docs/examples/umat_nh_ttb.f @@ -13,7 +13,12 @@ SUBROUTINE UMAT(STRESS,STATEV,DDSDDE,SSE,SPD,SCD, ! Jamal Bhatti, 2023-09-23, Leibniz University Hannover use Tensor - implicit none + + ! `implicit none` is not supported if 'ABA_PARAM.INC' is included + ! declare all double-variables which start with `i,j,k,l,m,n` + ! - otherwise they will be integers + + ! implicit none INCLUDE 'ABA_PARAM.INC' CHARACTER*80 CMNAME diff --git a/docs/examples/umat_nh_ttb_simple.f b/docs/examples/umat_nh_ttb_simple.f index 7b9c913..5aa5b08 100644 --- a/docs/examples/umat_nh_ttb_simple.f +++ b/docs/examples/umat_nh_ttb_simple.f @@ -13,8 +13,12 @@ SUBROUTINE UMAT(STRESS,STATEV,DDSDDE,SSE,SPD,SCD, ! Andreas Dutzler, 2018-07-22, Graz University of Technology use Tensor - implicit none - + + ! `implicit none` is not supported if 'ABA_PARAM.INC' is included + ! declare all double-variables which start with `i,j,k,l,m,n` + ! - otherwise they will be integers + + ! implicit none INCLUDE 'ABA_PARAM.INC' CHARACTER*80 CMNAME From 66d3b60dd7d9f5d4bcb60217dff3a119b107d6fb Mon Sep 17 00:00:00 2001 From: Andreas Dutzler Date: Mon, 25 Sep 2023 22:23:27 +0200 Subject: [PATCH 13/18] Update umat_nh_ttb.f Add the reference --- docs/examples/umat_nh_ttb.f | 3 +++ 1 file changed, 3 insertions(+) diff --git a/docs/examples/umat_nh_ttb.f b/docs/examples/umat_nh_ttb.f index 80684dc..e481780 100644 --- a/docs/examples/umat_nh_ttb.f +++ b/docs/examples/umat_nh_ttb.f @@ -10,6 +10,9 @@ SUBROUTINE UMAT(STRESS,STATEV,DDSDDE,SSE,SPD,SCD, ! Example for usage of Tensor Toolbox ! capability: 3D analysis ! Formulation: Total Lagrange with push forward for Abaqus + ! Reference: Holzapfel, G. (2001). NONLINEAR SOLID MECHANICS. + ! A Continuum Approach for Engineering. + ! ! Jamal Bhatti, 2023-09-23, Leibniz University Hannover use Tensor From 689ac90318e6e3979e1b997ba6b8687c4f2dc7f6 Mon Sep 17 00:00:00 2001 From: Andreas Dutzler Date: Mon, 25 Sep 2023 23:07:27 +0200 Subject: [PATCH 14/18] Revert to the original added Umat example --- docs/examples/umat_nh_ttb.f | 64 ++++++++++++++++++++++++++----------- 1 file changed, 45 insertions(+), 19 deletions(-) diff --git a/docs/examples/umat_nh_ttb.f b/docs/examples/umat_nh_ttb.f index e481780..0586a73 100644 --- a/docs/examples/umat_nh_ttb.f +++ b/docs/examples/umat_nh_ttb.f @@ -35,11 +35,14 @@ SUBROUTINE UMAT(STRESS,STATEV,DDSDDE,SSE,SPD,SCD, type(Tensor2) :: F1 type(Tensor4) :: P4 - real(kind=8) :: J,kappa,C10,D1,dUdI1bar,dUdJ,ddUdJdJ,p,ptilde + real(kind=8) :: J,kappa,C10,D1,dUdI1bar,dUdI2bar,dUdJ,ddUdJdJ + real(kind=8) :: ddUdI1bardI1bar,ddUdI2bardI2bar,ddUdI1bardI2bar + real(kind=8) :: p,ptilde,gama1bar,gama2bar,I1bar,trSbarCbar + real(kind=8) :: delta1bar,delta2bar,delta3bar,delta4bar ! also possible as types Tensor2s and Tensor4s type(Tensor2) :: C1,invC1,S1,Eye,Cbar,Sbar,Siso - type(Tensor4) :: C4,P4tilde,C4iso,C4vol + type(Tensor4) :: C4,C4bar,P4tilde,C4iso,C4vol ! material parameters C10 = PROPS(2) @@ -51,38 +54,61 @@ SUBROUTINE UMAT(STRESS,STATEV,DDSDDE,SSE,SPD,SCD, J = det(F1) ! right cauchy-green deformation tensor and it's inverse - C1 = transpose(F1)*F1 + C1 = transpose(F1) * F1 invC1 = inv(C1) - - dUdJ = kappa*(J-1) + + dUdJ = kappa * (J-1) ddUdJdJ = kappa - + dUdI1bar = C10 - - Cbar = J**(-2./3.)*C1 - Sbar = TWO*dUdI1bar*Eye + dUdI2bar = ZERO + + ! double derivatives + ddUdI1bardI1bar = ZERO + ddUdI1bardI2bar = ZERO + ddUdI2bardI2bar = ZERO + + Cbar = J**(-2./3.) * C1 + I1bar = tr(Cbar) + gama1bar = TWO * (dUdI1bar + tr(Cbar) * dUdI2bar) + gama2bar = -TWO * dUdI2bar + Sbar = gama1bar * Eye + gama2bar * Cbar p = dUdJ ptilde = p + J * ddUdJdJ - P4 = identity4(Eye)-1./3.*(invC1.dya.C1) - Siso = J**(-2./3.)*(P4**Sbar) + P4 = identity4(Eye) - 1./3. * (invC1.dya.C1) + Siso = J**(-2./3.) * (P4**Sbar) ! push forward of pk2 stress to cauchy stress - S1 = piola(F1,J*p*invC1 + Siso)/J + S1 = piola(F1, J * p * invC1 + Siso) / J + + ! coefficients for the elasticity tensor + delta1bar = FOUR * (ddUdI1bardI1bar + + * TWO * I1bar * ddUdI1bardI2bar + dUdI2bar + + * I1bar**2 * ddUdI2bardI2bar) + delta2bar = -FOUR * (ddUdI1bardI2bar + I1bar * ddUdI2bardI2bar) + delta3bar = FOUR * ddUdI2bardI2bar + delta4bar = -FOUR * dUdI2bar + + C4bar = J**(-4./3.) * (delta1bar * (Eye.dya.Eye) + * + delta2bar * ((Eye.dya.Cbar) + (Cbar.dya.Eye)) + * + delta3bar * (Cbar.dya.Cbar) + * + delta4bar * identity4(Eye)) - P4tilde = identity4(invC1) - 1./3.*(invC1.dya.invC1) + P4tilde = identity4(invC1) - 1./3. * (invC1.dya.invC1) - C4iso = 2./3.*tr(Sbar*Cbar)*P4tilde - 2./3.*( - * (invC1.dya.Siso) + (Siso.dya.invC1)) - C4vol = (J*ptilde) * ((invC1.dya.invC1))-(2.*J*p) - * *(identity4(invC1)) + C4iso = P4**C4bar**transpose(P4) + * + 2./3. * tr(Sbar*Cbar) * P4tilde + * - 2./3. * ((invC1.dya.Siso) + (Siso.dya.invC1)) + C4vol = (J * ptilde) * ((invC1.dya.invC1)) - (2. * J * p) + * * (identity4(invC1)) ! push forward to jaumann tangent of cauchy stress for abaqus - C4 = piola(F1,C4iso+C4vol)/J + (S1.cdya.Eye)+(Eye.cdya.S1) + C4 = piola(F1, C4iso + C4vol) / J + (S1.cdya.Eye) + (Eye.cdya.S1) ! output as array STRESS(1:ntens) = asabqarray(voigt(S1),ntens) DDSDDE(1:ntens,1:ntens) = asabqarray(voigt(C4),ntens,ntens) return - end \ No newline at end of file + end From 1d696368040d5cb8fb045efa02284cd5a8c331f5 Mon Sep 17 00:00:00 2001 From: Andreas Dutzler Date: Mon, 25 Sep 2023 23:12:37 +0200 Subject: [PATCH 15/18] Typo in comments --- docs/examples/umat_nh_ttb.f | 2 +- docs/examples/umat_nh_ttb_simple.f | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/examples/umat_nh_ttb.f b/docs/examples/umat_nh_ttb.f index 0586a73..03152a4 100644 --- a/docs/examples/umat_nh_ttb.f +++ b/docs/examples/umat_nh_ttb.f @@ -17,7 +17,7 @@ SUBROUTINE UMAT(STRESS,STATEV,DDSDDE,SSE,SPD,SCD, use Tensor - ! `implicit none` is not supported if 'ABA_PARAM.INC' is included + ! `implicit none` is not supported if 'ABA_PARAM.INC' is included. ! declare all double-variables which start with `i,j,k,l,m,n` ! - otherwise they will be integers diff --git a/docs/examples/umat_nh_ttb_simple.f b/docs/examples/umat_nh_ttb_simple.f index 5aa5b08..078fa61 100644 --- a/docs/examples/umat_nh_ttb_simple.f +++ b/docs/examples/umat_nh_ttb_simple.f @@ -14,7 +14,7 @@ SUBROUTINE UMAT(STRESS,STATEV,DDSDDE,SSE,SPD,SCD, use Tensor - ! `implicit none` is not supported if 'ABA_PARAM.INC' is included + ! `implicit none` is not supported if 'ABA_PARAM.INC' is included. ! declare all double-variables which start with `i,j,k,l,m,n` ! - otherwise they will be integers From 8f12340f3d657bd935d3e6ee79d6bf2e5b022377 Mon Sep 17 00:00:00 2001 From: Andreas Dutzler Date: Mon, 25 Sep 2023 23:20:03 +0200 Subject: [PATCH 16/18] Update umat_nh_ttb.f --- docs/examples/umat_nh_ttb.f | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/docs/examples/umat_nh_ttb.f b/docs/examples/umat_nh_ttb.f index 03152a4..9cc870f 100644 --- a/docs/examples/umat_nh_ttb.f +++ b/docs/examples/umat_nh_ttb.f @@ -6,7 +6,8 @@ SUBROUTINE UMAT(STRESS,STATEV,DDSDDE,SSE,SPD,SCD, 3 NDI,NSHR,NTENS,NSTATV,PROPS,NPROPS,COORDS,DROT,PNEWDT, 4 CELENT,DFGRD0,DFGRD1,NOEL,NPT,LAYER,KSPT,JSTEP,KINC) - ! ABAQUS UMAT: Nearly-Incompressible Neo-Hookean Material + ! ABAQUS UMAT: Easy-to-extend Nearly-Incompressible Neo-Hookean +! Material Formulation ! Example for usage of Tensor Toolbox ! capability: 3D analysis ! Formulation: Total Lagrange with push forward for Abaqus @@ -37,7 +38,7 @@ SUBROUTINE UMAT(STRESS,STATEV,DDSDDE,SSE,SPD,SCD, type(Tensor4) :: P4 real(kind=8) :: J,kappa,C10,D1,dUdI1bar,dUdI2bar,dUdJ,ddUdJdJ real(kind=8) :: ddUdI1bardI1bar,ddUdI2bardI2bar,ddUdI1bardI2bar - real(kind=8) :: p,ptilde,gama1bar,gama2bar,I1bar,trSbarCbar + real(kind=8) :: p,ptilde,gama1bar,gama2bar,I1bar real(kind=8) :: delta1bar,delta2bar,delta3bar,delta4bar ! also possible as types Tensor2s and Tensor4s From cff91c544dab2db4c63c03bbbb08c5b6d917e763 Mon Sep 17 00:00:00 2001 From: Andreas Dutzler Date: Mon, 25 Sep 2023 23:22:26 +0200 Subject: [PATCH 17/18] Update umat_nh_ttb.f --- docs/examples/umat_nh_ttb.f | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/examples/umat_nh_ttb.f b/docs/examples/umat_nh_ttb.f index 9cc870f..63578f1 100644 --- a/docs/examples/umat_nh_ttb.f +++ b/docs/examples/umat_nh_ttb.f @@ -58,7 +58,7 @@ SUBROUTINE UMAT(STRESS,STATEV,DDSDDE,SSE,SPD,SCD, C1 = transpose(F1) * F1 invC1 = inv(C1) - dUdJ = kappa * (J-1) + dUdJ = kappa * (J - 1) ddUdJdJ = kappa dUdI1bar = C10 @@ -71,7 +71,7 @@ SUBROUTINE UMAT(STRESS,STATEV,DDSDDE,SSE,SPD,SCD, Cbar = J**(-2./3.) * C1 I1bar = tr(Cbar) - gama1bar = TWO * (dUdI1bar + tr(Cbar) * dUdI2bar) + gama1bar = TWO * (dUdI1bar + I1bar * dUdI2bar) gama2bar = -TWO * dUdI2bar Sbar = gama1bar * Eye + gama2bar * Cbar From ae0503f2640d64cf61ecb3736b9097e4b7bd34e5 Mon Sep 17 00:00:00 2001 From: Andreas Dutzler Date: Mon, 25 Sep 2023 23:23:51 +0200 Subject: [PATCH 18/18] Update CHANGELOG.md --- CHANGELOG.md | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 9d11829..33c06fe 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,10 +4,11 @@ All notable changes to this project will be documented in this file. The format ## [Unreleased] ### Added -- Add a new example for a Neo-Hookean Abaqus Umat. +- Add a new example for an easy-to-extend Neo-Hookean Abaqus Umat. ### Fixed -- Fix a typo in the Neo-Hooke example for Abaqus Umat. +- Fix a typo in the basic Neo-Hooke example for Abaqus Umat. +- Disable `implicit none` for the basic Neo-Hooke example for Abaqus Umat (not supported in combination with `INCLUDE 'ABA_PARAM.INC'`). ## [2.0.0] - 2023-07-23