35 integer(kind=kint) :: contact_elim, solver_type, loglevel, myrank
42 writelog = (myrank==0 .and. loglevel>0)
44 if( contact_elim==0 )
then
45 if( solver_type==1 )
then
59 if( .not. any_lagrange(hecmesh, heclagmat) ) contact_elim = 1
62 if( contact_elim==1 )
then
63 if( writelog )
write(*,*)
'solve contact with elimination'
66 if( writelog )
write(*,*)
'solve contact without elimination'
67 if( solver_type==1 )
then
68 write(*,*)
'ERROR: iterative solver without elimination not available in contact analysis'
70 elseif( solver_type==2 )
then
72 else if( solver_type==3 )
then
74 elseif( solver_type==5 )
then
76 elseif( solver_type==7 )
then
78 write(*,*)
'ERROR: !SOLVER,METHOD=DIRECTmf not available in parallel contact analysis',&
79 ' without elimination; specify CONTACT_ELIM=1 or use MUMPS or DIRECTmkl instead'
84 write(*,*)
'ERROR: specified solver not available in contact analysis without elimination;',&
85 ' please use MUMPS or DIRECTmkl instead'
99 type (hecmwst_ebc) :: hecebc
100 integer(kind=kint),
intent(out) :: istat
101 real(kind=
kreal),
optional :: rf
102 logical :: is_contact_active
104 real(kind=
kreal) :: factor
105 real(kind=
kreal) :: t1, t2
106 integer(kind=kint) :: ndof
107 integer(kind=kint) :: contact_elim, solver_type
114 if( .not. any_lagrange(hecmesh, heclagmat) ) contact_elim = 1
118 if(
present(rf) )factor = rf
128 if( contact_elim==1 )
then
131 if( solver_type==1 )
then
132 write(*,*)
'ERROR: iterative solver without elimination not available in contact analysis'
134 elseif( solver_type==2 )
then
136 write(*,*)
'ERROR: !SOLVER,METHOD=DIRECT not available in parallel contact analysis;',&
137 ' please use MUMPS or DIRECTmkl instead'
140 call add_conmat_to_hecmat(hecmat,conmat,heclagmat)
143 elseif( solver_type==3 )
then
147 call add_conmat_to_hecmat(hecmat,conmat,heclagmat)
150 elseif( solver_type==5 )
then
152 elseif( solver_type==7 )
then
154 write(*,*)
'ERROR: !SOLVER,METHOD=DIRECTmf not available in parallel contact analysis',&
155 ' without elimination; specify CONTACT_ELIM=1 or use MUMPS or DIRECTmkl instead'
158 call add_conmat_to_hecmat(hecmat,conmat,heclagmat)
162 write(*,*)
'ERROR: specified solver not available in contact analysis without elimination;',&
163 ' please use MUMPS or DIRECTmkl instead'
176 hecmat%X=factor*hecmat%X
182 logical function any_lagrange(hecMESH, hecLagMAT)
185 integer(kind=kint) :: n
187 n = heclagmat%num_lagrange
190 end function any_lagrange
193 subroutine add_conmat_to_hecmat(hecMAT,conMAT,hecLagMat)
199 integer(kind=kint) :: ndof,ndof2,i
204 do i=1,hecmat%NP*ndof + heclagmat%num_lagrange
205 hecmat%B(i) = hecmat%B(i) + conmat%B(i)
208 do i=1,hecmat%NP*ndof2
209 hecmat%D(i) = hecmat%D(i) + conmat%D(i)
212 do i=1,hecmat%NPL*ndof2
213 hecmat%AL(i) = hecmat%AL(i) + conmat%AL(i)
216 do i=1,hecmat%NPU*ndof2
217 hecmat%AU(i) = hecmat%AU(i) + conmat%AU(i)
219 end subroutine add_conmat_to_hecmat
Essential boundary conditions kept as per-DOF marks and values so that they can be imposed on the mat...
integer(kind=kint) function, public hecmw_mat_get_solver_type(hecMAT)
subroutine, public hecmw_mat_set_contact_elim(hecMAT, contact_elim)
subroutine, public hecmw_mat_set_flag_diverged(hecMAT, flag_diverged)
subroutine, public hecmw_mat_set_flag_converged(hecMAT, flag_converged)
integer(kind=kint) function, public hecmw_mat_get_timelog(hecMAT)
integer(kind=kint) function, public hecmw_mat_get_loglevel(hecMAT)
integer(kind=kint) function, public hecmw_mat_get_contact_elim(hecMAT)
subroutine hecmw_abort(comm, code)
integer(kind=kint) function hecmw_comm_get_size()
integer(kind=kint) function hecmw_comm_get_comm()
integer(kind=kint), parameter hecmw_max
integer(kind=4), parameter kreal
integer(kind=kint) function hecmw_comm_get_rank()
real(kind=kreal) function hecmw_wtime()
subroutine hecmw_update_r(hecMESH, val, n, m)
subroutine hecmw_allreduce_i1(hecMESH, s, ntag)
subroutine solve_lineq_serial_lag_hecmw_init(hecMAT, hecLagMAT, is_sym)
subroutine solve_lineq_serial_lag_hecmw(hecMESH, hecMAT, hecLagMAT, hecEBC)
Structure for Lagrange multiplier-related part of stiffness matrix (Lagrange multiplier-related matri...