PolarizedTypes
Documentation for PolarizedTypes.
PolarizedTypes.CirBasis
PolarizedTypes.CoherencyMatrix
PolarizedTypes.CoherencyMatrix
PolarizedTypes.CoherencyMatrix
PolarizedTypes.CoherencyMatrix
PolarizedTypes.CoherencyMatrix
PolarizedTypes.ElectricFieldBasis
PolarizedTypes.LPol
PolarizedTypes.LinBasis
PolarizedTypes.PolBasis
PolarizedTypes.RPol
PolarizedTypes.StokesParams
PolarizedTypes.XPol
PolarizedTypes.YPol
PolarizedTypes.basis_components
PolarizedTypes.basis_transform
PolarizedTypes.evpa
PolarizedTypes.fracpolarization
PolarizedTypes.innerprod
PolarizedTypes.linearpol
PolarizedTypes.mbreve
PolarizedTypes.mpol
PolarizedTypes.m̆
PolarizedTypes.polarization
PolarizedTypes.polellipse
PolarizedTypes.CirBasis
— TypeCirBasis <: PolBasis
Measurement uses the circular polarization basis, which is typically used for circular feed interferometers.
PolarizedTypes.CoherencyMatrix
— TypeCoherencyMatrix(s::StokesParams, basis1::PolBasis)
+Home · PolarizedTypes.jl PolarizedTypes
Documentation for PolarizedTypes.
PolarizedTypes.CirBasis
PolarizedTypes.CoherencyMatrix
PolarizedTypes.CoherencyMatrix
PolarizedTypes.CoherencyMatrix
PolarizedTypes.CoherencyMatrix
PolarizedTypes.CoherencyMatrix
PolarizedTypes.ElectricFieldBasis
PolarizedTypes.LPol
PolarizedTypes.LinBasis
PolarizedTypes.PolBasis
PolarizedTypes.RPol
PolarizedTypes.StokesParams
PolarizedTypes.XPol
PolarizedTypes.YPol
PolarizedTypes.basis_components
PolarizedTypes.basis_transform
PolarizedTypes.evpa
PolarizedTypes.fracpolarization
PolarizedTypes.innerprod
PolarizedTypes.linearpol
PolarizedTypes.mbreve
PolarizedTypes.mpol
PolarizedTypes.m̆
PolarizedTypes.polarization
PolarizedTypes.polellipse
PolarizedTypes.CirBasis
— TypeCirBasis <: PolBasis
Measurement uses the circular polarization basis, which is typically used for circular feed interferometers.
sourcePolarizedTypes.CoherencyMatrix
— TypeCoherencyMatrix(s::StokesParams, basis1::PolBasis)
CoherencyMatrix(s::StokesParams, basis1::PolBasis, basis2::PolBasis)
CoherencyMatrix(s::StokesParams, basis1::PolBasis, basis2::PolBasis, refbasis=CirBasis())
Constructs the coherency matrix from the set of stokes parameters s
. This is specialized on basis1
and basis2
which form the tensor product basis |basis1><basis2|
, or if a single basis is given then by |basis><basis|
.
For example
CoherencyMatrix(s, CircBasis())
will give the coherency matrix
I+V Q+iU
Q-iU I-V
while
CoherencyMatrix(s, LinBasis())
will give
I+Q U+iV
- U-iV I-Q
Notes
Internally this function first converts to a reference basis and then the final basis. You can select the reference basis used with the optional argument refbasis. By default we use the circular basis as our reference. Note that this is only important for mixed bases, e.g., if basis1
and basis2
are different. If basis1==basis2
then the reference basis is never used.
sourcePolarizedTypes.CoherencyMatrix
— Typestruct CoherencyMatrix{B1, B2, T} <: StaticArraysCore.FieldMatrix{2, 2, T}
Coherency matrix for a single baseline with bases B1
and B2
. The two bases correspond to the type of feeds used for each telescope and should be subtypes of PolBasis
. To see which bases are implemented type subtypes(Rimes.PolBasis)
in the REPL.
For a circular basis the layout of the coherency matrix is
RR* RL*
+ U-iV I-Q
Notes
Internally this function first converts to a reference basis and then the final basis. You can select the reference basis used with the optional argument refbasis. By default we use the circular basis as our reference. Note that this is only important for mixed bases, e.g., if basis1
and basis2
are different. If basis1==basis2
then the reference basis is never used.
sourcePolarizedTypes.CoherencyMatrix
— Typestruct CoherencyMatrix{B1, B2, T} <: StaticArraysCore.FieldMatrix{2, 2, T}
Coherency matrix for a single baseline with bases B1
and B2
. The two bases correspond to the type of feeds used for each telescope and should be subtypes of PolBasis
. To see which bases are implemented type subtypes(Rimes.PolBasis)
in the REPL.
For a circular basis the layout of the coherency matrix is
RR* RL*
LR* RR*
which can be constructed using
c = CoherencyMatrix(RR, LR, RL, LL, CirBasis())
For a linear basis the layout of the coherency matrix is
XX* XY*
YX* YY*
which can be constructed using
c = CoherencyMatrix(XX, YX, XY, YY, CirBasis())
For a mixed (e.g., circular and linear basis) the layout of the coherency matrix is
RX* RY*
LX* LY*
or e.g., linear and circular the layout of the coherency matrix is
XR* XL*
YR* YL*
These coherency matrices can be constructed using:
# Circular and linear feeds i.e., |R><X|
c = CoherencyMatrix(RX, LX, RY, LY, LinBasis(), CirBasis())
# Linear and circular feeds i.e., |X><R|
-c = CoherencyMatrix(XR, YR, XL, YL, LinBasis(), CirBasis())
sourcePolarizedTypes.CoherencyMatrix
— MethodCoherencyMatrix(e11, e21, e12, e22, basis1::PolBasis basis2::PolBasis)
Constructs the coherency matrix with components e11 e12 e21 e22 relative to the tensor product basis, basis
given by |basis1><basis2|
.
For instance
c = Coherency(1.0, 0.0, 0.0, 1.0, CirBasis(), LinBasis())
elements correspond to RX* RY* LX* LY*
sourcePolarizedTypes.CoherencyMatrix
— MethodCoherencyMatrix(e11, e21, e12, e22, basis::PolBasis)
Constructs the coherency matrix with components e11 e12 e21 e22 relative to the tensor product basis, basis
given by |basis><basis|
.
For instance
c = Coherency(1.0, 0.0, 0.0, 1.0, CirBasis())
elements correspond to RR* RL* LR* LL*
sourcePolarizedTypes.CoherencyMatrix
— MethodCoherencyMatrix(e11, e21, e12, e22, basis::NTuple{2, PolBasis})
Constructs the coherency matrix with components e11 e12 e21 e22 relative to the tensor product basis, |basis[1]><basis[2]|
. Note that basis[1] and basis[2] could be different.
For instance
c = Coherency(1.0, 0.0, 0.0, 1.0, CirBasis(), LinBasis())
elements correspond to RX* RY* LX* LY*
sourcePolarizedTypes.ElectricFieldBasis
— Typeabstract type ElectricFieldBasis
An abstract type whose subtypes denote a specific electric field basis.
sourcePolarizedTypes.LPol
— Typestruct LPol <: PolarizedTypes.ElectricFieldBasis
The left circular electric field basis, i.e. a left-handed circular feed.
sourcePolarizedTypes.LinBasis
— TypeLinBasis <: PolBasis
Measurement uses the linear polarization basis, which is typically used for linear feed interferometers.
sourcePolarizedTypes.PolBasis
— Typestruct PolBasis{B1<:Union{Missing, PolarizedTypes.ElectricFieldBasis}, B2<:Union{Missing, PolarizedTypes.ElectricFieldBasis}}
Denotes a general polarization basis, with basis vectors (B1,B2) which are typically <: Union{ElectricFieldBasis, Missing}
sourcePolarizedTypes.RPol
— Typestruct RPol <: PolarizedTypes.ElectricFieldBasis
The right circular electric field basis, i.e. a right-handed circular feed.
sourcePolarizedTypes.StokesParams
— Typestruct StokesParams{T} <: StaticArraysCore.FieldVector{4, T}
Static vector that holds the stokes parameters of a polarized complex visibility
To convert between a StokesParams
and CoherencyMatrix
use the convert
function
convert(::CoherencyMatrix, StokesVector(1.0, 0.1, 0.1, 0.4))
sourcePolarizedTypes.XPol
— Typestruct XPol <: PolarizedTypes.ElectricFieldBasis
The horizontal or X electric feed basis, i.e. the horizontal linear feed.
sourcePolarizedTypes.YPol
— Typestruct YPol <: PolarizedTypes.ElectricFieldBasis
The vertical or Y electric feed basis, i.e. the vertical linear feed.
sourcePolarizedTypes.basis_components
— Functionbasis_components([T=Float64,], e::ElectricFieldBasis, b::PolBasis)
Returns a static vector that contains the components of the electric field basis vector e
in terms of the polarization basis b
. The first argument is optionally the eltype of the static vector.
Examples
julia> basis_components(Float64, R(), PolBasis{XPol,Y}())
+c = CoherencyMatrix(XR, YR, XL, YL, LinBasis(), CirBasis())
sourcePolarizedTypes.CoherencyMatrix
— MethodCoherencyMatrix(e11, e21, e12, e22, basis1::PolBasis basis2::PolBasis)
Constructs the coherency matrix with components e11 e12 e21 e22 relative to the tensor product basis, basis
given by |basis1><basis2|
.
For instance
c = Coherency(1.0, 0.0, 0.0, 1.0, CirBasis(), LinBasis())
elements correspond to RX* RY* LX* LY*
sourcePolarizedTypes.CoherencyMatrix
— MethodCoherencyMatrix(e11, e21, e12, e22, basis::PolBasis)
Constructs the coherency matrix with components e11 e12 e21 e22 relative to the tensor product basis, basis
given by |basis><basis|
.
For instance
c = Coherency(1.0, 0.0, 0.0, 1.0, CirBasis())
elements correspond to RR* RL* LR* LL*
sourcePolarizedTypes.CoherencyMatrix
— MethodCoherencyMatrix(e11, e21, e12, e22, basis::NTuple{2, PolBasis})
Constructs the coherency matrix with components e11 e12 e21 e22 relative to the tensor product basis, |basis[1]><basis[2]|
. Note that basis[1] and basis[2] could be different.
For instance
c = Coherency(1.0, 0.0, 0.0, 1.0, CirBasis(), LinBasis())
elements correspond to RX* RY* LX* LY*
sourcePolarizedTypes.ElectricFieldBasis
— Typeabstract type ElectricFieldBasis
An abstract type whose subtypes denote a specific electric field basis.
sourcePolarizedTypes.LPol
— Typestruct LPol <: PolarizedTypes.ElectricFieldBasis
The left circular electric field basis, i.e. a left-handed circular feed.
sourcePolarizedTypes.LinBasis
— TypeLinBasis <: PolBasis
Measurement uses the linear polarization basis, which is typically used for linear feed interferometers.
sourcePolarizedTypes.PolBasis
— Typestruct PolBasis{B1<:Union{Missing, PolarizedTypes.ElectricFieldBasis}, B2<:Union{Missing, PolarizedTypes.ElectricFieldBasis}}
Denotes a general polarization basis, with basis vectors (B1,B2) which are typically <: Union{ElectricFieldBasis, Missing}
sourcePolarizedTypes.RPol
— Typestruct RPol <: PolarizedTypes.ElectricFieldBasis
The right circular electric field basis, i.e. a right-handed circular feed.
sourcePolarizedTypes.StokesParams
— Typestruct StokesParams{T} <: StaticArraysCore.FieldVector{4, T}
Static vector that holds the stokes parameters of a polarized complex visibility
To convert between a StokesParams
and CoherencyMatrix
use the convert
function
convert(::CoherencyMatrix, StokesVector(1.0, 0.1, 0.1, 0.4))
sourcePolarizedTypes.XPol
— Typestruct XPol <: PolarizedTypes.ElectricFieldBasis
The horizontal or X electric feed basis, i.e. the horizontal linear feed.
sourcePolarizedTypes.YPol
— Typestruct YPol <: PolarizedTypes.ElectricFieldBasis
The vertical or Y electric feed basis, i.e. the vertical linear feed.
sourcePolarizedTypes.basis_components
— Functionbasis_components([T=Float64,], e::ElectricFieldBasis, b::PolBasis)
Returns a static vector that contains the components of the electric field basis vector e
in terms of the polarization basis b
. The first argument is optionally the eltype of the static vector.
Examples
julia> basis_components(Float64, R(), PolBasis{XPol,Y}())
2-element StaticArraysCore.SVector{2, ComplexF64} with indices SOneTo(2):
0.7071067811865475 + 0.0im
0.0 - 0.7071067811865475im
@@ -24,14 +24,14 @@
julia> basis_components(Float64, X(), PolBasis{XPol,Y}())
2-element StaticArraysCore.SVector{2, ComplexF64} with indices SOneTo(2):
1.0 + 0.0im
- 0.0 + 0.0im
sourcePolarizedTypes.basis_transform
— Functionbasis_transform([T=Float64,], b1::PolBasis, b2::PolBasis)
+ 0.0 + 0.0im
sourcePolarizedTypes.basis_transform
— Functionbasis_transform([T=Float64,], b1::PolBasis, b2::PolBasis)
basis_transform([T=Float64,], b1::PolBasis=>b2::PolBasis)
Produces the transformation matrix that transforms the vector components from basis b1
to basis b2
. This means that if for example E
is the circular basis then basis_transform(CirBasis=>LinBasis)E
is in the linear basis. In other words the columns of the transformation matrix are the coordinate vectors of the new basis vectors in the old basis.
Example
julia> basis_transform(CirBasis()=>LinBasis())
2×2 StaticArraysCore.SMatrix{2, 2, ComplexF64, 4} with indices SOneTo(2)×SOneTo(2):
0.707107-0.0im 0.707107-0.0im
- 0.0-0.707107im 0.0+0.707107im
sourcePolarizedTypes.evpa
— Methodevpa(m::Union{StokesParams, CoherencyMatrix})
Compute the evpa of a stokes vect or cohereny matrix.
sourcePolarizedTypes.fracpolarization
— Methodfracpolarization(s)
-
Returns the (Q/I, U/I, V/I) fractional polarization vector as a 3-element static vector.
sourcePolarizedTypes.innerprod
— Functioninnerprod(::Type{T}, XPol(), YPol())
Computes the complex inner product of two elements of a complex Hilbert space X
and Y
where base element of the output is T.
sourcePolarizedTypes.linearpol
— Methodlinearpol(s)
-
Computes linearpol
from a set of stokes parameters s
.
sourcePolarizedTypes.mbreve
— Methodmbreve(m)
-
Computes the complex fractional linear polarization of the complex or visibility quantities. Note that this function can also be called used m̆
sourcePolarizedTypes.mpol
— Methodmpol(m::StokesParameters{<:Real})
Compute the complex fractional linear polarization of a Stokes Parameter m
sourcePolarizedTypes.m̆
— Methodm̆(m::Union{StokesParameters{<:Complex}, CoherencyMatrix)
Computes the complex fractional linear polarization of the complex or visibility quantities. Note that this function can also be called used mbreve
sourcePolarizedTypes.polarization
— Methodpolarization(s)
-
Returns the (Q, U, V) polarization vector as a 3-element static vector.
sourcePolarizedTypes.polellipse
— Methodpolellipse(s)
+ 0.0-0.707107im 0.0+0.707107im
sourcePolarizedTypes.evpa
— Methodevpa(m::Union{StokesParams, CoherencyMatrix})
Compute the evpa of a stokes vect or cohereny matrix.
sourcePolarizedTypes.fracpolarization
— Methodfracpolarization(s)
+
Returns the (Q/I, U/I, V/I) fractional polarization vector as a 3-element static vector.
sourcePolarizedTypes.innerprod
— Functioninnerprod(::Type{T}, XPol(), YPol())
Computes the complex inner product of two elements of a complex Hilbert space X
and Y
where base element of the output is T.
sourcePolarizedTypes.linearpol
— Methodlinearpol(s)
+
Computes linearpol
from a set of stokes parameters s
.
sourcePolarizedTypes.mbreve
— Methodmbreve(m)
+
Computes the complex fractional linear polarization of the complex or visibility quantities. Note that this function can also be called used m̆
sourcePolarizedTypes.mpol
— Methodmpol(m::StokesParameters{<:Real})
Compute the complex fractional linear polarization of a Stokes Parameter m
sourcePolarizedTypes.m̆
— Methodm̆(m::Union{StokesParameters{<:Complex}, CoherencyMatrix)
Computes the complex fractional linear polarization of the complex or visibility quantities. Note that this function can also be called used mbreve
sourcePolarizedTypes.polarization
— Methodpolarization(s)
+
Returns the (Q, U, V) polarization vector as a 3-element static vector.
sourcePolarizedTypes.polellipse
— Methodpolellipse(s)
Returns the polarization ellipse of the Stokes parameters s
. The results is a named tuple with elements
a
: The semi-major axis of the polarization ellipseb
: The semi-minor axis of the polarization ellipseevpa
: The electric vector position angle of s
or the PA of the ellipse.sn
: The sign of the Stokes V
.
Notes
The semi-major and semi-minor axes are defined as
a = 1/2(Iₚ + |L|)
- b = 1/2(Iₚ - |L|)
where Iₚ = √(Q² + U² + V²)
and |L| = √(Q² + U²)
.
In general the area of the ellipse is given by
πab = π/4|V|²
For sources with zero linear polarization a = b
so we have a circle with radius |V|
. For purely linear polarization b = 0
giving a line with length |L|
.
sourceSettings
This document was generated with Documenter.jl version 0.27.24 on Wednesday 23 August 2023. Using Julia version 1.9.2.
+ b = 1/2(Iₚ - |L|)
where Iₚ = √(Q² + U² + V²)
and |L| = √(Q² + U²)
.
In general the area of the ellipse is given by
πab = π/4|V|²
For sources with zero linear polarization a = b
so we have a circle with radius |V|
. For purely linear polarization b = 0
giving a line with length |L|
.