OpenMPCD
DeviceCode/HarmonicTrimers.hpp
Go to the documentation of this file.
1 /**
2  * @file
3  * Defines CUDA Device code for OpenMPCD::CUDA::MPCFluid::HarmonicTrimers
4  */
5 
6 #ifndef OPENMPCD_CUDA_MPCFLUID_DEVICECODE_HARMONICTRIMERS_HPP
7 #define OPENMPCD_CUDA_MPCFLUID_DEVICECODE_HARMONICTRIMERS_HPP
8 
9 #include <OpenMPCD/Types.hpp>
10 
11 namespace OpenMPCD
12 {
13 namespace CUDA
14 {
15 namespace MPCFluid
16 {
17 namespace DeviceCode
18 {
19  /**
20  * Streams the given trimer via velocity-Verlet integration.
21  * No boundary conditions are considered.
22  * This function assumes that the individual particles in the trimer all have mass 1.
23  * @param[in] workUnitOffset The number of trimers to skip.
24  * @param[in,out] positions The array of MPC fluid particle positions.
25  * @param[in,out] velocities The array of MPC fluid particle velocities.
26  * @param[in] reducedSpringConstant1 The spring constant for the spring between particles 1 and 2,
27  * divided by the mass of an individual constituent particle.
28  * @param[in] reducedSpringConstant2 The spring constant for the spring between particles 2 and 3,
29  * divided by the mass of an individual constituent particle.
30  * @param[in] timestep The timestep for an individual velocity-Verlet step.
31  * @param[in] stepCount The number of velocity-Verlet steps to perform.
32  */
33  __global__ void streamHarmonicTrimerVelocityVerlet(
34  const unsigned int workUnitOffset,
35  MPCParticlePositionType* const positions,
36  MPCParticleVelocityType* const velocities,
37  const FP reducedSpringConstant1,
38  const FP reducedSpringConstant2,
39  const FP timestep,
40  const unsigned int stepCount);
41 
42 } //namespace DeviceCode
43 } //namespace MPCFluid
44 } //namespace CUDA
45 } //namespace OpenMPCD
46 
47 #endif
Types.hpp
OpenMPCD::CUDA::MPCFluid::DeviceCode::streamHarmonicTrimerVelocityVerlet
__global__ void streamHarmonicTrimerVelocityVerlet(const unsigned int workUnitOffset, MPCParticlePositionType *const positions, MPCParticleVelocityType *const velocities, const FP reducedSpringConstant1, const FP reducedSpringConstant2, const FP timestep, const unsigned int stepCount)
Streams the given trimer via velocity-Verlet integration.