moved second file extension (.pes) into DAMASK_abaqus_*.f
This commit is contained in:
parent
35346b70b5
commit
12b81a2b75
|
@ -52,8 +52,8 @@
|
||||||
module DAMASK_interface
|
module DAMASK_interface
|
||||||
|
|
||||||
implicit none
|
implicit none
|
||||||
character(len=4), parameter :: InputFileExtension = '.inp'
|
character(len=4), dimension(2), parameter :: InputFileExtension = ['.pes','.inp']
|
||||||
character(len=4), parameter :: LogFileExtension = '.log'
|
character(len=4), parameter :: LogFileExtension = '.log'
|
||||||
|
|
||||||
contains
|
contains
|
||||||
|
|
||||||
|
|
|
@ -52,8 +52,8 @@
|
||||||
module DAMASK_interface
|
module DAMASK_interface
|
||||||
|
|
||||||
implicit none
|
implicit none
|
||||||
character(len=4), parameter :: InputFileExtension = '.inp'
|
character(len=4), dimension(2), parameter :: InputFileExtension = ['.pes','.inp']
|
||||||
character(len=4), parameter :: LogFileExtension = '.log'
|
character(len=4), parameter :: LogFileExtension = '.log'
|
||||||
|
|
||||||
contains
|
contains
|
||||||
|
|
||||||
|
|
20
code/IO.f90
20
code/IO.f90
|
@ -226,26 +226,28 @@ subroutine IO_open_inputFile(myUnit,model)
|
||||||
|
|
||||||
integer(pInt) :: myStat
|
integer(pInt) :: myStat
|
||||||
character(len=1024) :: path
|
character(len=1024) :: path
|
||||||
character(len=4) :: InputFileExtension2 = '.pes'
|
|
||||||
|
|
||||||
#ifdef Abaqus
|
#ifdef Abaqus
|
||||||
path = trim(getSolverWorkingDirectoryName())//trim(model)//InputFileExtension2 ! attempt .pes, if it exists: it should be used
|
integer(pInt) :: fileType
|
||||||
|
|
||||||
|
fileType = 1_pInt ! assume .pes
|
||||||
|
path = trim(getSolverWorkingDirectoryName())//trim(model)//inputFileExtension(fileType) ! attempt .pes, if it exists: it should be used
|
||||||
open(myUnit+1,status='old',iostat=myStat,file=path)
|
open(myUnit+1,status='old',iostat=myStat,file=path)
|
||||||
if(myStat /= 0_pInt) then !if .pes does not work / exist; use conventional extension, i.e.".inp"
|
if(myStat /= 0_pInt) then ! if .pes does not work / exist; use conventional extension, i.e.".inp"
|
||||||
path = trim(getSolverWorkingDirectoryName())//trim(model)//InputFileExtension
|
fileType = 2_pInt
|
||||||
|
path = trim(getSolverWorkingDirectoryName())//trim(model)//inputFileExtension(fileType)
|
||||||
open(myUnit+1,status='old',iostat=myStat,file=path)
|
open(myUnit+1,status='old',iostat=myStat,file=path)
|
||||||
InputFileExtension2=InputFileExtension
|
|
||||||
endif
|
endif
|
||||||
if (myStat /= 0_pInt) call IO_error(100_pInt,ext_msg=path) !ensure that any file opened works
|
if (myStat /= 0_pInt) call IO_error(100_pInt,ext_msg=path) ! ensure that any file opened works
|
||||||
|
|
||||||
path = trim(getSolverWorkingDirectoryName())//trim(model)//InputFileExtension2//'_assembly'
|
path = trim(getSolverWorkingDirectoryName())//trim(model)//inputFileExtension(fileType)//'_assembly'
|
||||||
open(myUnit,iostat=myStat,file=path)
|
open(myUnit,iostat=myStat,file=path)
|
||||||
if (myStat /= 0_pInt) call IO_error(100_pInt,ext_msg=path)
|
if (myStat /= 0_pInt) call IO_error(100_pInt,ext_msg=path)
|
||||||
if (.not.abaqus_assembleInputFile(myUnit,myUnit+1_pInt)) call IO_error(103_pInt) ! strip comments and concatenate any "include"s
|
if (.not.abaqus_assembleInputFile(myUnit,myUnit+1_pInt)) call IO_error(103_pInt) ! strip comments and concatenate any "include"s
|
||||||
close(myUnit+1_pInt)
|
close(myUnit+1_pInt)
|
||||||
#endif
|
#endif
|
||||||
#ifdef Marc
|
#ifdef Marc
|
||||||
path = trim(getSolverWorkingDirectoryName())//trim(model)//InputFileExtension
|
path = trim(getSolverWorkingDirectoryName())//trim(model)//inputFileExtension
|
||||||
open(myUnit,status='old',iostat=myStat,file=path)
|
open(myUnit,status='old',iostat=myStat,file=path)
|
||||||
if (myStat /= 0_pInt) call IO_error(100_pInt,ext_msg=path)
|
if (myStat /= 0_pInt) call IO_error(100_pInt,ext_msg=path)
|
||||||
#endif
|
#endif
|
||||||
|
|
Loading…
Reference in New Issue