in Abaqus there is a second input file ending (.pes), if this file exists it is to be preferred over the *.inp file (thanks Steffen)

This commit is contained in:
Franz Roters 2013-02-04 08:29:58 +00:00
parent 7f5e9f70b2
commit 01a7850517
1 changed files with 10 additions and 3 deletions

View File

@ -220,13 +220,20 @@ subroutine IO_open_inputFile(myUnit,model)
integer(pInt) :: myStat
character(len=1024) :: path
character(len=4) :: InputFileExtension2
#ifdef Abaqus
path = trim(getSolverWorkingDirectoryName())//trim(model)//InputFileExtension
InputFileExtension2='.pes'
path = trim(getSolverWorkingDirectoryName())//trim(model)//InputFileExtension2 ! attempt .pes, if it exists: it should be used
open(myUnit+1,status='old',iostat=myStat,file=path)
if (myStat /= 0_pInt) call IO_error(100_pInt,ext_msg=path)
if(myStat /= 0_pInt) then !if .pes does not work / exist; use conventional extension, i.e.".inp"
path = trim(getSolverWorkingDirectoryName())//trim(model)//InputFileExtension
open(myUnit+1,status='old',iostat=myStat,file=path)
InputFileExtension2=InputFileExtension
endif
if (myStat /= 0_pInt) call IO_error(100_pInt,ext_msg=path) !ensure that any file opened works
path = trim(getSolverWorkingDirectoryName())//trim(model)//InputFileExtension//'_assembly'
path = trim(getSolverWorkingDirectoryName())//trim(model)//InputFileExtension2//'_assembly'
open(myUnit,iostat=myStat,file=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