38 type(hecmwst_local_mesh) :: hecmesh
39 type(hecmwst_matrix) :: hecmat
41 real(kind=kreal),
intent(in) :: time
42 real(kind=kreal),
intent(in) :: tincr
44 real(kind=kreal),
intent(in),
optional :: coef(6)
46 integer(kind=kint) :: ndof, itype, is, ie, ic_type, nn, icel, iis, i, j, in, jn
47 integer(kind=kint) :: nodlocal(fstrsolid%max_ncon)
48 real(kind=kreal) :: stiff_mat(fstrsolid%max_ncon_stf*6, fstrsolid%max_ncon_stf*6)
49 real(kind=kreal) :: mass_mat(20*6, 20*6), damp_mat(20*6, 20*6)
50 real(kind=kreal) :: mat(20*6, 20*6), lumped(20*6)
51 real(kind=kreal) :: tt(fstrsolid%max_ncon), ecoord(3,fstrsolid%max_ncon)
52 real(kind=kreal) :: u(6,fstrsolid%max_ncon), du(6*20), u_prev(6,fstrsolid%max_ncon)
53 real(kind=kreal) :: veca(20*6), vecb(20*6)
54 real(kind=kreal) :: acc(20*6), vec(20*6), df(20*6)
55 real(kind=kreal) :: a1, a2, a3, b1, b2, b3
56 type(tmaterial),
pointer :: material
59 is_dynamic =
present(fstrdynamic) .and.
present(coef)
61 call hecmw_mat_clear( hecmat )
63 fstrsolid%DFORCE = 0.0d0
64 a1 = coef(1); a2 = coef(2); a3 = coef(3)
65 b1 = coef(4); b2 = coef(5); b3 = coef(6)
71 do itype = 1, hecmesh%n_elem_type
72 is = hecmesh%elem_type_index(itype-1) + 1
73 ie = hecmesh%elem_type_index(itype )
74 ic_type = hecmesh%elem_type_item(itype)
77 if (hecmw_is_etype_link(ic_type)) cycle
78 if (hecmw_is_etype_patch(ic_type)) cycle
80 nn = hecmw_get_max_node(ic_type)
92 iis = hecmesh%elem_node_index(icel-1)
93 nn = hecmesh%elem_node_index(icel) - iis
96 in = hecmesh%elem_node_item(iis+j)
99 ecoord(i,j) = hecmesh%node(3*(in-1)+i)
102 du(ndof*(j-1)+i) = fstrsolid%dunode(ndof*(in-1)+i)
103 u(i,j) = fstrsolid%unode(ndof*(in-1)+i) + du(ndof*(j-1)+i)
104 u_prev(i,j) = fstrsolid%unode(ndof*(in-1)+i)
106 if( is_dynamic )
then
108 vec(ndof*(j-1)+i) = fstrdynamic%VEL(ndof*(in-1)+i,1)
109 acc(ndof*(j-1)+i) = fstrdynamic%ACC(ndof*(in-1)+i,1)
112 if( fstrsolid%TEMP_ngrp_tot > 0 .or. fstrsolid%TEMP_irres > 0 )
then
113 tt(j) = fstrsolid%temperature( nodlocal(j) )
120 call stf_dummy( ndof, nn, ecoord(:,1:nn), u(1:3,1:nn), &
121 & stiff_mat(1:nn*ndof, 1:nn*ndof), fstrsolid%elements(icel) )
122 call hecmw_mat_ass_elem(hecmat, nn, nodlocal, stiff_mat)
132 time, tincr, is_dynamic, fstrsolid, hecmesh, icel, nodlocal, &
133 stiff_mat, mass_mat, damp_mat, lumped )
136 if( is_dynamic )
then
139 veca(i) = -a3*du(i) + a2*vec(i) + a1*acc(i)
140 vecb(i) = -b3*du(i) + b2*vec(i) + b1*acc(i)
144 material => fstrsolid%elements(icel)%gausses(1)%pMaterial
146 a3, b3, veca, vecb, stiff_mat, mass_mat, damp_mat, mat, df )
148 call hecmw_mat_ass_elem(hecmat, nn, nodlocal, mat)
153 fstrsolid%DFORCE(ndof*(nodlocal(j)-1)+i) = fstrsolid%DFORCE(ndof*(nodlocal(j)-1)+i)+df(ndof*(j-1)+i)
158 call hecmw_mat_ass_elem(hecmat, nn, nodlocal, stiff_mat)
178 time, tincr, is_dynamic, fstrSOLID, hecMESH, icel, nodLOCAL, &
179 stiff_mat, mass_mat, damp_mat, lumped )
188 integer(kind=kint),
intent(in) :: ic_type, ndof
189 integer(kind=kint),
intent(inout) :: nn
190 real(kind=kreal),
intent(in) :: ecoord(:,:), u(:,:), u_prev(:,:), tt(:)
191 real(kind=kreal),
intent(in) :: time, tincr
192 logical,
intent(in) :: is_dynamic
194 type(hecmwst_local_mesh),
intent(in) :: hecMESH
195 integer(kind=kint),
intent(in) :: icel
196 integer(kind=kint),
intent(inout) :: nodLOCAL(:)
197 real(kind=kreal),
intent(inout) :: stiff_mat(:,:), mass_mat(:,:), damp_mat(:,:)
198 real(kind=kreal),
intent(inout) :: lumped(:)
200 type(tmaterial),
pointer :: material
201 integer(kind=kint) :: isect, ihead, cdsys_id, sec_opt, i, j
202 real(kind=kreal) :: coords(3,3), thick
203 real(kind=kreal) :: rho, length, surf
204 real(kind=kreal) :: shell_nddisp(6,fstrsolid%max_ncon)
205 real(kind=kreal) :: shell_du(6,fstrsolid%max_ncon)
206 real(kind=kreal) :: shell_director(3,fstrsolid%max_ncon)
207 real(kind=kreal) :: shell_ref_director(3,fstrsolid%max_ncon)
210 isect = hecmesh%section_ID(icel)
211 ihead = hecmesh%section%sect_R_index(isect-1)
212 cdsys_id = hecmesh%section%sect_orien_ID(isect)
213 sec_opt = hecmesh%section%sect_opt(isect)
215 if( cdsys_id > 0 )
call get_coordsys(cdsys_id, hecmesh, fstrsolid, coords)
217 material => fstrsolid%elements(icel)%gausses(1)%pMaterial
218 thick = hecmesh%section%sect_R_item(ihead+1)
220 if( ic_type==241 .or. ic_type==242 .or. ic_type==231 .or. ic_type==232 .or. ic_type==2322)
then
221 if( material%nlgeom_flag /= infinitesimal )
call createmat_abort( ic_type, 2 )
222 call stf_c2( ic_type, nn, ecoord(1:2,1:nn), fstrsolid%elements(icel)%gausses(:), thick, &
223 stiff_mat(1:nn*ndof,1:nn*ndof), fstrsolid%elements(icel)%iset, u(1:2,1:nn) )
225 if( is_dynamic )
call mass_c2(ic_type, nn, ecoord(1:2,1:nn), fstrsolid%elements(icel)%gausses, &
226 sec_opt, thick, mass_mat, lumped)
228 elseif( ic_type==301 )
then
229 call stf_c1( ic_type, nn, ecoord(:,1:nn), thick, fstrsolid%elements(icel)%gausses(:), &
230 stiff_mat(1:nn*ndof,1:nn*ndof), u(1:3,1:nn) )
232 elseif( ic_type==361 )
then
233 if( fstrsolid%sections(isect)%elemopt361 ==
kel361fi )
then
234 call stf_c3( ic_type, nn, ecoord(:,1:nn), fstrsolid%elements(icel)%gausses(:), &
235 stiff_mat(1:nn*ndof,1:nn*ndof), cdsys_id, coords, time, tincr, u(1:3,1:nn), tt(1:nn) )
236 else if( fstrsolid%sections(isect)%elemopt361 ==
kel361bbar )
then
237 call stf_c3d8bbar( ic_type, nn, ecoord(:,1:nn), fstrsolid%elements(icel)%gausses(:), &
238 stiff_mat(1:nn*ndof,1:nn*ndof), cdsys_id, coords, time, tincr, u(1:3,1:nn), tt(1:nn) )
239 else if( fstrsolid%sections(isect)%elemopt361 ==
kel361ic )
then
240 call stf_c3d8ic( ic_type, nn, ecoord(:,1:nn), fstrsolid%elements(icel)%gausses(:), &
241 stiff_mat(1:nn*ndof,1:nn*ndof), cdsys_id, coords, time, tincr, u(1:3,1:nn), &
242 fstrsolid%elements(icel)%aux, tt(1:nn) )
243 else if( fstrsolid%sections(isect)%elemopt361 ==
kel361fbar )
then
244 call stf_c3d8fbar( ic_type, nn, ecoord(:,1:nn), fstrsolid%elements(icel)%gausses(:), &
245 stiff_mat(1:nn*ndof,1:nn*ndof), cdsys_id, coords, time, tincr, u(1:3,1:nn), tt(1:nn) )
248 if( is_dynamic )
call mass_c3(ic_type, nn, ecoord(1:3,1:nn), fstrsolid%elements(icel)%gausses, mass_mat, lumped)
250 elseif( ic_type==341 .or. ic_type==351 .or. ic_type==342 .or. ic_type==352 .or. ic_type==362 )
then
253 if( .not. (ic_type==341 .and. fstrsolid%sections(isect)%elemopt341 ==
kel341sesns) )
then
254 call stf_c3( ic_type, nn, ecoord(:,1:nn), fstrsolid%elements(icel)%gausses(:), &
255 stiff_mat(1:nn*ndof,1:nn*ndof), cdsys_id, coords, time, tincr, u(1:3,1:nn), tt(1:nn) )
258 if( is_dynamic )
call mass_c3(ic_type, nn, ecoord(1:3,1:nn), fstrsolid%elements(icel)%gausses, mass_mat, lumped)
260 else if( ic_type == 511 )
then
261 call stf_connector( ic_type, nn, ecoord(:,1:nn), fstrsolid%elements(icel)%gausses(:), &
262 stiff_mat(1:nn*ndof,1:nn*ndof), u(1:3,1:nn), tt(1:nn))
264 if( is_dynamic )
call dmp_connector( ic_type, nn, ecoord(:,1:nn), fstrsolid%elements(icel)%gausses(:), &
265 damp_mat(1:nn*ndof,1:nn*ndof), u(1:3,1:nn), tt(1:nn))
267 else if( ic_type == 611 )
then
268 if( material%nlgeom_flag /= infinitesimal )
call createmat_abort( ic_type, 2 )
269 call stf_beam(ic_type, nn, ecoord, hecmesh%section%sect_R_item(ihead+1:), &
270 & material%variables(m_youngs), material%variables(m_poisson), stiff_mat(1:nn*ndof,1:nn*ndof))
272 if( is_dynamic )
then
273 surf = hecmesh%section%sect_R_item(ihead+4)
275 rho = material%variables(m_density)
276 call mass_beam(surf, length, rho, mass_mat)
279 else if( ic_type == 641 )
then
280 if( material%nlgeom_flag /= infinitesimal )
call createmat_abort( ic_type, 2 )
281 call stf_beam_641(ic_type, nn, ecoord, fstrsolid%elements(icel)%gausses(:), &
282 & hecmesh%section%sect_R_item(ihead+1:), stiff_mat(1:nn*ndof,1:nn*ndof))
284 if( is_dynamic )
then
285 surf = hecmesh%section%sect_R_item(ihead+4)
287 rho = material%variables(m_density)
291 else if( ( ic_type == 741 ) .or. ( ic_type == 743 ) .or. ( ic_type == 731 ) )
then
293 shell_du(:, :) = 0.0d0
295 do i = 1, min(ndof, 6)
296 shell_du(i,j) = fstrsolid%dunode(ndof*(nodlocal(j)-1)+i)
300 shell_nddisp(1:6,1:nn) )
303 shell_ref_director(1:3,1:nn) )
304 call stf_shell_mitc(ic_type, nn, ndof, ecoord(1:3,1:nn), fstrsolid%elements(icel)%gausses(:), &
305 & stiff_mat(1:nn*ndof,1:nn*ndof), thick, 0, nddisp=shell_nddisp(1:6,1:nn), &
306 & element=fstrsolid%elements(icel), nddirector=shell_director(1:3,1:nn), &
307 & ndrefdirector=shell_ref_director(1:3,1:nn))
309 if( material%nlgeom_flag /= infinitesimal )
call createmat_abort( ic_type, 2 )
310 call stf_shell_mitc(ic_type, nn, ndof, ecoord(1:3,1:nn), fstrsolid%elements(icel)%gausses(:), &
311 & stiff_mat(1:nn*ndof,1:nn*ndof), thick, 0)
314 if( is_dynamic )
then
315 rho = material%variables(m_density)
316 call mass_shell(ic_type, nn, ecoord(1:3,1:nn), rho, thick, fstrsolid%elements(icel)%gausses, mass_mat, lumped)
319 else if( ic_type == 761 )
then
320 if( material%nlgeom_flag /= infinitesimal )
call createmat_abort( ic_type, 2 )
321 call stf_shell_mitc(731, 3, 6, ecoord(1:3,1:3), fstrsolid%elements(icel)%gausses(:), &
322 & stiff_mat(1:nn*ndof,1:nn*ndof), thick, 2)
324 if( is_dynamic )
then
326 rho = material%variables(m_density)
327 call mass_s3(surf, thick, rho, mass_mat)
330 else if( ic_type == 781 )
then
331 if( material%nlgeom_flag /= infinitesimal )
call createmat_abort( ic_type, 2 )
332 call stf_shell_mitc(741, 4, 6, ecoord(1:3,1:4), fstrsolid%elements(icel)%gausses(:), &
333 & stiff_mat(1:nn*ndof,1:nn*ndof), thick, 1)
335 if( is_dynamic )
then
337 rho = material%variables(m_density)
338 call mass_s4(surf, thick, rho, mass_mat)
341 elseif( ic_type==3414 )
then
342 if( material%mtype /= incomp_newtonian )
call createmat_abort( ic_type, 3, material%mtype )
343 call stf_c3_vp( ic_type, nn, ecoord(:,1:nn), fstrsolid%elements(icel)%gausses(:), &
344 stiff_mat(1:nn*ndof,1:nn*ndof), tincr, u_prev(1:4,1:nn) )
346 else if( ic_type == 881 .or. ic_type == 891 )
then
347 call stf_c3d4_sesns( ic_type, nn, nodlocal, ecoord(:,1:nn), fstrsolid%elements(icel)%gausses(:), &
348 stiff_mat, cdsys_id, coords, time, tincr, u(1:3,1:nn), tt(1:nn) )
351 call createmat_abort( ic_type, 1 )
364 a3, b3, vecA, vecB, stiff_mat, mass_mat, damp_mat, mat, df )
366 integer(kind=kint),
intent(in) :: ic_type, nn, ndof
367 type(tmaterial),
pointer,
intent(in) :: material
369 real(kind=kreal),
intent(in) :: a3, b3
370 real(kind=kreal),
intent(in) :: veca(:), vecb(:)
371 real(kind=kreal),
intent(in) :: stiff_mat(:,:), mass_mat(:,:), damp_mat(:,:)
372 real(kind=kreal),
intent(out) :: mat(:,:), df(:)
374 integer(kind=kint) :: i, j
375 real(kind=kreal) :: ray_m, ray_k, c1, c2
376 real(kind=kreal) :: vecc(20*6), kb(20*6)
378 if( material%is_elem_Rayleigh_damping )
then
379 ray_m = material%variables(m_damping_rm)
380 ray_k = material%variables(m_damping_rk)
382 ray_m = fstrdynamic%ray_m
383 ray_k = fstrdynamic%ray_k
391 mat(j,i) = c1*stiff_mat(j,i) + c2*mass_mat(j,i)
394 if( ic_type == 511 )
then
397 mat(j,i) = mat(j,i) + b3*damp_mat(j,i)
404 vecc(i) = veca(i) + ray_m*vecb(i)
410 kb(i) = kb(i) + stiff_mat(i,j)*vecb(j)
415 df(1:nn*ndof) = matmul(mass_mat(1:nn*ndof,1:nn*ndof), vecc(1:nn*ndof))
417 df(i) = df(i) + ray_k*kb(i)
419 if( ic_type == 511 )
then
422 df(i) = df(i) + damp_mat(i,j)*vecb(j)
429 subroutine createmat_abort( ic_type, flag, mtype )
430 integer(kind=kint),
intent(in) :: ic_type
431 integer(kind=kint),
intent(in) :: flag
432 integer(kind=kint),
intent(in),
optional :: mtype
435 write(*,*)
'###ERROR### : Element type not supported for static analysis'
436 else if( flag == 2 )
then
437 write(*,*)
'###ERROR### : Element type not supported for nonlinear static analysis'
438 else if( flag == 3 )
then
439 write(*,*)
'###ERROR### : This element is not supported for this material'
441 write(*,*)
' ic_type = ', ic_type
442 if(
present(mtype) )
write(*,*)
' mtype = ', mtype
443 call hecmw_abort(hecmw_comm_get_comm())
444 end subroutine createmat_abort
This module contains subroutines used in 3d eigen analysis for.
real(kind=kreal) function get_length(ecoord)
subroutine mass_beam_33(surf, length, rho, mass)
subroutine mass_c2(etype, nn, ecoord, gausses, sec_opt, thick, mass, lumped, temperature)
real(kind=kreal) function get_face4(ecoord)
subroutine mass_s3(surf, thick, rho, mass)
real(kind=kreal) function get_face3(ecoord)
subroutine mass_c3(etype, nn, ecoord, gausses, mass, lumped, temperature)
subroutine mass_beam(surf, length, rho, mass)
subroutine mass_s4(surf, thick, rho, mass)
This module defined elemact data and function.
integer, parameter kelact_inactive
subroutine stf_dummy(ndof, nn, ecoord, u, stiff, element)
This module assembles the tangent stiffness matrix and, in the implicit dynamic case,...
subroutine, public fstr_creatematrix_and_dampingforce(hecMESH, hecMAT, fstrSOLID, time, tincr, fstrDYNAMIC, coef)
Assemble the system matrix and, optionally, the dynamic damping force.
subroutine calc_stiff_and_mass_elem(ic_type, nn, ndof, ecoord, u, u_prev, tt, time, tincr, is_dynamic, fstrSOLID, hecMESH, icel, nodLOCAL, stiff_mat, mass_mat, damp_mat, lumped)
Compute the element tangent stiffness (and, in the dynamic case, the element mass and connector dampi...
subroutine calc_damping_mat_and_force_elem(ic_type, nn, ndof, material, fstrDYNAMIC, a3, b3, vecA, vecB, stiff_mat, mass_mat, damp_mat, mat, df)
Combine the element K, M (and connector C) into the effective dynamic system matrix mat = c1*K + c2*M...
Shared predicates for finite-rotation nodal kinematics.
logical function, public fstr_uses_finite_rotation_kinematics(etype, nn, material)
Finite-rotation nodal kinematics for NLGEOM.
subroutine, public fstr_get_shell_trial_directors(fstrSOLID, thick, nn, nodLOCAL, directors)
Half-thickness director from the current Newton trial frame (dtriad).
subroutine, public fstr_ensure_finite_rotation_state(hecMESH, fstrSOLID, ndof)
Build the per-node reference frames once, by averaging element shell triads at shared nodes....
subroutine, public fstr_get_shell_reference_directors(fstrSOLID, thick, nn, nodLOCAL, directors)
Half-thickness director from the fixed reference frame (ref_triad).
This module defines common data and basic structures for analysis.
integer(kind=kint), parameter kel361bbar
subroutine get_coordsys(cdsys_ID, hecMESH, fstrSOLID, coords)
This subroutine fetch coords defined by local coordinate system.
integer(kind=kint), parameter kel341sesns
integer(kind=kint), parameter kel361fi
integer(kind=kint), parameter kel361ic
integer(kind=kint), parameter kel361fbar
subroutine shellcomposenodaldisplacement(ndof, nn, disp_old, disp_inc, disp_new)
This modules just summarizes all modules used in static analysis.
This modules defines a structure to record history dependent parameter in static analysis.
Data for DYNAMIC ANSLYSIS (fstrDYNAMIC)