| 1 |
|
#ifdef __C |
| 2 |
|
#ifndef __FSIMULATION |
| 3 |
|
#define __FSIMULATION |
| 4 |
< |
/** This header provides dual access for the simulation structure between fortran and C |
| 5 |
< |
for the simtype structure. NOTE: Sequence of struct components must match between |
| 6 |
< |
C and fortran and in general be packed double,int,char. |
| 7 |
< |
*/ |
| 4 |
> |
/** This header provides dual access for the simulation structure between |
| 5 |
> |
fortran and C for the simtype structure. NOTE: Sequence of struct |
| 6 |
> |
components must match between C and fortran and in general be packed |
| 7 |
> |
double,int,char. |
| 8 |
> |
*/ |
| 9 |
|
typedef struct{ |
| 10 |
|
double box[3]; |
| 11 |
|
double rlist; |
| 12 |
|
double rcut; |
| 13 |
< |
double rlistsq; |
| 14 |
< |
double rcutsq; |
| 15 |
< |
double rcut6; |
| 16 |
< |
int natoms; |
| 17 |
< |
int usePBC; |
| 18 |
< |
int do_stress; |
| 19 |
< |
char ensemble[100]; |
| 20 |
< |
char mixingRule[100]; |
| 13 |
> |
double rrf; |
| 14 |
> |
double rt; |
| 15 |
> |
int SIM_uses_PBC; |
| 16 |
> |
int SIM_uses_LJ; |
| 17 |
> |
int SIM_uses_sticky; |
| 18 |
> |
int SIM_uses_dipoles; |
| 19 |
> |
int SIM_uses_RF; |
| 20 |
> |
int SIM_uses_GB; |
| 21 |
> |
int SIM_uses_EAM; |
| 22 |
|
} simtype; |
| 23 |
|
#endif //__FSIMULATION |
| 24 |
|
#endif //__C |
| 25 |
|
|
| 26 |
|
#ifdef __FORTRAN90 |
| 27 |
|
|
| 28 |
< |
integer, parameter :: string_len = 100 |
| 29 |
< |
|
| 30 |
< |
type, public :: simtype |
| 31 |
< |
PRIVATE |
| 32 |
< |
SEQUENCE |
| 33 |
< |
!! Periodic Box |
| 34 |
< |
real ( kind = dp ), dimension(3) :: box |
| 35 |
< |
!! List Cutoff |
| 36 |
< |
real ( kind = dp ) :: rlist = 0.0_dp |
| 37 |
< |
!! Radial cutoff |
| 38 |
< |
real ( kind = dp ) :: rcut = 0.0_dp |
| 39 |
< |
!! List cutoff squared |
| 40 |
< |
real ( kind = dp ) :: rlistsq = 0.0_dp |
| 41 |
< |
!! Radial Cutoff squared |
| 42 |
< |
real ( kind = dp ) :: rcutsq = 0.0_dp |
| 43 |
< |
!! Radial Cutoff^6 |
| 44 |
< |
real ( kind = dp ) :: rcut6 = 0.0_dp |
| 45 |
< |
!! Number of particles on this processor |
| 46 |
< |
integer :: nLRparticles |
| 47 |
< |
!! Periodic Boundry Conditions |
| 48 |
< |
logical :: use_pbc |
| 49 |
< |
!! Calculate stress tensor and virial? |
| 48 |
< |
logical :: do_stress |
| 49 |
< |
!! Ensemble must be defined inside of C |
| 50 |
< |
character(len = string_len) :: ensemble |
| 51 |
< |
!! Mixing Rules must be defined inside of C |
| 52 |
< |
character(len = string_len) :: mixingRule |
| 53 |
< |
end type simtype |
| 28 |
> |
type, public :: simtype |
| 29 |
> |
PRIVATE |
| 30 |
> |
SEQUENCE |
| 31 |
> |
!! Periodic Box |
| 32 |
> |
real ( kind = dp ), dimension(3) :: box |
| 33 |
> |
!! List Cutoff |
| 34 |
> |
real ( kind = dp ) :: rlist = 0.0_dp |
| 35 |
> |
!! Radial cutoff |
| 36 |
> |
real ( kind = dp ) :: rcut = 0.0_dp |
| 37 |
> |
!! Reaction Field sphere radius |
| 38 |
> |
real ( kind = dp ) :: rrf = 0.0_dp |
| 39 |
> |
!! Taper radius for dipole and reaction field switching function |
| 40 |
> |
real ( kind = dp ) :: rt = 0.0_dp |
| 41 |
> |
!! Periodic Boundry Conditions |
| 42 |
> |
logical :: SIM_uses_PBC |
| 43 |
> |
logical :: SIM_uses_LJ |
| 44 |
> |
logical :: SIM_uses_sticky |
| 45 |
> |
logical :: SIM_uses_dipoles |
| 46 |
> |
logical :: SIM_uses_RF |
| 47 |
> |
logical :: SIM_uses_GB |
| 48 |
> |
logical :: SIM_uses_EAM |
| 49 |
> |
end type simtype |
| 50 |
|
#endif |