BDSIM
BDSIM is a Geant4 extension toolkit for simulation of particle transport in accelerator beamlines.
BDSIntegratorTeleporter.hh
1/*
2Beam Delivery Simulation (BDSIM) Copyright (C) Royal Holloway,
3University of London 2001 - 2022.
4
5This file is part of BDSIM.
6
7BDSIM is free software: you can redistribute it and/or modify
8it under the terms of the GNU General Public License as published
9by the Free Software Foundation version 3 of the License.
10
11BDSIM is distributed in the hope that it will be useful, but
12WITHOUT ANY WARRANTY; without even the implied warranty of
13MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14GNU General Public License for more details.
15
16You should have received a copy of the GNU General Public License
17along with BDSIM. If not, see <http://www.gnu.org/licenses/>.
18*/
19#ifndef BDSINTEGRATORTELEPORTER_H
20#define BDSINTEGRATORTELEPORTER_H
21
22#include "BDSIntegratorMag.hh"
23
24#include "globals.hh" // geant4 types / globals
25#include "G4ThreeVector.hh"
26#include "G4Transform3D.hh"
27
28class G4Mag_EqRhs;
30
38{
39public:
40 BDSIntegratorTeleporter(G4Mag_EqRhs* eqOfMIn,
41 G4Transform3D teleporterDeltaIn,
42 G4double teleporterLengthIn,
43 BDSPTCOneTurnMap* oneTurnMapIn=nullptr);
44
46
47 virtual void Stepper(const G4double yIn[],
48 const G4double dydx[],
49 const G4double h,
50 G4double yOut[],
51 G4double yErr[]);
52
53private:
54
55 const G4Transform3D transform;
56 const G4ThreeVector dPos;
57 const G4double teleporterLength;
58 BDSPTCOneTurnMap* oneTurnMap;
59 G4bool threeDMethod;
60};
61
62#endif
Common functionality to BDSIM integrators.
Custom unphysical integrator to advance particle in teleporter.
G4bool threeDMethod
Whether to use full 3D transform.
Class to load and use PTC 1 turn map.