From 8336d0705c99c3a19ba0e56387338a41e9e81bfd Mon Sep 17 00:00:00 2001 From: Christoph Kords Date: Mon, 24 Sep 2012 06:13:26 +0000 Subject: [PATCH] new numerics parameter "unitlength" that scales the model size in DAMASK; this enables to use very small models in marc without getting any numerical problems for example with contact which does not seem to work when using very small numbers --- code/CPFEM.f90 | 7 ++++--- code/config/numerics.config | 1 + 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/code/CPFEM.f90 b/code/CPFEM.f90 index 2388c7a3b..3e7e3a4cc 100644 --- a/code/CPFEM.f90 +++ b/code/CPFEM.f90 @@ -237,7 +237,8 @@ subroutine CPFEM_general(mode, coords, ffn, ffn1, Temperature, dt, element, IP, !*** variables and functions from other modules ***! use prec, only: pInt use numerics, only: defgradTolerance, & - iJacoStiffness + iJacoStiffness, & + numerics_unitlength use debug, only: debug_level, & debug_CPFEM, & debug_levelBasic, & @@ -611,11 +612,11 @@ subroutine CPFEM_general(mode, coords, ffn, ffn1, Temperature, dt, element, IP, CPFEM_dcsde(1:6,1:6,IP,cp_en) = CPFEM_odd_jacobian * math_identity2nd(6) CPFEM_calc_done = .false. #ifndef Marc - mesh_ipCenterOfGravity(1:3,IP,cp_en) = coords(1:3,1) + mesh_ipCenterOfGravity(1:3,IP,cp_en) = numerics_unitlength * coords(1:3,1) #else do node = 1,FE_Nnodes(mesh_element(2,cp_en)) FEnodeID = mesh_FEasCP('node',mesh_element(4+node,cp_en)) - mesh_node(1:3,FEnodeID) = mesh_node0(1:3,FEnodeID) + coords(1:3,node) + mesh_node(1:3,FEnodeID) = mesh_node0(1:3,FEnodeID) + numerics_unitlength * coords(1:3,node) enddo #endif diff --git a/code/config/numerics.config b/code/config/numerics.config index 3e0e14204..c646d413b 100644 --- a/code/config/numerics.config +++ b/code/config/numerics.config @@ -10,6 +10,7 @@ pert_method 1 # perturbation method (1 = forward, 2 = b integrator 1 # integration method (1 = Fixed Point Iteration, 2 = Euler, 3 = Adaptive Euler, 4 = classical 4th order Runge-Kutta, 5 = 5th order Runge-Kutta Cash-Karp) integratorStiffness 1 # integration method used for stiffness (1 = Fixed Point Iteration, 2 = Euler, 3 = Adaptive Euler, 4 = classical 4th order Runge-Kutta, 5 = 5th order Runge-Kutta Cash-Karp) analyticJaco 0 # use analytic Jacobian or perturbation (0 = perturbations, 1 = analytic) +unitlength 1 # physical length of one computational length unit ## crystallite numerical parameters ## nCryst 20 # crystallite loop limit (only for debugging info, loop limit is determined by "subStepMinCryst")