29 , fieldlayout_m(nullptr)
38 , fieldlayout_m(nullptr)
74 if ( !isForbidTransform ) {
86 if ( !isForbidTransform ) {
97 return hr_m * scalefactor;
134 throw OpalException(
"AmrPartBunch::getFieldLayout() ",
"Not yet Implemented.");
153 if ( !isForbidTransform ) {
162 if ( !isForbidTransform ) {
171 "AmrObject pointer is not set.");
230 std::unique_ptr<size_t[]> partPerLevel(
new size_t[nLevel] );
233 for (
int i = 0; i < nLevel; ++i)
239 for (
size_t i = 0; i < LocalNumPerLevel.size(); ++i)
240 partPerLevel[i] = LocalNumPerLevel[i];
242 reduce(*partPerLevel.get(),
244 nLevel, std::plus<size_t>());
266 if ( gamma >= 1.0 ) {
280 Vector_t lorentzFactor(1.0, 1.0, 1.0);
283 lorentzFactor[1] = gamma;
285 lorentzFactor[2] = gamma;
bool reduce(Communicate &, InputIterator, InputIterator, OutputIterator, const ReduceOp &, bool *IncludeVal=0)
virtual void set_meshEnlargement(double dh)
IpplTimings::TimerRef boundpTimer_m
double getBinGamma(int bin)
Get gamma of one bin.
FieldSolver * fs_m
stores the used field solver
std::pair< Vector_t, Vector_t > VectorPair_t
Vector_t hr_m
meshspacing of cartesian mesh
UnitState_t stateOfLastBoundP_
IpplTimings::TimerRef selfFieldTimer_m
timer for selfField calculation
static OpalData * getInstance()
virtual Vektor< int, 3 > getBaseLevelGridPoints() const =0
virtual void initFineLevels()=0
virtual double getRho(int x, int y, int z)=0
const bool & isRefined() const
virtual void computeSelfFields_cycl(double gamma)=0
virtual VectorPair_t getEExtrema()=0
virtual const int & maxLevel() const =0
virtual void computeSelfFields()=0
void setBoundingBox(double dh)
void setDomainRatio(const std::vector< double > &ratio)
void computeSelfFields_cycl(double gamma)
void updateDomainLength(Vektor< int, 3 > &grid)
void initialize(FieldLayout_t *fLayout)
void updateLorentzFactor(int bin=0)
AmrPartBunch(const PartData *ref)
VectorPair_t getEExtrema()
FieldLayout_t * fieldlayout_m
void set_meshEnlargement(double dh)
const size_t & getLevelStatistics(int l) const
std::unique_ptr< size_t[]> globalPartPerLevel_m
void gatherLevelStatistics()
void updateFieldContainers_m()
void setAmrDomainRatio(const std::vector< double > &ratio)
void updateFields(const Vector_t &hr, const Vector_t &origin)
pbase_t * getAmrParticleBase()
double getRho(int x, int y, int z)
FieldLayout_t & getFieldLayout()
The base class for all OPAL exceptions.
void setLorentzFactor(const Vector_t &lorentzFactor)
bool isForbidTransform() const
const double & getScalingFactor() const
const ParticleLevelCounter_t & getLocalNumPerLevel() const
void setForbidTransform(bool forbidTransform)
const double & domainMapping(bool inverse=false)
static void stopTimer(TimerRef t)
static void startTimer(TimerRef t)