DAMASK with grid solvers  Revision: v2.0.3-2204-gdb1f2151
The Düsseldorf Advanced Material Simulation Kit with Grid Solvers
damask_interface Module Reference

Interfacing between the 1-based solvers and the material subroutines provided by DAMASK. More...

Functions/Subroutines

subroutine, public damask_interface_init
 initializes the solver by interpreting the command line arguments. Also writes information on computation to screen More...
 
subroutine setworkingdirectory (workingDirectoryArg)
 extract working directory from given argument or from location of geometry file, possibly converting relative arguments to absolut path More...
 
character(len=:) function, allocatable, public getsolverjobname ()
 solver job name (no extension) as combination of geometry and load case name More...
 
character(len=:) function, allocatable getgeometryfile (geometryParameter)
 basename of geometry file with extension from command line arguments More...
 
character(len=:) function, allocatable getloadcasefile (loadCaseParameter)
 relative path of loadcase from command line arguments More...
 
character(len=:) function, allocatable rectifypath (path)
 remove ../, /./, and // from path. More...
 
character(len=:) function, allocatable makerelativepath (a, b)
 relative path from absolute a to absolute b More...
 
subroutine catchsigterm (signal)
 sets global variable SIGTERM to .true. More...
 
subroutine, public setsigterm (state)
 sets global variable SIGTERM More...
 
subroutine catchsigusr1 (signal)
 sets global variable SIGUSR1 to .true. More...
 
subroutine, public setsigusr1 (state)
 sets global variable SIGUSR1 More...
 
subroutine catchsigusr2 (signal)
 sets global variable SIGUSR2 to .true. if program receives SIGUSR2 More...
 
subroutine, public setsigusr2 (state)
 sets global variable SIGUSR2 More...
 

Variables

logical, public, protected sigterm
 termination signal More...
 
logical, public, protected sigusr1
 
  1. user-defined signal
More...
 
logical, public, protected sigusr2
 
integer, public, protected interface_restartinc = 0
 Increment at which calculation starts. More...
 
character(len=:), allocatable, public, protected geometryfile
 parameter given for geometry file More...
 
character(len=:), allocatable, public, protected loadcasefile
 parameter given for load case file More...
 

Detailed Description

Interfacing between the 1-based solvers and the material subroutines provided by DAMASK.

Author
Jaeyong Jung, Max-Planck-Institut für Eisenforschung GmbH
Pratheek Shanthraj, Max-Planck-Institut für Eisenforschung GmbH
Martin Diehl, Max-Planck-Institut für Eisenforschung GmbH
Philip Eisenlohr, Max-Planck-Institut für Eisenforschung GmbH

Interfacing between the 1-based solvers and the material subroutines provided by DAMASK. Interpretating the command line arguments to get load case, geometry file, and working directory.

Function/Subroutine Documentation

◆ catchsigterm()

subroutine damask_interface::catchsigterm ( integer(c_int), value  signal)
private

sets global variable SIGTERM to .true.

Definition at line 1879 of file DAMASK_interface.f90.

References sigterm.

◆ catchsigusr1()

subroutine damask_interface::catchsigusr1 ( integer(c_int), value  signal)
private

sets global variable SIGUSR1 to .true.

Definition at line 1903 of file DAMASK_interface.f90.

References sigusr1.

Referenced by damask_interface_init().

+ Here is the caller graph for this function:

◆ catchsigusr2()

subroutine damask_interface::catchsigusr2 ( integer(c_int), value  signal)
private

sets global variable SIGUSR2 to .true. if program receives SIGUSR2

Definition at line 1927 of file DAMASK_interface.f90.

References sigusr2.

Referenced by damask_interface_init().

+ Here is the caller graph for this function:

◆ damask_interface_init()

subroutine, public damask_interface::damask_interface_init

initializes the solver by interpreting the command line arguments. Also writes information on computation to screen

Definition at line 56 of file DAMASK_interface.f90.

References catchsigusr1(), catchsigusr2(), geometryfile, system_routines::getcwd(), getgeometryfile(), system_routines::gethostname(), getloadcasefile(), getsolverjobname(), interface_restartinc, loadcasefile, quit(), setsigterm(), setsigusr1(), setsigusr2(), and setworkingdirectory().

