Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F80356178
dihedral_opls_kokkos.h
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Subscribers
None
File Metadata
Details
File Info
Storage
Attached
Created
Sat, Aug 31, 07:53
Size
3 KB
Mime Type
text/x-c
Expires
Mon, Sep 2, 07:53 (1 d, 21 h)
Engine
blob
Format
Raw Data
Handle
20350580
Attached To
rLAMMPS lammps
dihedral_opls_kokkos.h
View Options
/* -*- c++ -*- ----------------------------------------------------------
LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator
http://lammps.sandia.gov, Sandia National Laboratories
Steve Plimpton, sjplimp@sandia.gov
Copyright (2003) Sandia Corporation. Under the terms of Contract
DE-AC04-94AL85000 with Sandia Corporation, the U.S. Government retains
certain rights in this software. This software is distributed under
the GNU General Public License.
See the README file in the top-level LAMMPS directory.
------------------------------------------------------------------------- */
#ifdef DIHEDRAL_CLASS
DihedralStyle
(
opls
/
kk
,
DihedralOPLSKokkos
<
LMPDeviceType
>
)
DihedralStyle
(
opls
/
kk
/
device
,
DihedralOPLSKokkos
<
LMPDeviceType
>
)
DihedralStyle
(
opls
/
kk
/
host
,
DihedralOPLSKokkos
<
LMPHostType
>
)
#else
#ifndef LMP_DIHEDRAL_OPLS_KOKKOS_H
#define LMP_DIHEDRAL_OPLS_KOKKOS_H
#include "dihedral_opls.h"
#include "kokkos_type.h"
namespace
LAMMPS_NS
{
template
<
int
NEWTON_BOND
,
int
EVFLAG
>
struct
TagDihedralOPLSCompute
{};
template
<
class
DeviceType
>
class
DihedralOPLSKokkos
:
public
DihedralOPLS
{
public:
typedef
DeviceType
device_type
;
typedef
EV_FLOAT
value_type
;
typedef
ArrayTypes
<
DeviceType
>
AT
;
DihedralOPLSKokkos
(
class
LAMMPS
*
);
virtual
~
DihedralOPLSKokkos
();
virtual
void
compute
(
int
,
int
);
virtual
void
coeff
(
int
,
char
**
);
template
<
int
NEWTON_BOND
,
int
EVFLAG
>
KOKKOS_INLINE_FUNCTION
void
operator
()(
TagDihedralOPLSCompute
<
NEWTON_BOND
,
EVFLAG
>
,
const
int
&
,
EV_FLOAT
&
)
const
;
template
<
int
NEWTON_BOND
,
int
EVFLAG
>
KOKKOS_INLINE_FUNCTION
void
operator
()(
TagDihedralOPLSCompute
<
NEWTON_BOND
,
EVFLAG
>
,
const
int
&
)
const
;
//template<int NEWTON_BOND>
KOKKOS_INLINE_FUNCTION
void
ev_tally
(
EV_FLOAT
&
ev
,
const
int
i1
,
const
int
i2
,
const
int
i3
,
const
int
i4
,
F_FLOAT
&
edihedral
,
F_FLOAT
*
f1
,
F_FLOAT
*
f3
,
F_FLOAT
*
f4
,
const
F_FLOAT
&
vb1x
,
const
F_FLOAT
&
vb1y
,
const
F_FLOAT
&
vb1z
,
const
F_FLOAT
&
vb2x
,
const
F_FLOAT
&
vb2y
,
const
F_FLOAT
&
vb2z
,
const
F_FLOAT
&
vb3x
,
const
F_FLOAT
&
vb3y
,
const
F_FLOAT
&
vb3z
)
const
;
protected:
class
NeighborKokkos
*
neighborKK
;
typename
AT
::
t_x_array_randomread
x
;
typename
AT
::
t_f_array
f
;
typename
AT
::
t_int_2d
dihedrallist
;
DAT
::
tdual_efloat_1d
k_eatom
;
DAT
::
tdual_virial_array
k_vatom
;
typename
ArrayTypes
<
DeviceType
>::
t_efloat_1d
d_eatom
;
typename
ArrayTypes
<
DeviceType
>::
t_virial_array
d_vatom
;
int
nlocal
,
newton_bond
;
int
eflag
,
vflag
;
DAT
::
tdual_int_scalar
k_warning_flag
;
typename
AT
::
t_int_scalar
d_warning_flag
;
HAT
::
t_int_scalar
h_warning_flag
;
DAT
::
tdual_ffloat_1d
k_k1
;
DAT
::
tdual_ffloat_1d
k_k2
;
DAT
::
tdual_ffloat_1d
k_k3
;
DAT
::
tdual_ffloat_1d
k_k4
;
DAT
::
t_ffloat_1d
d_k1
;
DAT
::
t_ffloat_1d
d_k2
;
DAT
::
t_ffloat_1d
d_k3
;
DAT
::
t_ffloat_1d
d_k4
;
virtual
void
allocate
();
};
}
#endif
#endif
/* ERROR/WARNING messages:
W: Dihedral problem
Conformation of the 4 listed dihedral atoms is extreme; you may want
to check your simulation geometry.
*/
Event Timeline
Log In to Comment