more flexibility for the L in the load case

Note that mixed boundary conditions for L introduce an ambiguity.
Consider:

L = [[1.0, x, x],
     [  0, 0, 0],
     [  0, 0, 0]]
P = [[x, 0, 0],
     [x, x, x],
     [x, x, x]]

What we need is F^(n+1)=F_dot^(n+1) x Delta_t, where F_dot^(n+1) is
F_dot^(n+1)_ij = L_ik F^n_kj.

So component F_11 has contributions from L_12 and L_13. We first assume
L_12=L_13=0 and then choose F^(n+1)_12 and F^(n+1)_13 to get
P_12=P_13=0. This implicitly gives a solution for L_12 and L_13, which
is however only one out of infinitely many.
This commit is contained in:
Martin Diehl 2021-07-20 06:38:29 +02:00
parent 03b7532cc5
commit 85735605f8
5 changed files with 3 additions and 11 deletions

View File

@ -504,8 +504,6 @@ subroutine IO_error(error_ID,el,ip,g,instance,ext_msg)
! errors related to the grid solver
case (831)
msg = 'mask consistency violated in grid load case'
case (832)
msg = 'ill-defined L (line partly defined) in grid load case'
case (833)
msg = 'non-positive ratio for geometric progression'
case (834)

View File

@ -218,12 +218,6 @@ program DAMASK_grid
reportAndCheck: if (worldrank == 0) then
print'(/,a,i0)', ' load case: ', l
print*, ' estimate_rate:', loadCases(l)%estimate_rate
if (loadCases(l)%deformation%myType == 'L') then
do j = 1, 3
if (any(loadCases(l)%deformation%mask(j,1:3) .eqv. .true.) .and. &
any(loadCases(l)%deformation%mask(j,1:3) .eqv. .false.)) errorID = 832 ! each row should be either fully or not at all defined
enddo
endif
if (loadCases(l)%deformation%myType == 'F') then
print*, ' F:'
else

View File

@ -370,7 +370,7 @@ subroutine grid_mechanical_FEM_forward(cutBack,guess,Delta_t,Delta_t_old,t_remai
! calculate rate for aim
if (deformation_BC%myType=='L') then ! calculate F_aimDot from given L and current F
F_aimDot = F_aimDot &
+ merge(.0_pReal,matmul(deformation_BC%values, F_aim_lastInc),deformation_BC%mask)
+ matmul(merge(.0_pReal,deformation_BC%values,deformation_BC%mask),F_aim_lastInc)
elseif (deformation_BC%myType=='dot_F') then ! F_aimDot is prescribed
F_aimDot = F_aimDot &
+ merge(.0_pReal,deformation_BC%values,deformation_BC%mask)

View File

@ -321,7 +321,7 @@ subroutine grid_mechanical_spectral_basic_forward(cutBack,guess,Delta_t,Delta_t_
! calculate rate for aim
if (deformation_BC%myType=='L') then ! calculate F_aimDot from given L and current F
F_aimDot = F_aimDot &
+ merge(.0_pReal,matmul(deformation_BC%values, F_aim_lastInc),deformation_BC%mask)
+ matmul(merge(.0_pReal,deformation_BC%values,deformation_BC%mask),F_aim_lastInc)
elseif (deformation_BC%myType=='dot_F') then ! F_aimDot is prescribed
F_aimDot = F_aimDot &
+ merge(.0_pReal,deformation_BC%values,deformation_BC%mask)

View File

@ -357,7 +357,7 @@ subroutine grid_mechanical_spectral_polarisation_forward(cutBack,guess,Delta_t,D
! calculate rate for aim
if (deformation_BC%myType=='L') then ! calculate F_aimDot from given L and current F
F_aimDot = F_aimDot &
+ merge(.0_pReal,matmul(deformation_BC%values, F_aim_lastInc),deformation_BC%mask)
+ matmul(merge(.0_pReal,deformation_BC%values,deformation_BC%mask),F_aim_lastInc)
elseif (deformation_BC%myType=='dot_F') then ! F_aimDot is prescribed
F_aimDot = F_aimDot &
+ merge(.0_pReal,deformation_BC%values,deformation_BC%mask)