Basic Functions

ABCDMatrixOptics.propagateFunction
propagate(e::Union{Element, Vector{<:Element}}, b)

Propagate a beam b either by a single element e::Element or Vector{<:Element}.

Return is the final beam. Also available as e * b.

Example

julia> beam = FreeSpace(10) * GeometricBeam(w=10.0, k=1.0)
GeometricBeam{Float64}(20.0, 1.0, 10.0)

julia> beam = [ThinLens(10), FreeSpace(10)] * GeometricBeam(w=10.0, k=0.0)
GeometricBeam{Float64}(0.0, -1.0, 10.0)

julia> beam.w ≈ 0
true
ABCDMatrixOptics.traceFunction
trace(elems::Vector{<:Element}, b0::AbstractBeam)

Trace a beam b0 through a vector of elements elems. All intermediate states of the beam will be recorded.

Return is a Vector of states where the last entry is the final beam. Final beam is equivalent to propagate(elems, b0).

Example

julia> trace([ThinLens(10), FreeSpace(10)], GeometricBeam(w=10.0, k=0.0))
3-element Vector{GeometricBeam{Float64}}:
GeometricBeam{Float64}(10.0, 0.0, 0.0)
GeometricBeam{Float64}(10.0, -1.0, 0.0)
GeometricBeam{Float64}(0.0, -1.0, 10.0)
ABCDMatrixOptics.transfer_matrixFunction
transfer_matrix(element::Element)

Returns the Ray Transfer (ABCD) matrix associated with the given, optical element.

transfer_matrix(elements)

Returns the Ray Transfer (ABCD) matrix associated with an optical system described by a collection (e.g. a vector or iteration) of optical elements.