#include #include using namespace std; #define PI 3.1415926 #include "HDGEOMETRY/DMagneticFieldMap.h" #include "MyTrajectory.h" #include "MyTrajectoryBfield.h" int main() { DMagneticFieldMap *bfield; double charge = 1.0, p = 1.0 , theta = PI/6.0, phi = PI/4.0; HepVector B(3), x0(3); B(1) = 0.0; B(2) = 0.0; B(3) = 4.0; x0(1) = 0.0; x0(2) = 0.0; x0(3) = 0.0; MyTrajectoryBfield trajectory(bfield); trajectory.swim(charge, x0, p, theta, phi); trajectory.print(); return 0; }