Referenced by cpfem2::cpfem_initall().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getgeometryfile()

character(len=:) function, allocatable damask_interface::getgeometryfile ( character(len=*), intent(in)  geometryParameter)
private

basename of geometry file with extension from command line arguments

Definition at line 1758 of file DAMASK_interface.f90.

References system_routines::getcwd(), makerelativepath(), and quit().

Referenced by damask_interface_init().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getloadcasefile()

character(len=:) function, allocatable damask_interface::getloadcasefile ( character(len=*), intent(in)  loadCaseParameter)
private

relative path of loadcase from command line arguments

Definition at line 1781 of file DAMASK_interface.f90.

References system_routines::getcwd(), makerelativepath(), and quit().

Referenced by damask_interface_init().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getsolverjobname()

character(len=:) function, allocatable, public damask_interface::getsolverjobname

◆ makerelativepath()

character(len=:) function, allocatable damask_interface::makerelativepath ( character (len=*), intent(in)  a,
character (len=*), intent(in)  b 
)
private

relative path from absolute a to absolute b

Definition at line 1851 of file DAMASK_interface.f90.

References rectifypath().

Referenced by getgeometryfile(), and getloadcasefile().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ rectifypath()

character(len=:) function, allocatable damask_interface::rectifypath ( character(len=*), intent(in)  path)
private

remove ../, /./, and // from path.

works only if absolute path is given

Definition at line 1805 of file DAMASK_interface.f90.

Referenced by makerelativepath(), and setworkingdirectory().

+ Here is the caller graph for this function:

◆ setsigterm()

subroutine, public damask_interface::setsigterm ( logical, intent(in)  state)

sets global variable SIGTERM

Definition at line 1892 of file DAMASK_interface.f90.

References sigterm.

Referenced by damask_interface_init().

+ Here is the caller graph for this function:

◆ setsigusr1()

subroutine, public damask_interface::setsigusr1 ( logical, intent(in)  state)

sets global variable SIGUSR1

Definition at line 1916 of file DAMASK_interface.f90.

References sigusr1.

Referenced by damask_interface_init().

+ Here is the caller graph for this function:

◆ setsigusr2()

subroutine, public damask_interface::setsigusr2 ( logical, intent(in)  state)

sets global variable SIGUSR2

Definition at line 1940 of file DAMASK_interface.f90.

References sigusr2.

Referenced by damask_interface_init().

+ Here is the caller graph for this function:

◆ setworkingdirectory()

subroutine damask_interface::setworkingdirectory ( character(len=*), intent(in)  workingDirectoryArg)
private

extract working directory from given argument or from location of geometry file, possibly converting relative arguments to absolut path

Parameters
[in]workingdirectoryargworking directory argument

Definition at line 1710 of file DAMASK_interface.f90.

References system_routines::getcwd(), quit(), rectifypath(), and system_routines::setcwd().

Referenced by damask_interface_init().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

Variable Documentation

◆ geometryfile

character(len=:), allocatable, public, protected damask_interface::geometryfile

parameter given for geometry file

Definition at line 38 of file DAMASK_interface.f90.

Referenced by damask_interface_init(), getsolverjobname(), and discretization_grid::readgeom().

◆ interface_restartinc

integer, public, protected damask_interface::interface_restartinc = 0

◆ loadcasefile

character(len=:), allocatable, public, protected damask_interface::loadcasefile

parameter given for load case file

Definition at line 38 of file DAMASK_interface.f90.

Referenced by damask_interface_init(), damask_spectral(), and getsolverjobname().

◆ sigterm

logical, public, protected damask_interface::sigterm

termination signal

Definition at line 32 of file DAMASK_interface.f90.

Referenced by catchsigterm(), and setsigterm().

◆ sigusr1

logical, public, protected damask_interface::sigusr1

  1. user-defined signal

Definition at line 32 of file DAMASK_interface.f90.

Referenced by catchsigusr1(), and setsigusr1().

◆ sigusr2

logical, public, protected damask_interface::sigusr2
  1. user-defined signal

Definition at line 32 of file DAMASK_interface.f90.

Referenced by catchsigusr2(), and setsigusr2().