piol.particlesource module

Inheritance diagram

Inheritance diagram of piol.particlesource

API reference

class piol.particlesource.GaussianSource(N, ax, bx, ex, ay, by, ey, *coords)[source]

Bases: piol.element.Element

Initialize particle source for a beam with Gaussian distribution

Parameters
  • N (int) – Number of particles added

  • ax (float) – Twiss parameter alpha of distribution in x-direction

  • bx (float) – Twiss parameter beta of distribution in x-direction

  • ex (float) – The rms emittance of distribution in x-direction

  • ay (float) – Twiss parameter alpha of distribution in y-direction

  • by (float) – Twiss parameter beta of distribution in y-direction

  • ey (float) – The rms emittance of distribution in y-direction

  • coords (tuple) – A tuple of tuples for other beam properties.

printDebug(indent='')[source]

Print debugging information for element.

transfer(driver)[source]

Transfers the particles saved in the driver through the element.

Parameters

driver (Driver) – Driver of the system

class piol.particlesource.GeneralParticleSource(N, *coords, **kwargs)[source]

Bases: piol.element.Element

Initialize particle source

printDebug(indent='')[source]

Print debugging information for element.

setParameter(parameter, value)[source]

Modifies given parameter.

transfer(driver)[source]

Transfers the particles saved in the driver through the element.

Parameters

driver (Driver) – Driver of the system

class piol.particlesource.KVSource(N, ax, bx, ex, ay, by, ey, *coords)[source]

Bases: piol.element.Element

Initialize particle source for a beam with KV distribution

Parameters
  • N (int) – Number of particles added

  • ax (float) – Twiss parameter alpha of distribution in x-direction

  • bx (float) – Twiss parameter beta of distribution in x-direction

  • ex (float) – The rms emittance of distribution in x-direction

  • ay (float) – Twiss parameter alpha of distribution in y-direction

  • by (float) – Twiss parameter beta of distribution in y-direction

  • ey (float) – The rms emittance of distribution in y-direction

  • coords (tuple) – A tuple of tuples for other beam properties.

printDebug(indent='')[source]

Print debugging information for element.

transfer(driver)[source]

Transfers the particles saved in the driver through the element.

Parameters

driver (Driver) – Driver of the system

class piol.particlesource.WaterbagSource(N, ax, bx, ex, ay, by, ey, *coords)[source]

Bases: piol.element.Element

Initialize particle source for a beam with Waterbag distribution

Parameters
  • N (int) – Number of particles added

  • ax (float) – Twiss parameter alpha of distribution in x-direction

  • bx (float) – Twiss parameter beta of distribution in x-direction

  • ex (float) – The rms emittance of distribution in x-direction

  • ay (float) – Twiss parameter alpha of distribution in y-direction

  • by (float) – Twiss parameter beta of distribution in y-direction

  • ey (float) – The rms emittance of distribution in y-direction

  • coords (tuple) – A tuple of tuples for other beam properties.

printDebug(indent='')[source]

Print debugging information for element.

transfer(driver)[source]

Transfers the particles saved in the driver through the element.

Parameters

driver (Driver) – Driver of the system