18#include "BDSFieldESinusoid.hh"
19#include "BDSMagnetStrength.hh"
20#include "BDSUtilities.hh"
22#include "G4ThreeVector.hh"
25#include "CLHEP/Units/SystemOfUnits.h"
31 G4ThreeVector( (*strength)[
"ex"], (*strength)[
"ey"], (*strength)[
"ez"]),
32 (*strength)[
"frequency"],
34 (*strength)[
"synchronousT0"])
37BDSFieldESinusoid::BDSFieldESinusoid(G4double eFieldAmplitudeIn,
38 const G4ThreeVector& unitDirectionIn,
41 G4double synchronousTIn):
42 eField(eFieldAmplitudeIn),
43 unitDirection(unitDirectionIn.unit()),
44 angularFrequency(CLHEP::twopi*frequencyIn),
46 synchronousT(synchronousTIn)
52 const G4double t)
const
A sinusoidal electric (only) field that doesn't vary with position. Uses cosine.
G4double angularFrequency
Angular frequency of field.
virtual G4ThreeVector GetField(const G4ThreeVector &position, const G4double t) const
Accessor for field value.
const G4ThreeVector unitDirection
Peak amplitude of electric field.
G4double synchronousT
Global T offset for 0 phase.
G4bool finiteStrength
Flag to cache whether finite nor not.
Efficient storage of magnet strengths.
G4bool IsFinite(G4double value, G4double tolerance=std::numeric_limits< double >::epsilon())