13 subroutine dynamic_mat_ass_bc(hecMESH, hecMAT, fstrSOLID ,fstrDYNAMIC, fstrPARAM, fstrMAT, iter, conMAT)
22 type(hecmwst_matrix) :: hecMAT
23 type(hecmwst_local_mesh) :: hecMESH
28 integer,
optional :: iter
29 type(hecmwst_matrix),
optional :: conMAT
31 integer(kind=kint) :: ig0, ig, ityp, NDOF, iS0, iE0, ik, in, idofS, idofE, idof
33 integer(kind=kint) :: flag_u
34 real(kind=kreal) :: rhs, f_t, f_t1
37 integer(kind=kint) :: n_rot, rid, n_nodes
38 type(trotinfo) :: rinfo
39 real(kind=kreal) :: theta, normal(3), direc(3), ccoord(3), cdiff(3), cdiff0(3)
40 real(kind=kreal) :: cdisp(3), cddisp(3)
43 n_rot = fstrsolid%BOUNDARY_ngrp_rot
44 if( n_rot > 0 )
call fstr_rotinfo_init(n_rot, rinfo)
45 fstrsolid%REACTION = 0.d0
51 if( fstrdynamic%idx_eqa == 1 )
then
53 do ig0 = 1, fstrsolid%BOUNDARY_ngrp_tot
54 ig = fstrsolid%BOUNDARY_ngrp_ID(ig0)
55 rhs = fstrsolid%BOUNDARY_ngrp_val(ig0)
57 if(
present(iter) )
then
61 fstrdynamic%i_step = fstrdynamic%i_step-1
62 fstrdynamic%t_curr = fstrdynamic%t_curr - fstrdynamic%t_delta
63 call table_dyn(hecmesh, fstrsolid, fstrdynamic, ig0, f_t1, flag_u)
64 fstrdynamic%i_step = fstrdynamic%i_step+1
65 fstrdynamic%t_curr = fstrdynamic%t_curr + fstrdynamic%t_delta
66 call table_dyn(hecmesh, fstrsolid, fstrdynamic, ig0, f_t, flag_u)
67 rhs = rhs * (f_t-f_t1)
70 call table_dyn(hecmesh, fstrsolid, fstrdynamic, ig0, f_t, flag_u)
74 ityp = fstrsolid%BOUNDARY_ngrp_type(ig0)
76 idofe = ityp - idofs*10
78 is0 = hecmesh%node_group%grp_index(ig-1) + 1
79 ie0 = hecmesh%node_group%grp_index(ig )
81 if( fstrsolid%BOUNDARY_ngrp_rotID(ig0) > 0 )
then
82 rid = fstrsolid%BOUNDARY_ngrp_rotID(ig0)
83 if( .not. rinfo%conds(rid)%active )
then
84 rinfo%conds(rid)%active = .true.
85 rinfo%conds(rid)%center_ngrp_id = fstrsolid%BOUNDARY_ngrp_centerID(ig0)
86 rinfo%conds(rid)%torque_ngrp_id = ig
90 rinfo%conds(rid)%vec(idof-ndof) = rhs
92 rinfo%conds(rid)%vec(idof) = rhs
99 in = hecmesh%node_group%grp_item(ik)
101 do idof = idofs, idofe
102 if(
present(conmat))
then
103 call hecmw_mat_ass_bc(hecmat, in, idof, rhs, conmat)
105 call hecmw_mat_ass_bc(hecmat, in, idof, rhs)
108 .and. fstrparam%nlgeom .and. fstrdynamic%idx_resp == 1 )
then
109 if(
present(conmat))
then
117 fstrsolid%REACTION(ndof*(in-1)+idof) = fstrsolid%QFORCE(ndof*(in-1)+idof)
125 if( .not. rinfo%conds(rid)%active ) cycle
130 if( f_t > 0.d0 )
then
131 ig = rinfo%conds(rid)%center_ngrp_id
133 ccoord(idof) = hecmw_ngrp_get_totalvalue(hecmesh, ig, ndof, idof, hecmesh%node)
134 cdisp(idof) = hecmw_ngrp_get_totalvalue(hecmesh, ig, ndof, idof, fstrsolid%unode)
135 cddisp(idof) = hecmw_ngrp_get_totalvalue(hecmesh, ig, ndof, idof, hecmat%B)
137 ccoord(1:ndof) = ccoord(1:ndof) + cdisp(1:ndof)
140 ig = rinfo%conds(rid)%torque_ngrp_id
141 is0 = hecmesh%node_group%grp_index(ig-1) + 1
142 ie0 = hecmesh%node_group%grp_index(ig )
144 in = hecmesh%node_group%grp_item(ik)
145 if( f_t > 0.d0 )
then
146 cdiff0(1:ndof) = hecmesh%node(ndof*(in-1)+1:ndof*in)+fstrsolid%unode(ndof*(in-1)+1:ndof*in)-ccoord(1:ndof)
147 cdiff(1:ndof) = cdiff0(1:ndof)
151 rhs = cdiff(idof)-cdiff0(idof)+cddisp(idof)
152 if(
present(conmat))
then
153 call hecmw_mat_ass_bc(hecmat, in, idof, rhs, conmat)
155 call hecmw_mat_ass_bc(hecmat, in, idof, rhs)
159 if(
present(conmat))
then
167 fstrsolid%REACTION(ndof*(in-1)+idof) = fstrsolid%QFORCE(ndof*(in-1)+idof)
178 else if( fstrdynamic%idx_eqa == 11 )
then
181 do ig0 = 1, fstrsolid%BOUNDARY_ngrp_tot
182 ig = fstrsolid%BOUNDARY_ngrp_ID(ig0)
183 rhs = fstrsolid%BOUNDARY_ngrp_val(ig0)
185 call table_dyn(hecmesh, fstrsolid, fstrdynamic, ig0, f_t, flag_u)
188 ityp = fstrsolid%BOUNDARY_ngrp_type(ig0)
190 is0 = hecmesh%node_group%grp_index(ig-1) + 1
191 ie0 = hecmesh%node_group%grp_index(ig )
193 idofe = ityp - idofs*10
196 in = hecmesh%node_group%grp_item(ik)
198 do idof = idofs, idofe
199 hecmat%B (ndof*in-(ndof-idof)) = rhs
200 fstrdynamic%VEC1(ndof*in-(ndof-idof)) = 1.0d0
203 fstrsolid%REACTION(ndof*(in-1)+idof) = fstrsolid%QFORCE(ndof*(in-1)+idof)
212 if( n_rot > 0 )
call fstr_rotinfo_finalize(rinfo)
225 type(hecmwst_matrix) :: hecmat
226 type(hecmwst_local_mesh) :: hecMESH
230 integer(kind=kint) :: NDOF, ig0, ig, ityp, iS0, iE0, ik, in, idofS, idofE, idof
231 integer(kind=kint) :: flag_u
232 real(kind=kreal) :: rhs, f_t
237 do ig0 = 1, fstrsolid%BOUNDARY_ngrp_tot
238 ig = fstrsolid%BOUNDARY_ngrp_ID(ig0)
239 rhs = fstrsolid%BOUNDARY_ngrp_val(ig0)
242 call table_dyn(hecmesh, fstrsolid, fstrdynamic, ig0, f_t, flag_u)
245 ityp = fstrsolid%BOUNDARY_ngrp_type(ig0)
247 is0 = hecmesh%node_group%grp_index(ig-1) + 1
248 ie0 = hecmesh%node_group%grp_index(ig )
250 idofe = ityp - idofs*10
253 in = hecmesh%node_group%grp_item(ik)
255 do idof = idofs, idofe
256 fstrdynamic%DISP(ndof*in-(ndof-idof),1) = rhs
274 type(hecmwst_matrix) :: hecmat
275 type(hecmwst_local_mesh) :: hecMESH
278 integer,
optional :: iter
280 integer(kind=kint) :: ig0, ig, ityp, NDOF, iS0, iE0, ik, in, idofS, idofE, idof
282 integer(kind=kint) :: flag_u
283 real(kind=kreal) :: rhs, f_t, f_t1
286 integer(kind=kint) :: n_rot, rid, n_nodes
287 type(trotinfo) :: rinfo
288 real(kind=kreal) :: theta, normal(3), direc(3), ccoord(3), cdiff(3), cdiff0(3)
289 real(kind=kreal) :: cdisp(3), cddisp(3)
292 n_rot = fstrsolid%BOUNDARY_ngrp_rot
293 if( n_rot > 0 )
call fstr_rotinfo_init(n_rot, rinfo)
294 fstrsolid%REACTION = 0.d0
300 do ig0 = 1, fstrsolid%BOUNDARY_ngrp_tot
301 ig = fstrsolid%BOUNDARY_ngrp_ID(ig0)
302 rhs = fstrsolid%BOUNDARY_ngrp_val(ig0)
304 call table_dyn(hecmesh, fstrsolid, fstrdynamic, ig0, f_t, flag_u)
307 ityp = fstrsolid%BOUNDARY_ngrp_type(ig0)
309 is0 = hecmesh%node_group%grp_index(ig-1) + 1
310 ie0 = hecmesh%node_group%grp_index(ig )
312 idofe = ityp - idofs*10
315 in = hecmesh%node_group%grp_item(ik)
317 do idof = idofs, idofe
318 hecmat%B(ndof*in-(ndof-idof)) = rhs*fstrdynamic%VEC1(ndof*in-(ndof-idof))
322 fstrsolid%REACTION(ndof*(in-1)+idof) = fstrsolid%QFORCE(ndof*(in-1)+idof)
327 if( n_rot > 0 )
call fstr_rotinfo_finalize(rinfo)
This module contains functions to set displacement boundary condition in dynamic analysis.
subroutine dynamic_bc_init(hecMESH, hecMAT, fstrSOLID, fstrDYNAMIC)
This subroutine setup initial condition of displacement.
subroutine dynamic_mat_ass_bc(hecMESH, hecMAT, fstrSOLID, fstrDYNAMIC, fstrPARAM, fstrMAT, iter, conMAT)
This subroutine setup disp bundary condition.
subroutine dynamic_explicit_ass_bc(hecMESH, hecMAT, fstrSOLID, fstrDYNAMIC, iter)
This subroutine setup disp boundary condition.
This module defined coomon data and basic structures for analysis.
integer(kind=kint), parameter kcaslagrange
contact analysis algorithm
integer(kind=kint), parameter kststatic
Table of lading step in dynamic analysis.
subroutine table_dyn(hecMESH, fstrSOLID, fstrDYNAMIC, ig0, f_t, flag_u)
This module provides aux functions.
subroutine rotate_3dvector_by_rodrigues_formula(r, v)
Data for DYNAMIC ANSLYSIS (fstrDYNAMIC)
FSTR INNER CONTROL PARAMETERS (fstrPARAM)