OPALX (Object Oriented Parallel Accelerator Library for Exascal) master (dc2a29eed580)
OPALX
Loading...
Searching...
No Matches
Track.h
Go to the documentation of this file.
1//
2// Class Track
3// Hold data for tracking.
4// Acts as a communication area between the various tracking commands.
5//
6// Copyright (c) 2008 - 2020, Paul Scherrer Institut, Villigen PSI, Switzerland
7// All rights reserved
8//
9// This file is part of OPAL.
10//
11// OPAL is free software: you can redistribute it and/or modify
12// it under the terms of the GNU General Public License as published by
13// the Free Software Foundation, either version 3 of the License, or
14// (at your option) any later version.
15//
16// You should have received a copy of the GNU General Public License
17// along with OPAL. If not, see <https://www.gnu.org/licenses/>.
18//
19
20#ifndef OPAL_Track_HH
21#define OPAL_Track_HH
22#include "Algorithms/PartData.h"
23#include "PartBunch/PartBunch.h"
24#include "Steppers/Steppers.h"
25#include "Track/TrackCmd.h"
26#include "Track/TrackParser.h"
27
28#include <stack>
29#include <string>
30#include <vector>
31
32class BeamSequence;
34
35class Track {
36public:
37 Track(BeamSequence*, const PartData&, const std::vector<double>& dt,
38 const std::vector<unsigned long long>& maxtsteps, int stepsperturn, double zStart,
39 const std::vector<double>& zStop, Steppers::TimeIntegrator timeintegrator, double t0,
40 double dtScInit, double deltaTau, EmissionSourceList* emissionSourcesList = nullptr,
41 const std::vector<std::string>& beamNames = {});
42 ~Track();
43
46
49
52
55
58
60 static Track* block;
61
63 std::vector<double> dT;
64
65 // For AMTS integrator in OPAL-T
67
70 double t0_m;
71
73 std::vector<unsigned long long> localTimeSteps;
74
77
79 double zstart;
80
82 std::vector<double> zstop;
83
86
89
92 std::vector<std::string> beamNames_m;
93
94private:
95 // Not implemented.
97 Track(const Track&);
98 void operator=(const Track&);
99
100 static std::stack<Track*> stashedTrack;
101};
102
103#endif // OPAL_Track_HH
Template PIC bunch: IPPL PicManager, shared field mesh/solver, and multiple particle containers.
The base class for all OPAL beam lines and sequences.
Particle reference data.
Definition PartData.h:37
Definition Track.h:35
std::vector< std::string > beamNames_m
Definition Track.h:92
BeamSequence * use
The lattice to be tracked through.
Definition Track.h:51
int stepsPerTurn
The timsteps per revolution period. ONLY available for OPAL-cycl.
Definition Track.h:76
PartData reference
The reference data.
Definition Track.h:48
void operator=(const Track &)
double zstart
The location at which the simulation starts.
Definition Track.h:79
~Track()
Definition Track.cpp:66
std::vector< unsigned long long > localTimeSteps
Maximal number of timesteps.
Definition Track.h:73
double deltaTau
Definition Track.h:66
std::vector< double > zstop
The location at which the simulation stops.
Definition Track.h:82
static Track * block
The block of track data.
Definition Track.h:60
Steppers::TimeIntegrator timeIntegrator
The ID of time integrator.
Definition Track.h:85
TrackParser parser
The parser used during tracking.
Definition Track.h:57
static std::stack< Track * > stashedTrack
Definition Track.h:100
double t0_m
Definition Track.h:70
double dtScInit
Definition Track.h:66
int truncOrder
Trunction order for map tracking.
Definition Track.h:88
EmissionSourceList * emissionSources
The emission sources list for particle injection (SOURCES= on TRACK).
Definition Track.h:54
PartBunch_t * bunch
The particle bunch to be tracked.
Definition Track.h:45
Track(const Track &)
std::vector< double > dT
The initial timestep.
Definition Track.h:63
TimeIntegrator
Definition Steppers.h:25