The Simulation class

The Simulation class is top-level class in KENV. It contains all the simulation data, and has the high-level method track that performs the integrate.

class kenv.solver.Simulation(beam, accelerator, particle=<kenv.beam.Particle object>)[source]

Initializes a Simulation.

Parameters
  • beam (an instance of Beam) – Beam data

  • accelerator (an instance of Accelerator) – Accelerator data

  • Particle (an instance of Particle, optional) – Particle data

track(*, particle: bool = False, centroid: bool = False, envelope: bool = True, rtol: float = 0.0001, atol: float = 1e-07, method: str = 'RK23')[source]

Tracking!

Parameters
  • particle (bool) – Particle equations switch

  • centroid (bool) – Centroid equations switch

  • envelope (bool) – Envelope equations switch

  • rtol (float, optional) –

  • atol (float, optional) –

  • method (str, optional) –