Rocstar  1.0
Rocstar multiphysics simulation application
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
arruda_boyce.cauchy.f90
Go to the documentation of this file.
1 !*********************************************************************
2 !* Illinois Open Source License *
3 !* *
4 !* University of Illinois/NCSA *
5 !* Open Source License *
6 !* *
7 !* Copyright@2008, University of Illinois. All rights reserved. *
8 !* *
9 !* Developed by: *
10 !* *
11 !* Center for Simulation of Advanced Rockets *
12 !* *
13 !* University of Illinois *
14 !* *
15 !* www.csar.uiuc.edu *
16 !* *
17 !* Permission is hereby granted, free of charge, to any person *
18 !* obtaining a copy of this software and associated documentation *
19 !* files (the "Software"), to deal with the Software without *
20 !* restriction, including without limitation the rights to use, *
21 !* copy, modify, merge, publish, distribute, sublicense, and/or *
22 !* sell copies of the Software, and to permit persons to whom the *
23 !* Software is furnished to do so, subject to the following *
24 !* conditions: *
25 !* *
26 !* *
27 !* @ Redistributions of source code must retain the above copyright *
28 !* notice, this list of conditions and the following disclaimers. *
29 !* *
30 !* @ Redistributions in binary form must reproduce the above *
31 !* copyright notice, this list of conditions and the following *
32 !* disclaimers in the documentation and/or other materials *
33 !* provided with the distribution. *
34 !* *
35 !* @ Neither the names of the Center for Simulation of Advanced *
36 !* Rockets, the University of Illinois, nor the names of its *
37 !* contributors may be used to endorse or promote products derived *
38 !* from this Software without specific prior written permission. *
39 !* *
40 !* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, *
41 !* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES *
42 !* OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND *
43 !* NONINFRINGEMENT. IN NO EVENT SHALL THE CONTRIBUTORS OR *
44 !* COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER *
45 !* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, *
46 !* ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE *
47 !* USE OR OTHER DEALINGS WITH THE SOFTWARE. *
48 !*********************************************************************
49 !* Please acknowledge The University of Illinois Center for *
50 !* Simulation of Advanced Rockets in works and publications *
51 !* resulting from this software or its derivatives. *
52 !*********************************************************************
53 SUBROUTINE arruda_boyce_cauchy(F11,F12,F13,F21,F22,F23,F31,F32,F33,&
54  cchy11,cchy22,cchy33,cchy12,cchy13,cchy23,ielem,mu,kappa)
55 
56 !!****f* Rocfrac/Rocfrac/Source/arruda_boyce.cauchy.f90
57 !!
58 !! NAME
59 !! ARRUDA_BOYCE_CAUCHY
60 !!
61 !! FUNCTION
62 !! Arruda-Boyce constitutive model, returns Cauchy Stress
63 !!
64 !! INPUTS
65 !! F11,F12,F13,F21,F22,F23,F31,F32,F33 -- componets
66 !! of the deformation gradient [F]
67 !! mu, kappa -- material parameters
68 !! ielem -- element id number
69 !!
70 !! OUTPUT
71 !! Cchy11, Cchy22, Cchy33,Cchy12,Cchy13,Cchy23 -- componets
72 !! of the Cauchy stress tensor
73 !!
74 !! USES
75 !! rs, Solve_x
76 !!
77 !!
78 !!***
79 
80  IMPLICIT NONE
81 
82 !-- Variables
83  INTEGER :: j,k,l,m,ierr,ielem
84  INTEGER :: istep
85  REAL*8 :: f11,f12,f13,f21,f22,f23,f31,f32,f33
86  REAL*8 :: s11,s22,s33,s12,s13,s23
87  REAL*8 :: shear_modulus
88  REAL*8 :: delta
89  REAL*8 :: fij(3,3), btens(3,3),princ(3,3)
90  REAL*8 :: cij(3,3), bulk, sqrt_n, cr, n
91  REAL*8 :: e_vec(3,3), sigma_a(3),stret(1:3)
92  REAL*8 :: e_val(3), e_chain, xi3, xmu, xxx, xmu_max, xjay
93  REAL*8 :: fv1(3), fv2(3), stretch(3)
94  REAL*8 :: fact
95  REAL*8 :: mu, kappa
96  REAL*8 :: cchy11,cchy22,cchy33,cchy12,cchy13,cchy23
97  REAL*8 :: pa
98  REAL*8 :: sum, sigma(3,3)
99  INTEGER :: jd,kd,id
100 
101 
102 !--(0) initial parameters
103 
104 ! CR : (initial shear modulus)/3
105 ! Bulk : bulk modulus, kappa
106 ! N : chain locking stretch ,for example, N=8
107 
108  cr = mu/3.d0
109 
110  bulk = 1.d0*kappa
111 
112  n = 64.d0
113  sqrt_n = sqrt(n)
114 
115 !-- (1) compute Deformation Gradient Fij
116 
117 ! Passed into Subroutine
118 
119 !
120 !-- (2) obtains the tensor b, left cauchy-green tensor using equation ???
121 !
122  btens(1,1) = f11**2+f12**2+f13**2
123  btens(1,2) = f21*f11+f12*f22+f13*f23
124  btens(1,3) = f31*f11+f12*f32+f13*f33
125  btens(2,1) = btens(1,2)
126  btens(2,2) = f21**2+f22**2+f23**2
127  btens(2,3) = f21*f31+f32*f22+f23*f33
128  btens(3,1) = btens(1,3)
129  btens(3,2) = btens(2,3)
130  btens(3,3) = f31**2+f32**2+f33**2
131 
132 !-- (3) compute eigen values (e_val) and eigen vectors (e_vec) of Cij
133 ! The rs subroutine seems to be more robust then Jacobi
134 !
135 ! option 1
136 
137 ! CALL jacobi(btens,stretch,princ)
138 
139 ! option 2
140 
141  fv1(1:3) = 0.d0
142  fv2(1:3) = 0.d0
143 
144  CALL rs(3,3,btens,stretch,1,princ,fv1,fv2,ierr)
145 
146  IF(ierr .NE. 0) THEN
147  print *,' error occurs at element ', ielem
148  END IF
149 
150 !-- (4) calculate stretch
151 ! Not Needed if used subroutine 'jacobi'
152 
153  stretch(1:3) = sqrt(stretch(1:3))
154 
155 !-- (5) compute ramda chain
156 
157  e_chain=sqrt(stretch(1)**2+stretch(2)**2+stretch(3)**2)
158  e_chain=1.0d0/sqrt(3.0d0)*(e_chain)
159 
160 !-- (6) compute I3 and Jay
161 
162  xjay= stretch(1)*stretch(2)*stretch(3)
163  xi3 = (xjay)**2
164 
165 !-- (7) compute xmu
166 
167  xmu = e_chain/sqrt_n
168 
169 !-- (8) Solve for x
170 
171  CALL solve_x(xxx,xmu,ielem,stretch)
172 
173 !-- (9) Compute sigma_A
174 
175  DO k=1,3
176  sigma_a(k)=cr*sqrt_n*(stretch(k)**2-e_chain**2)/ &
177  e_chain*xxx + bulk*log(sqrt(xi3))
178  END DO
179 
180 !-- (10a) Compute Cauchy-stress
181 
182  DO jd = 1,3
183  DO kd = 1,3
184  sum = 0.0d0
185  DO id = 1,3
186  sum = sum + sigma_a(id)*princ(jd,id)*princ(kd,id)
187  ENDDO
188  sigma(jd,kd)=sum
189  ENDDO
190  ENDDO
191 
192  cchy11 = sigma(1,1)
193  cchy22 = sigma(2,2)
194  cchy33 = sigma(3,3)
195  cchy12 = sigma(1,2)
196  cchy23 = sigma(2,3)
197  cchy13 = sigma(1,3)
198  RETURN
199 END SUBROUTINE arruda_boyce_cauchy
200 
FT m(int i, int j) const
Tfloat sum() const
Return the sum of all the pixel values in an image.
Definition: CImg.h:13022
subroutine rs(nm, n, a, w, matz, z, fv1, fv2, ierr)
j indices k indices k
Definition: Indexing.h:6
double sqrt(double d)
Definition: double.h:73
subroutine arruda_boyce_cauchy(F11, F12, F13, F21, F22, F23, F31, F32, F33, Cchy11, Cchy22, Cchy33, Cchy12, Cchy13, Cchy23, ielem, mu, kappa)
const NT & n
RT delta(int i) const
Definition: Direction_2.h:159
virtual std::ostream & print(std::ostream &os) const
j indices j
Definition: Indexing.h:6
unsigned long id(const Leda_like_handle &x)
Definition: Handle.h:107
subroutine solve_x(x, xmu, i, stretch)