Commit 35bdd2a3 authored by snuverink_j's avatar snuverink_j

Merge branch '523-remove-dks' into 'master'

Resolve "Remove DKS"

See merge request OPAL/src!353
parents db2860f9 7475754a
......@@ -137,26 +137,6 @@ message ("Found Boost library dir: ${Boost_LIBRARY_DIR}")
message ("Found Boost libraries: ${Boost_LIBRARIES}")
include_directories (SYSTEM ${Boost_INCLUDE_DIRS})
option (ENABLE_DKS "Enable DKS" OFF)
if (ENABLE_DKS)
find_package (DKS 1.1.1 REQUIRED HINTS $ENV{DKS_PREFIX} $ENV{DKS_DIR} $ENV{DKS})
set (DKS_VERSION_OPAL \"${DKS_VERSION}\")
message ("Found DKS version: ${DKS_VERSION}")
message ("Found DKS library: ${DKS_LIBRARY}")
message ("Found DKS include dir: ${DKS_INCLUDE_DIR}")
add_definitions(-DDKS_MPI)
### OpenCL compiler flags ###
#add_compile_options (-lOpenCL -pthread -DDKS_OPENCL)
### CUDA compiler flags ###
add_definitions(-DDKS_CUDA)
### if any accelerator enabled set flag to use DKS ###
add_definitions(-DIPPL_DKS -DIPPL_DKS_CUDA -DOPAL_DKS)
endif ()
# Handle options
option (BUILD_OPAL_UNIT_TESTS "Unit tests" OFF)
if (BUILD_OPAL_UNIT_TESTS)
......
......@@ -86,21 +86,7 @@ include_directories (
add_library ( ippl ${IPPL_SRCS} ${IPPL_SRCS_FORT} )
if (ENABLE_DKS)
message ( "DKS include dirs: ${DKS_INCLUDE_DIR}")
include_directories (${DKS_INCLUDE_DIR})
link_directories (${DKS_LIBRARY_DIR})
target_link_libraries (
${TARGET_LINK_LIBRARIES}
ippl
dks
${DKS_CUDA_LIBS}
)
else()
target_link_libraries(
ippl
)
endif ()
target_link_libraries(ippl)
install (TARGETS ippl DESTINATION lib)
install (FILES ${IPPL_BASEDIR_HDRS} DESTINATION include)
......
......@@ -20,10 +20,6 @@
#include "FFT/FFTBase.h"
#ifdef IPPL_DKS
#include "DKSOPAL.h"
#endif
// forward declarations
//template <unsigned Dim> class FieldLayout;
#include "FieldLayout/FieldLayout.h"
......@@ -57,11 +53,6 @@ class FFT : public FFTBase<Dim,T> {};
template <size_t Dim, class T>
class FFT<CCTransform,Dim,T> : public FFTBase<Dim,T> {
private:
#ifdef IPPL_DKS
DKSOPAL base;
#endif
public:
typedef FieldLayout<Dim> Layout_t;
......@@ -102,18 +93,6 @@ FFT(const Domain_t& cdomain, const bool& compressTemps=false)
normFact /= lengths[d];
}
#if defined(IPPL_DKS) && defined(IPPL_DKS_CUDA)
INFOMSG("Init DKS base cuda" << endl);
base.setAPI("Cuda", 4);
base.setDevice("-gpu", 4);
base.initDevice();
#elseif defined(IPPL_DKS) && defined(IPPL_DKS_OPENCL)
INFOMSG("Init DKS base opencl" << endl);
base.setAPI("OpenCL", 6);
base.setDevice("-gpu", 4);
base.initDevice();
#endif
// set up FFT Engine
this->getEngine().setup(Dim, transformTypes, lengths);
// set up the temporary fields
......@@ -461,11 +440,7 @@ public:
/** real-to-complex FFT on GPU: transfer the real field to GPU execute FFT
return the pointer to memory on GPU where complex results are stored
*/
#ifdef IPPL_DKS
void transformDKSRC(int direction, RealField_t &f, void* real_ptr, void* comp_ptr,
DKSOPAL &dksbase, int streamId = -1, const bool& constInput=false);
#endif
*/
/** complex-to-real FFT
Same as above, but with input and output field types reversed.
*/
......@@ -473,14 +448,10 @@ public:
const bool& constInput=false);
void transform(const char* directionName, ComplexField_t& f,
RealField_t& g, const bool& constInput=false);
/** complex-to-real FFT on GPU: pass pointer to GPU memory where complex field
is stored, do the inverse FFT and transfer real field back to host memory
*/
#ifdef IPPL_DKS
void transformDKSCR(int direction, RealField_t& g, void* real_ptr, void* comp_ptr,
DKSOPAL &dksbase, int streamId = -1, const bool& constInput=false);
#endif
private:
......
This diff is collapsed.
......@@ -698,8 +698,6 @@ LField<T,Dim>::swapData( LField<T,Dim>& a )
//
//////////////////////////////////////////////////////////////////////
// allocate memory for LField and if DKS is used and page-locked (pl) is +1 allocate
// page-locked memory for storage
template<class T, unsigned Dim>
void
LField<T,Dim>::allocateStorage(int newsize)
......
......@@ -12,7 +12,4 @@ const char *ippl_compile_machine = ${IPPL_COMPILE_MACHINE};
const char *ippl_compile_options = ${IPPL_COMPILE_OPTIONS};
const char *ippl_compile_user = ${IPPL_COMPILE_USER};
/* DKS version number */
#define IPPL_DKS_VERSION ${DKS_VERSION_OPAL}
#endif
......@@ -81,15 +81,6 @@ void IpplInfo::deleteGlobals() {
std::stack<StaticIpplInfo> IpplInfo::stashedStaticMembers;
//dks base member of IpplInfo initialized to default values
bool IpplInfo::DKSEnabled = false;
#if defined(IPPL_DKS) && defined(IPPL_DKS_CUDA)
DKSOPAL *IpplInfo::DKS = new DKSOPAL("Cuda", "-gpu");
#elseif defined(IPPL_DKS) && defined(IPPL_DKS_OPENCL)
DKSOPAL *IpplInfo::DKS = new DKSOPAL("OpenCL", "-gpu");
#endif
// should we use the optimization of deferring guard cell fills until
// absolutely needed? Can be changed to true by specifying the
// flag --defergcfill
......@@ -365,27 +356,6 @@ IpplInfo::IpplInfo(int& argc, char**& argv, int removeargs, MPI_Comm mpicomm) {
param_error(argv[i],
"Please specify an output level from 0 to 5", 0);
} else if ( ( strcmp(argv[i], "--use-dks") == 0 ) ) {
// Set DKSEnabled to true if OPAL is compiled with DKS.
#ifdef IPPL_DKS
int ndev = 0;
DKS->getDeviceCount(ndev);
if (ndev > 0) {
DKSEnabled = true;
INFOMSG("DKS enabled OPAL will use GPU where possible");
INFOMSG(endl);
} else {
DKSEnabled = false;
INFOMSG("No GPU device detected! --use-dks flag will have no effect");
INFOMSG(endl);
}
//TODO: check if any device is available and disable DKS if there isn't
#else
DKSEnabled = false;
INFOMSG("OPAL compiled without DKS, " << argv[i] << " flag has no effect");
INFOMSG(endl);
#endif
} else if ( ( strcmp(argv[i], "--warn") == 0 ) ) {
// Set the output level for warning messages.
if ( (i + 1) < argc && argv[i+1][0] != '-' && atoi(argv[i+1]) >= 0 )
......@@ -760,9 +730,6 @@ int IpplInfo::mySMPNode() {
// printVersion: print out a version summary. If the argument is true,
// print out a detailed listing, otherwise a summary.
void IpplInfo::printVersion(void) {
#ifdef OPAL_DKS
INFOMSG("DKS Version " << IPPL_DKS_VERSION << endl);
#endif
INFOMSG("IPPL Framework version " << version() << endl);
INFOMSG("Last build date: " << compileDate() << " by user ");
INFOMSG(compileUser() << endl);
......
......@@ -55,11 +55,6 @@
//(without further increasing the number of defines).
#include <mpi.h>
//DKS include
#ifdef IPPL_DKS
#include "DKSOPAL.h"
#endif
// forward declarations
class IpplStats;
class IpplInfo;
......@@ -87,10 +82,6 @@ public:
static IpplStats *Stats;
#ifdef IPPL_DKS
static DKSOPAL *DKS;
#endif
// Constructor 1: specify the argc, argv values from the cmd line.
// The second argument controls whether the IPPL-specific command line
// arguments are stripped out (the default) or left in (if the setting
......@@ -252,9 +243,6 @@ public:
// library (from IpplVersions.h)
static const char *compileUser();
//Static flag telling wheteher to use DKS when runnign OPAL
static bool DKSEnabled;
// stash all static members
static void stash();
......
......@@ -2,9 +2,5 @@
#include "Message/Communicate.h"
#include "Utility/IpplStats.h"
#ifdef IPPL_DKS
#include "DKSOPAL.h"
#endif
StaticIpplInfo::StaticIpplInfo() { }
StaticIpplInfo::~StaticIpplInfo() { }
......@@ -6,10 +6,6 @@
class Communicate;
class IpplStats;
class Inform;
//DKS include
#ifdef IPPL_DKS
class DKSOPAL;
#endif
class StaticIpplInfo {
public:
......@@ -32,10 +28,6 @@ public:
Inform *Error;
Inform *Debug;
#ifdef IPPL_DKS
DKSOPAL *DKS;
#endif
// flag telling whether to use optimization for reducing
// communication by deferring guard cell fills.
bool deferGuardCellFills;
......
......@@ -16,12 +16,6 @@ link_directories (
set (IPPL_LIBS ippl)
if (ENABLE_DKS)
include_directories (${DKS_INCLUDE_DIR})
link_directories (${DKS_LIBRARY_DIR})
set (IPPL_LIBS ${IPPL_LIBS} ${DKS_LIBRARY_DIR}/libdks.a)
endif ()
add_executable (fftspeed fftspeed.cpp)
add_executable (TestFFT TestFFT.cpp)
add_executable (TestFFT-1 TestFFT-1.cpp)
......@@ -45,7 +39,7 @@ target_link_libraries (TestRCMIC ${IPPL_LIBS} ${MPI_CXX_LIBRARIES} boost_timer
add_subdirectory (SeaborgRes)
# vi: set et ts=4 sw=4 sts=4:
# Local Variables:
# mode: cmake
# cmake-tab-width: 4
......
This diff is collapsed.
......@@ -17,13 +17,6 @@ set (COMPILE_FLAGS ${OPAL_CXX_FLAGS})
set (IPPL_LIBS ippl)
if (ENABLE_DKS)
include_directories (${DKS_INCLUDE_DIR})
link_directories (${DKS_LIBRARY_DIR})
#SET (IPPL_LIBS ${IPPL_LIBS} dks)
SET (IPPL_LIBS ${IPPL_LIBS} ${DKS_LIBRARY_DIR}/libdks.a)
endif ()
add_executable (testPwrSpec testPwrSpec.cpp)
target_link_libraries (
testPwrSpec
......
......@@ -13,12 +13,6 @@ link_directories (
set (IPPL_LIBS ippl)
set (COMPILE_FLAGS ${OPAL_CXX_FLAGS})
if (ENABLE_DKS)
include_directories (${DKS_INCLUDE_DIR})
link_directories (${DKS_LIBRARY_DIR})
SET (IPPL_LIBS ${IPPL_LIBS} ${DKS_LIBRARY_DIR}/libdks.a)
endif ()
add_executable (t3 t3.cpp)
target_link_libraries (
t3
......
......@@ -13,12 +13,6 @@ link_directories (
set (IPPL_LIBS ippl)
set (COMPILE_FLAGS ${OPAL_CXX_FLAGS})
if (ENABLE_DKS)
include_directories (${DKS_INCLUDE_DIR})
link_directories (${DKS_LIBRARY_DIR})
SET (IPPL_LIBS ${IPPL_LIBS} ${DKS_LIBRARY_DIR}/libdks.a)
endif ()
add_executable (2ddens 2ddens.cpp)
target_link_libraries (
2ddens
......
......@@ -18,14 +18,6 @@ link_directories (
set (IPPL_LIBS ippl)
set (COMPILE_FLAGS ${OPAL_CXX_FLAGS})
if (ENABLE_DKS)
include_directories (${DKS_INCLUDE_DIR})
link_directories (${DKS_LIBRARY_DIR})
#SET (IPPL_LIBS ${IPPL_LIBS} dks)
SET (IPPL_LIBS ${IPPL_LIBS} ${DKS_LIBRARY_DIR}/libdks.a)
endif ()
add_executable (PIC3d PIC3d.cpp)
target_link_libraries (
PIC3d
......
......@@ -13,12 +13,6 @@ link_directories (
set (IPPL_LIBS ippl)
set (COMPILE_FLAGS ${OPAL_CXX_FLAGS})
if (ENABLE_DKS)
include_directories (${DKS_INCLUDE_DIR})
link_directories (${DKS_LIBRARY_DIR})
SET (IPPL_LIBS ${IPPL_LIBS} ${DKS_LIBRARY_DIR}/libdks.a)
endif ()
add_executable (ScalarAdvection ScalarAdvection.cpp)
target_link_libraries (
ScalarAdvection
......
......@@ -13,12 +13,6 @@ link_directories (
set (IPPL_LIBS ippl)
set (COMPILE_FLAGS ${OPAL_CXX_FLAGS})
if (ENABLE_DKS)
include_directories (${DKS_INCLUDE_DIR})
link_directories (${DKS_LIBRARY_DIR})
SET (IPPL_LIBS ${IPPL_LIBS} ${DKS_LIBRARY_DIR}/libdks.a)
endif ()
add_executable (TestSIndex TestSIndex.cpp)
target_link_libraries (
TestSIndex
......
......@@ -18,14 +18,6 @@ link_directories (
set (IPPL_LIBS ippl)
if (ENABLE_DKS)
include_directories (${DKS_INCLUDE_DIR})
link_directories (${DKS_LIBRARY_DIR})
set (IPPL_LIBS ${IPPL_LIBS} ${DKS_LIBRARY_DIR}/libdks.a)
endif ()
add_executable (ipplToyFDTD ${IPPLTOYFDTD_SRCS} ToyFDTD-DataSink/ipplToyFDTD2.cpp)
target_link_libraries (
ipplToyFDTD
......@@ -35,7 +27,7 @@ target_link_libraries (
)
# vi: set et ts=4 sw=4 sts=4:
# Local Variables:
# mode: cmake
# cmake-tab-width: 4
......
......@@ -77,13 +77,7 @@ ParallelTTracker::ParallelTTracker(const Beamline &beamline,
WakeFieldTimer_m(IpplTimings::getTimer("WakeField")),
particleMatterStatus_m(false),
totalParticlesInSimulation_m(0)
{
#ifdef OPAL_DKS
if (IpplInfo::DKSEnabled)
setupDKS();
#endif
}
{}
ParallelTTracker::ParallelTTracker(const Beamline &beamline,
PartBunchBase<double, 3> *bunch,
......@@ -123,19 +117,9 @@ ParallelTTracker::ParallelTTracker(const Beamline &beamline,
stepSizes_m.sortAscendingZStop();
stepSizes_m.resetIterator();
#ifdef OPAL_DKS
if (IpplInfo::DKSEnabled)
setupDKS();
#endif
}
ParallelTTracker::~ParallelTTracker() {
#ifdef OPAL_DKS
if (IpplInfo::DKSEnabled)
delete dksbase;
#endif
}
ParallelTTracker::~ParallelTTracker() {}
void ParallelTTracker::visitBeamline(const Beamline &bl) {
const FlaggedBeamline* fbl = static_cast<const FlaggedBeamline*>(&bl);
......@@ -296,11 +280,6 @@ void ParallelTTracker::execute() {
setOptionalVariables();
#ifdef OPAL_DKS
if (IpplInfo::DKSEnabled)
allocateDeviceMemory();
#endif
globalEOL_m = false;
wakeStatus_m = false;
deletedParticles_m = false;
......@@ -382,11 +361,6 @@ void ParallelTTracker::execute() {
OPALTimer::Timer myt3;
*gmsg << "done executing ParallelTTracker at " << myt3.time() << endl;
#ifdef OPAL_DKS
if (IpplInfo::DKSEnabled)
freeDeviceMemory();
#endif
Monitor::writeStatistics();
OpalData::getInstance()->setPriorTrack();
......@@ -405,15 +379,7 @@ void ParallelTTracker::prepareSections() {
void ParallelTTracker::timeIntegration1(BorisPusher & pusher) {
IpplTimings::startTimer(timeIntegrationTimer1_m);
#ifdef OPAL_DKS
if (IpplInfo::DKSEnabled)
pushParticlesDKS();
else
pushParticles(pusher);
#else
pushParticles(pusher);
#endif
IpplTimings::stopTimer(timeIntegrationTimer1_m);
}
......@@ -438,20 +404,9 @@ void ParallelTTracker::timeIntegration2(BorisPusher & pusher) {
*/
IpplTimings::startTimer(timeIntegrationTimer2_m);
#ifdef OPAL_DKS
if (IpplInfo::DKSEnabled) {
kickParticlesDKS();
pushParticlesDKS(false);
} else {
kickParticles(pusher);
pushParticles(pusher);
}
#else
kickParticles(pusher);
//switchElements();
pushParticles(pusher);
#endif
const unsigned int localNum = itsBunch_m->getLocalNum();
for (unsigned int i = 0; i < localNum; ++ i) {
......@@ -822,7 +777,7 @@ void ParallelTTracker::computeParticleMatterInteraction(IndexMap::value_t elemen
}
boundingSphere.first = refToLocalCSTrafo.transformTo(boundingSphere.first);
it->apply(itsBunch_m, boundingSphere, totalParticlesInSimulation_m);
it->apply(itsBunch_m, boundingSphere);
it->print(msg);
boundingSphere.first = localToRefCSTrafo.transformTo(boundingSphere.first);
......
......@@ -247,29 +247,6 @@ private:
unsigned long totalParticlesInSimulation_m;
#ifdef OPAL_DKS
DKSOPAL *dksbase;
void *r_ptr;
void *p_ptr;
void *Ef_ptr;
void *Bf_ptr;
void *dt_ptr;
int stream1;
int stream2;
int numDeviceElements;
void setupDKS();
void allocateDeviceMemory();
void freeDeviceMemory();
void sendRPdt();
void sendEfBf();
void pushParticlesDKS(bool send = true);
void kickParticlesDKS();
#endif
/********************** END VARIABLES ***********************************/
void kickParticles(const BorisPusher &pusher);
......@@ -450,100 +427,4 @@ inline void ParallelTTracker::pushParticles(const BorisPusher &pusher) {
itsBunch_m->switchOffUnitlessPositions(true);
}
#ifdef OPAL_DKS
inline void ParallelTTracker::setupDKS() {
dksbase = new DKSOPAL;
dksbase->setAPI("Cuda");
dksbase->setDevice("-gpu");
dksbase->initDevice();
dksbase->createStream(stream1);
dksbase->createStream(stream2);
}
inline void ParallelTTracker::allocateDeviceMemory() {
int ierr;
r_ptr = dksbase->allocateMemory<Vector_t>(itsBunch_m->getLocalNum(), ierr);
p_ptr = dksbase->allocateMemory<Vector_t>(itsBunch_m->getLocalNum(), ierr);
Ef_ptr = dksbase->allocateMemory<Vector_t>(itsBunch_m->getLocalNum(), ierr);
Bf_ptr = dksbase->allocateMemory<Vector_t>(itsBunch_m->getLocalNum(), ierr);
dt_ptr = dksbase->allocateMemory<double>(itsBunch_m->getLocalNum(), ierr);
if (Ippl::getNodes() == 1) {
dksbase->registerHostMemory(&itsBunch_m->R[0], itsBunch_m->getLocalNum());
dksbase->registerHostMemory(&itsBunch_m->P[0], itsBunch_m->getLocalNum());
dksbase->registerHostMemory(&itsBunch_m->Ef[0], itsBunch_m->getLocalNum());
dksbase->registerHostMemory(&itsBunch_m->Bf[0], itsBunch_m->getLocalNum());
dksbase->registerHostMemory(&itsBunch_m->dt[0], itsBunch_m->getLocalNum());
}
numDeviceElements = itsBunch_m->getLocalNum();
}
inline void ParallelTTracker::freeDeviceMemory() {
dksbase->freeMemory<Vector_t>(r_ptr, numDeviceElements);
dksbase->freeMemory<Vector_t>(p_ptr, numDeviceElements);
dksbase->freeMemory<Vector_t>(Ef_ptr, numDeviceElements);
dksbase->freeMemory<Vector_t>(Bf_ptr, numDeviceElements);
dksbase->freeMemory<double>(dt_ptr, numDeviceElements);
if (Ippl::getNodes() == 1) {
dksbase->unregisterHostMemory(&itsBunch_m->R[0]);
dksbase->unregisterHostMemory(&itsBunch_m->P[0]);
dksbase->unregisterHostMemory(&itsBunch_m->Ef[0]);
dksbase->unregisterHostMemory(&itsBunch_m->Bf[0]);
dksbase->unregisterHostMemory(&itsBunch_m->dt[0]);
}
}
inline void ParallelTTracker::sendRPdt() {
dksbase->writeDataAsync<Vector_t>(r_ptr, &itsBunch_m->R[0], itsBunch_m->getLocalNum(), stream1);
dksbase->writeDataAsync<Vector_t>(p_ptr, &itsBunch_m->P[0], itsBunch_m->getLocalNum(), stream1);
dksbase->writeDataAsync<double>(dt_ptr, &itsBunch_m->dt[0], itsBunch_m->getLocalNum(), stream1);
}
inline void ParallelTTracker::sendEfBf() {
dksbase->writeDataAsync<Vector_t>(Ef_ptr, &itsBunch_m->Ef[0],
itsBunch_m->getLocalNum(), stream1);
dksbase->writeDataAsync<Vector_t>(Bf_ptr, &itsBunch_m->Bf[0],
itsBunch_m->getLocalNum(), stream1);
}
inline void ParallelTTracker::pushParticlesDKS(bool send) {
//send data to the GPU
if (send)
sendRPdt();
//execute particle push on the GPU
dksbase->callParallelTTrackerPush(r_ptr, p_ptr, dt_ptr, itsBunch_m->getLocalNum(),
Physics::c, stream1);
//get particles back to CPU
dksbase->readData<Vector_t>(r_ptr, &itsBunch_m->R[0], itsBunch_m->getLocalNum(), stream1);
}
inline
void ParallelTTracker::kickParticlesDKS() {
//send data to the GPU
sendEfBf();
sendRPdt();
//sync device
dksbase->syncDevice();
//execute kick on the GPU
dksbase->callParallelTTrackerKick(r_ptr, p_ptr, Ef_ptr, Bf_ptr, dt_ptr,
itsReference.getQ(), itsReference.getM(),
itsBunch_m->getLocalNum(), Physics::c, stream2);
dksbase->syncDevice();
//get data back from GPU
dksbase->readDataAsync<Vector_t>(p_ptr, &itsBunch_m->P[0], itsBunch_m->getLocalNum(), stream2);
}
#endif
#endif // OPAL_ParallelTTracker_HH
\ No newline at end of file
set (DKS_VERSION_OPAL \"${DKS_VERSION}\")
add_definitions (-DPARALLEL_IO)
if (ENABLE_SAAMG_SOLVER)
......@@ -18,7 +16,6 @@ if (ENABLE_AMR)
${Fortran_LIBS}
${AMREX_EXTRA_Fortran_LINK_LINE}
${AMREX_LIBRARIES}
)
else ()
set(AMR_LIBS "")
......@@ -123,11 +120,6 @@ link_directories (
${AMREX_LIBRARY_DIR}
)
if (ENABLE_DKS)
include_directories (${DKS_INCLUDE_DIR})
link_directories (${DKS_LIBRARY_DIR})
endif ()
#
# we cannot use the target name 'OPAL' for 'libOPAL'. On systems with
# case-insensitive filesystems (like macOS) this conflicts with the
......@@ -136,12 +128,6 @@ endif ()
add_library (libOPAL ${OPAL_SRCS})
set_target_properties (libOPAL PROPERTIES OUTPUT_NAME OPAL)
if (ENABLE_DKS)
target_link_libraries (libOPAL
dks
${DKS_CUDA_LIBS})
endif ()
target_link_libraries (libOPAL
${SAAMG_SOLVER_LIBS}
${AMR_MG_SOLVER_LIBS}
......
......@@ -114,8 +114,7 @@ const std::string BeamStrippingPhysics::getType() const {
}
void BeamStrippingPhysics::apply(PartBunchBase<double, 3> *bunch,
const std::pair<Vector_t, double> &/*boundingSphere*/,
size_t /*numParticlesInSimulation*/) {
const std::pair<Vector_t, double> &/*boundingSphere*/) {
dT_m = bunch->getdT();
......
......@@ -48,9 +48,8 @@ public:
void setCyclotron(Cyclotron* cycl) { cycl_m = cycl; };
void apply(PartBunchBase<double, 3> *bunch,
const std::pair<Vector_t, double> &boundingSphere,
size_t numParticlesInSimulation = 0);
virtual void apply(PartBunchBase<double, 3> *bunch,
const std::pair<Vector_t, double> &boundingSphere);
virtual const std::string getType() const;