QEDfields
Documentation for QEDfields.
QEDfields.AbstractBackgroundField
QEDfields.AbstractPulsedPlaneWaveField
QEDfields.CosSquarePulse
QEDfields.GaussianPulse
QEDfields._envelope
QEDfields._unsafe_gaussian_envelope
QEDfields.amplitude
QEDfields.domain
QEDfields.envelope
QEDfields.generic_spectrum
QEDfields.oscillator
QEDfields.polarization_vector
QEDfields.pulse_length
QEDfields.reference_momentum
QEDfields.AbstractBackgroundField
— TypeAbstract base type for describing classical background fields.
The only supported class of background fields yet, is the pulsed plane-wave field (see AbstractPulsedPlaneWaveField
for details).
QEDfields.AbstractPulsedPlaneWaveField
— TypeAbstract base type for pulsed plane-wave fields.
For every subtype, the following functions need to be implemented.
reference_momentum(::AbstractPulsedPlaneWaveField)
domain(::AbstractPulsedPlaneWaveField)
pulse_length(::AbstractPulsedPlaneWaveField)
envelope(::AbstractPulsedPlaneWaveField,x::Real)
QEDfields.CosSquarePulse
— TypeCosSquarePulse(mom::M,pulse_length::T) where {M<:QEDbase.AbstractFourMomentum,T<:Real}
Concrete implementation of an AbstractPulsedPlaneWaveField
for cos-square pulses.
The pulse envelope of a cos-square pulse is defined as
\[g(\phi) = \cos^2(\frac{\pi\phi}{2\Delta\phi})\]
for $\phi\in (-\Delta\phi,\Delta\phi)$, where $\Delta\phi$ denotes the pulse_length
, and zero otherwise.
QEDfields.GaussianPulse
— TypeGaussianPulse(mom::M,pulse_length::T) where {M<:QEDbase.AbstractFourMomentum,T<:Real}
Concrete implementation of an AbstractPulsedPlaneWaveField
for Gaussian pulses.
Propagates along the direction given by the space-like components of the reference momentum vector kmu = (omega/speedoflight, kx, ky, kz), and omega = 2pispeedoflight/wavelength.
The time-like coordinate omega/speedofligth of k_mu defines the field's oscillation frequency.
In order to fulfill the vacuum dispersion relation, k_mu*k^mu=0 is required.
The longitudinal envelope of a Gaussian pulse is defined as
\[g(\phi) = \exp(-\frac{\phi^2}{2\Delta\phi^2})\]
for $\phi\in (-\infty, \infty) and $\Delta\phi`$ denotes the pulse_length
.
There is no envelope in the transverse directions.
QEDfields._envelope
— Function_envelope(::AbstractPulsedPlaneWaveField, phi::Real)
Interface function for AbstractPulsedPlaneWaveField
, which returns the value of the phase envelope function (also referred to as pulse envelope) for a given phase variable.
The interface function can be implemented for just one phase point as input. With that, evaluation on a vector of inputs is generically implemented by broadcasting. However, if there is a better custom implementation for vectors in input values, consider implementing
_envelope(::AbstractPulsedPlaneWaveField, phi::AbstractVector{T<:Real})
This is the unsafe version of the phase envelope function, i.e. this should be implement without input checks like the domain check. In the safe version envelope
, a domain check is performed, i.e. it returns the value of _envelope
if the passed in phi
is in the domain
of the field, and zero otherwise.
QEDfields._unsafe_gaussian_envelope
— Method_unsafe_gaussian_envelope(phi::Real, dphi::Real)
The envelope of the Gaussian background field is defined according to the standard Gaussian distribution with dphi
representing the distribution's standard deviation.
QEDfields.amplitude
— Methodamplitude(field::AbstractPulsedPlaneWaveField, pol::AbstractDefinitePolarization, phi)
Returns the value of the amplitude for a given polarization direction and phase variable phi
.
There are two directions supported:
pol::PolX # -> return envelope(phi)*cos(phi)
pol::PolY # -> return envelope(phi)*sin(phi)
In this function, a domain check is performed, i.e. if phi
is in the domain of the field, the value of the amplitude is returned, and zero otherwise.
QEDfields.domain
— Functiondomain(::AbstractPulsedPlaneWaveField)
Interface function for AbstractPulsedPlaneWaveField
, which returns interval (as a IntervalSets.Interval
) for the given background field.
QEDfields.envelope
— Methodenvelope(pulsed_field::AbstractPulsedPlaneWaveField, phi::Real)
Return the value of the phase envelope function (also referred to as pulse envelope or pulse shape) for given pulsed_field
and phase phi
. Performs domain check on phi
before calling _envelope
; returns zero if phi
is not in the domain returned by [domain](@ref)
.
QEDfields.generic_spectrum
— Methodgeneric_spectrum(field::AbstractPulsedPlaneWaveField, pol::AbstractDefinitePolarization, pnum)
Return the generic spectrum of the given field, for the given polarization direction pol
and a given photon number parameter pnum
.
The generic spectrum is defined as the Fourier transform of the respective amplitude function for the given polarization direction:
\[\begin{align*} x-\mathrm{pol} &\to \int_{-\infty}^{\infty} g(\phi) \cos(\phi) \exp(il\phi)\\ y-\mathrm{pol} &\to \int_{-\infty}^{\infty} g(\phi) \sin(\phi) \exp(il\phi) \end{align*}\]
where $g(\phi)$ is the envelope
and $l$ the photon number parameter.
QEDfields.oscillator
— Functionoscillator(pol::AbstractPolarizaion, phi::Real)
Return the value of the base oscillator associated with a given polarization pol
at a given point phi
.
The current default implementation are
PolX() -> cos(phi)
PolY() -> sin(phi)
AllPol() -> (cos(phi), sin(phi))
QEDfields.polarization_vector
— Methodpolarization_vector(pol::AbstractPolarization, mom::QEDbase.AbstractFourMomentum)
Return the polarization vector for a given polarization and four-momentum mom
. For a definite polarization, the respective LorentzVector
is returned, where as for an indefinite polarization, a tuple of polarization vectors is returned.
In the current implementation, we use the base_state
function for Photon
provided by QEDcore.jl
.
QEDfields.pulse_length
— Functionpulse_length(::AbstractPulsedPlaneWaveField)
Interface function for AbstractPulsedPlaneWaveField
, which returns a dimensionless representative number for the duration of the background field, i.e. a half-width or standard deviation in units of phase periods.
QEDfields.reference_momentum
— Functionreference_momentum(::AbstractPulsedPlaneWaveField)
Interface function for AbstractPulsedPlaneWaveField
, which returns the reference momentum (as a subtype of QEDbase.AbstractFourMomentum
) associated with the passed background field.