|
|
@ -21,10 +21,11 @@ module mode_create
|
|
|
|
public
|
|
|
|
public
|
|
|
|
contains
|
|
|
|
contains
|
|
|
|
|
|
|
|
|
|
|
|
subroutine create()
|
|
|
|
subroutine create(arg_pos)
|
|
|
|
! Main subroutine which controls execution
|
|
|
|
! Main subroutine which controls execution
|
|
|
|
|
|
|
|
|
|
|
|
character(len=100) :: textholder
|
|
|
|
character(len=100) :: textholder
|
|
|
|
|
|
|
|
integer, intent(out) :: arg_pos
|
|
|
|
|
|
|
|
|
|
|
|
integer :: i, ibasis, inod
|
|
|
|
integer :: i, ibasis, inod
|
|
|
|
real(kind=dp), allocatable :: r_node_temp(:,:,:)
|
|
|
|
real(kind=dp), allocatable :: r_node_temp(:,:,:)
|
|
|
@ -45,13 +46,7 @@ module mode_create
|
|
|
|
lat_atom_num = 0
|
|
|
|
lat_atom_num = 0
|
|
|
|
|
|
|
|
|
|
|
|
!First we parse the command
|
|
|
|
!First we parse the command
|
|
|
|
call parse_command()
|
|
|
|
call parse_command(arg_pos)
|
|
|
|
|
|
|
|
|
|
|
|
! Before building do a check on the file
|
|
|
|
|
|
|
|
if (outfilenum == 0) then
|
|
|
|
|
|
|
|
textholder = 'none'
|
|
|
|
|
|
|
|
call get_out_file(textholder)
|
|
|
|
|
|
|
|
end if
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
!Now we setup the unit element and call other init subroutines
|
|
|
|
!Now we setup the unit element and call other init subroutines
|
|
|
|
call def_ng_node(1, element_type)
|
|
|
|
call def_ng_node(1, element_type)
|
|
|
@ -161,10 +156,10 @@ module mode_create
|
|
|
|
sub_box_array_bd(2,2,1) = ele_num
|
|
|
|
sub_box_array_bd(2,2,1) = ele_num
|
|
|
|
end subroutine create
|
|
|
|
end subroutine create
|
|
|
|
!This subroutine parses the command and pulls out information needed for mode_create
|
|
|
|
!This subroutine parses the command and pulls out information needed for mode_create
|
|
|
|
subroutine parse_command()
|
|
|
|
subroutine parse_command(arg_pos)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
integer :: arg_pos, ori_pos, i, j, arglen, stat
|
|
|
|
integer, intent(out) :: arg_pos
|
|
|
|
|
|
|
|
integer :: ori_pos, i, j, arglen, stat
|
|
|
|
character(len=100) :: textholder
|
|
|
|
character(len=100) :: textholder
|
|
|
|
character(len=8) :: orient_string
|
|
|
|
character(len=8) :: orient_string
|
|
|
|
|
|
|
|
|
|
|
@ -245,20 +240,10 @@ module mode_create
|
|
|
|
read(textholder, *) origin(i)
|
|
|
|
read(textholder, *) origin(i)
|
|
|
|
arg_pos = arg_pos + 1
|
|
|
|
arg_pos = arg_pos + 1
|
|
|
|
end do
|
|
|
|
end do
|
|
|
|
!If a filetype is passed then we add name.ext to the outfiles list
|
|
|
|
|
|
|
|
case('xyz')
|
|
|
|
|
|
|
|
textholder = trim(adjustl(name)) //'.xyz'
|
|
|
|
|
|
|
|
call get_out_file(textholder)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
case default
|
|
|
|
case default
|
|
|
|
!Check to see if it is an option command, if so then mode_create must be finished
|
|
|
|
!If it isn't an option then you have to exit
|
|
|
|
if(textholder(1:1) == '-') then
|
|
|
|
|
|
|
|
exit
|
|
|
|
exit
|
|
|
|
|
|
|
|
|
|
|
|
!Check to see if a filename was passed
|
|
|
|
|
|
|
|
elseif(scan(textholder,'.',.true.) > 0) then
|
|
|
|
|
|
|
|
call get_out_file(textholder)
|
|
|
|
|
|
|
|
end if
|
|
|
|
|
|
|
|
end select
|
|
|
|
end select
|
|
|
|
end do
|
|
|
|
end do
|
|
|
|
|
|
|
|
|
|
|
|