OpenMPCD
Namespaces | Functions
StarPolymers_Implementation.hpp File Reference
#include <OpenMPCD/CUDA/MPCSolute/StarPolymers.hpp>
#include <OpenMPCD/CUDA/Macros.hpp>
#include <algorithm>
Include dependency graph for StarPolymers_Implementation.hpp:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Namespaces

 OpenMPCD::CUDA
 Namespace for simulations using CUDA.
 
 OpenMPCD::CUDA::MPCSolute
 Namespace for MPC Solute classes.
 
 OpenMPCD::CUDA::MPCSolute::ImplementationDetails
 Contains implementation details used in OpenMPCD::CUDA::MPCSolute.
 
 OpenMPCD::CUDA::MPCSolute::ImplementationDetails::StarPolymers
 Contains implementation details used in OpenMPCD::CUDA::MPCSolute::StarPolymers.
 

Functions

OPENMPCD_CUDA_HOST_AND_DEVICE std::size_t OpenMPCD::CUDA::MPCSolute::ImplementationDetails::StarPolymers::getParticleCountPerStar (const std::size_t armCountPerStar, const std::size_t particleCountPerArm, const bool hasMagneticParticles)
 Returns the total number of particles per star. More...
 
OPENMPCD_CUDA_HOST_AND_DEVICE std::size_t OpenMPCD::CUDA::MPCSolute::ImplementationDetails::StarPolymers::getParticleCount (const std::size_t starCount, const std::size_t armCountPerStar, const std::size_t particleCountPerArm, const bool hasMagneticParticles)
 Returns the total number of particles in a StarPolymers instance. More...
 
OPENMPCD_CUDA_HOST_AND_DEVICE void OpenMPCD::CUDA::MPCSolute::ImplementationDetails::StarPolymers::getParticleStructureIndices (const std::size_t particleID, const std::size_t starCount, const std::size_t armCountPerStar, const std::size_t particleCountPerArm, const bool hasMagneticParticles, std::size_t *const starID, bool *const isCoreParticle, std::size_t *const armID, bool *const isMagneticParticle, std::size_t *const particleIDInArm)
 Computes the structure indices of the particle ID given. More...
 
OPENMPCD_CUDA_HOST_AND_DEVICE ParticleType::Enum OpenMPCD::CUDA::MPCSolute::ImplementationDetails::StarPolymers::getParticleType (const std::size_t particleID, const std::size_t starCount, const std::size_t armCountPerStar, const std::size_t particleCountPerArm, const bool hasMagneticParticles)
 Returns the particle type that corresponds to the given ID. More...
 
OPENMPCD_CUDA_HOST_AND_DEVICE bool OpenMPCD::CUDA::MPCSolute::ImplementationDetails::StarPolymers::particlesAreBonded (const std::size_t particleID1, const std::size_t particleID2, const std::size_t starCount, const std::size_t armCountPerStar, const std::size_t particleCountPerArm, const bool hasMagneticParticles)
 Returns whether the two given particles are bonded. More...
 
OPENMPCD_CUDA_HOST_AND_DEVICE std::size_t OpenMPCD::CUDA::MPCSolute::ImplementationDetails::StarPolymers::getParticleTypeCombinationIndex (const ParticleType::Enum type1, const ParticleType::Enum type2)
 Returns a different integer, in a consecutive range starting from 0, for every combination of particle types, except that the result is invariant under exchange of the two arguments. More...
 
template<typename T >
__global__ void OpenMPCD::CUDA::MPCSolute::ImplementationDetails::StarPolymers::createInteractionsOnDevice_kernel (const T epsilon_core, const T epsilon_arm, const T epsilon_magnetic, const T sigma_core, const T sigma_arm, const T sigma_magnetic, const T D_core, const T D_arm, const T D_magnetic, const T magneticPrefactor, const Vector3D< T > dipoleOrientation, PairPotentials::WeeksChandlerAndersen_DistanceOffset< T > **const WCAPotentials, PairPotentials::FENE< T > **const FENEPotentials, PairPotentials::MagneticDipoleDipoleInteraction_ConstantIdenticalDipoles< T > **const magneticPotential)
 Constructs the interaction potentials in Device memory. More...
 
template<typename T >
void OpenMPCD::CUDA::MPCSolute::ImplementationDetails::StarPolymers::createInteractionsOnDevice (const T epsilon_core, const T epsilon_arm, const T epsilon_magnetic, const T sigma_core, const T sigma_arm, const T sigma_magnetic, const T D_core, const T D_arm, const T D_magnetic, const T magneticPrefactor, const Vector3D< T > dipoleOrientation, PairPotentials::WeeksChandlerAndersen_DistanceOffset< T > ***const WCAPotentials, PairPotentials::FENE< T > ***const FENEPotentials, PairPotentials::MagneticDipoleDipoleInteraction_ConstantIdenticalDipoles< T > ***const magneticPotential)
 Constructs the necessary interaction potentials in memory. More...
 
template<typename T >
__global__ void OpenMPCD::CUDA::MPCSolute::ImplementationDetails::StarPolymers::destroyInteractionsOnDevice_kernel (PairPotentials::WeeksChandlerAndersen_DistanceOffset< T > **const WCAPotentials, PairPotentials::FENE< T > **const FENEPotentials, PairPotentials::MagneticDipoleDipoleInteraction_ConstantIdenticalDipoles< T > **const magneticPotential)
 Frees the memory allocated through createInteractionsOnDevice_kernel. More...
 
template<typename T >
void OpenMPCD::CUDA::MPCSolute::ImplementationDetails::StarPolymers::destroyInteractionsOnDevice (PairPotentials::WeeksChandlerAndersen_DistanceOffset< T > **const WCAPotentials, PairPotentials::FENE< T > **const FENEPotentials, PairPotentials::MagneticDipoleDipoleInteraction_ConstantIdenticalDipoles< T > **const magneticPotential)
 Frees the memory allocated through createInteractionsOnDevice. More...
 
template<typename T >
const OPENMPCD_CUDA_HOST_AND_DEVICE Vector3D< T > OpenMPCD::CUDA::MPCSolute::ImplementationDetails::StarPolymers::computeForceOnParticle1DueToParticle2 (const std::size_t particleID1, const std::size_t particleID2, const RemotelyStoredVector< const T > &position1, const RemotelyStoredVector< const T > &position2, const std::size_t starCount, const std::size_t armCountPerStar, const std::size_t particleCountPerArm, const bool hasMagneticParticles, PairPotentials::WeeksChandlerAndersen_DistanceOffset< T > **const WCAPotentials, PairPotentials::FENE< T > **const FENEPotentials, PairPotentials::MagneticDipoleDipoleInteraction_ConstantIdenticalDipoles< T > **const magneticPotential)
 Returns the force that is exerted on particleID1 due to particleID2. More...
 

Detailed Description

Contains implementation details used in OpenMPCD::CUDA::MPCSolute::StarPolymers.

Definition in file StarPolymers_Implementation.hpp.