1 |
! provide interface for c calls.... |
2 |
|
3 |
subroutine makeatype(atp, status) |
4 |
|
5 |
use atype_module, ONLY: new_atype |
6 |
|
7 |
#define __FORTRAN90 |
8 |
#include "types/AtomTypeProperties.h" |
9 |
|
10 |
type(AtomTypeProperties), intent(in) :: atp |
11 |
integer, intent(inout) :: status |
12 |
|
13 |
integer :: ident |
14 |
logical :: is_Directional, is_LennardJones, is_Electrostatic |
15 |
logical :: is_Charge, is_Dipole, is_Quadrupole |
16 |
logical :: is_Sticky, is_StickyPower, is_GayBerne, is_EAM |
17 |
logical :: is_Shape, is_FLARB |
18 |
logical :: is_MEAM,is_SuttonChen |
19 |
|
20 |
ident = atp%ident |
21 |
is_Directional = (atp%is_Directional .ne. 0) |
22 |
is_LennardJones = (atp%is_LennardJones .ne. 0) |
23 |
is_Electrostatic = ((atp%is_Charge .ne. 0) .or. (atp%is_Dipole .ne. 0)) & |
24 |
.or. (atp%is_Quadrupole .ne. 0) |
25 |
|
26 |
is_Charge = (atp%is_Charge .ne. 0) |
27 |
is_Dipole = (atp%is_Dipole .ne. 0) |
28 |
is_Quadrupole = (atp%is_Quadrupole .ne. 0) |
29 |
is_Sticky = (atp%is_Sticky .ne. 0) |
30 |
is_StickyPower = (atp%is_StickyPower .ne. 0) |
31 |
is_GayBerne = (atp%is_GayBerne .ne. 0) |
32 |
is_EAM = (atp%is_EAM .ne. 0) |
33 |
is_Shape = (atp%is_Shape .ne. 0) |
34 |
is_FLARB = (atp%is_FLARB .ne. 0) |
35 |
is_SuttonChen = (atp%is_SuttonChen .ne. 0) |
36 |
is_MEAM = (atp%is_MEAM .ne. 0) |
37 |
|
38 |
call new_atype(ident, is_Directional, is_LennardJones, is_Electrostatic, & |
39 |
is_Charge, is_Dipole, is_Quadrupole, is_Sticky, is_StickyPower, & |
40 |
is_GayBerne, is_EAM, is_Shape, is_FLARB, is_SuttonChen, is_MEAM,status) |
41 |
|
42 |
end subroutine makeatype |
43 |
|
44 |
! clears memory up |
45 |
subroutine deleteAtypes() |
46 |
use atype_module,ONLY: delete_atypes |
47 |
call delete_atypes() |
48 |
end subroutine deleteatypes |