# UBA-FNAL QSS-Geant4 Meeting¶

## Parameters for simple tests for the proof of principle

(prepared by Soon)¶

### Equation of Motion of a charged particle in the magnetic field (the Lorentz Equation)¶

`m d/dt gamma dx/dt = q (v x B)`

`(For the relativistic treatment, please see`

http://www-geant4.kek.jp/lxr/source/geometry/magneticfield/src/G4EqMagElectricField.cc#L58 )

where

x = position vector (x,y,z)

v = momentum vector (vx, vy, vz)

B = magnetic field vector (Bx, By, Bz)

t = time

m = mass of particle

q = charge of particle

c = speed of light

gamma = 1/sqrt(1-beta*beta) where beta = magnitude(v)/c

### Initial conditions for an electron in the uniform magnetic field and stepping parameters¶

use (unit-less) parameters following the Geant4 system of units mm = 1, MeV = 1, nanosecond (ns) = 1, eplus=1

c = 299.792458 mm/ns ;

m = M/c^2 where M = 0.5109989 MeV (elctron_mass_c2)

x = (0,0,0)

v = (0.999c,0,0) this is equivalent to (kinetic) energy = M * (gamma -1) = M * (22.366272 - 1) ~ 10.9181415106 MeV

B = (0,0,0.001) 1 tesla = 1E-3 (MeV/eplus)*(ns/mm*mm)

q = - eplus = - 1 (for electron)

the default step size to trial = 1 mm

the truncation error or the QSS quantum = 0.01 mm / 100 (the default step) = 0.0001 mm

### Expected Radius and Period (please check)¶

Radius = (M/c^2) * gamma * v/ B = 0.5109989 * 22.366272 *0.999 * 1000 / 299.7922458 ~ 38.0854 [mm]

Period = 2*pi/w = 2*pi /(B/((M/c^2) * gamma)) = 6.283185 * 1000 * (0.5109989/(299.7922458*299.7922458)) * 22.366272 ~ 0.7990 [ns]

see the repository for the N02 based tracking only example