mxlib
c++ tools for analyzing astronomical data and other tasks by Jared R. Males. [git repo]
Loading...
Searching...
No Matches

Working with the Zernike polynomials. More...

Working with the Zernike polynomials.

Author
Jared R. Males (jared.nosp@m.male.nosp@m.s@gma.nosp@m.il.c.nosp@m.om)
Todo
the basic zernike polys should be in math::func.

Definition in file zernike.hpp.

#include <cmath>
#include <complex>
#include <vector>
#include "../mxlib.hpp"
#include "../math/func/bessel.hpp"
#include "../math/func/jinc.hpp"
#include "../math/func/factorial.hpp"
#include "../math/func/sign.hpp"
#include "../math/constants.hpp"

Go to the source code of this file.

Namespaces

namespace  mx
 The mxlib c++ namespace.

Functions

int mx::sigproc::noll_nm (int &n, int &m, int j)
 Get the Zernike coefficients n,m corrresponding the Noll index j.
int mx::sigproc::noll_j (unsigned n, int m)
 Get the Noll index j corresponding to Zernike coefficients n,m.
int mx::sigproc::nZernRadOrd (unsigned n)
 Get the number of Zernikes up to and including a radial order.
template<typename realT>
int mx::sigproc::zernikeRCoeffs (std::vector< realT > &c, int n, int m)
 Calculate the coefficients of a Zernike radial polynomial.
template<typename realT, typename calcRealT>
realT mx::sigproc::zernikeR (realT rho, int n, int m, std::vector< calcRealT > &c)
 Calculate the value of a Zernike radial polynomial at a given separation.
template<typename realT, typename calcRealT>
realT mx::sigproc::zernikeR (realT rho, int n, int m)
 Calculate the value of a Zernike radial polynomial at a given separation.
template<typename realT, typename calcRealT>
realT mx::sigproc::zernike (realT rho, realT phi, int n, int m, std::vector< calcRealT > &c)
 Calculate the value of a Zernike radial polynomial at a given radius and angle.
template<typename realT, typename calcRealT>
realT mx::sigproc::zernike (realT rho, realT phi, int n, int m)
 Calculate the value of a Zernike radial polynomial at a given radius and angle.
template<typename realT, typename calcRealT>
realT mx::sigproc::zernike (realT rho, realT phi, int j)
 Calculate the value of a Zernike radial polynomial at a given radius and angle.
template<typename arrayT, typename calcRealT, int overscan = 2>
int mx::sigproc::zernike (arrayT &arr, int n, int m, typename arrayT::Scalar xcen, typename arrayT::Scalar ycen, typename arrayT::Scalar rad=-1)
 Fill in an Eigen-like array with a Zernike polynomial.
template<typename arrayT, typename calcRealT>
int mx::sigproc::zernike (arrayT &arr, int j, typename arrayT::Scalar xcen, typename arrayT::Scalar ycen, typename arrayT::Scalar rad=-1)
 Fill in an Eigen-like array with a Zernike polynomial.
template<typename arrayT, typename calcRealT>
int mx::sigproc::zernike (arrayT &arr, int n, int m, typename arrayT::Scalar rad=-1)
 Fill in an Eigen-like array with a Zernike polynomial.
template<typename arrayT, typename calcRealT>
int mx::sigproc::zernike (arrayT &arr, int j, typename arrayT::Scalar rad=-1)
 Fill in an Eigen-like array with a Zernike polynomial.
template<typename cubeT, typename calcRealT>
int mx::sigproc::zernikeBasis (cubeT &cube, typename cubeT::Scalar rad=-1, int minj=2)
 Fill in an Eigencube-like array with Zernike polynomials in Noll order.
template<typename realT>
std::complex< realT > mx::sigproc::zernikeQ (realT k, realT phi, int n, int m)
 Calculate the square-normed Fourier transform of a Zernike polynomial at position (k,phi).
template<typename realT>
realT mx::sigproc::zernikeQNorm (realT k, realT phi, int n, int m)
 Calculate the square-normed Fourier transform of a Zernike polynomial at position (k,phi).
template<typename realT>
realT mx::sigproc::zernikeQNorm (realT k, realT phi, int j)
 Calculate the square-normed Fourier transform of a Zernike polynomial at position (k,phi).
template<typename arrayT>
int mx::sigproc::zernikeQNorm (arrayT &arr, arrayT &k, arrayT &phi, int j)
 Fill in an Eigen-like array with the square-normed Fourier transform of a Zernike polynomial.
template<typename realT>
realT mx::sigproc::zernikePPiston (const realT &kD)
 Calculate the spatial power spectrum of Piston.
template<typename realT>
realT mx::sigproc::zernikePTipTilt (const realT &kD)
 Calculate the spatial power spectrum of Tip & Tilt.
template<typename realT>
realT mx::sigproc::zernikePDefocus (const realT &kD)
 Calculate the spatial power spectrum of Defocus.
template<typename realT>
realT mx::sigproc::zernikePAstig (const realT &kD)
 Calculate the spatial power spectrum of Astigmatism.
template<typename realT>
realT mx::sigproc::zernikePComa (const realT &kD)
 Calculate the spatial power spectrum of Coma.
template<typename realT>
realT mx::sigproc::zernikePTrefoil (const realT &kD)
 Calculate the spatial power spectrum of Trefoil.
template<typename realT>
realT mx::sigproc::zernikeModeDOCKolmogorov (unsigned noll_j)
 Get the degrees of correction coefficient for Zernike polynomials in Kolmogorov turbulence.
template<typename realT>
realT mx::sigproc::zernikeModeDOCKolmogorov (unsigned noll_j, realT D, realT r_0)
 Get the degrees of correction for Zernike polynomials in Kolmogorov turbulence.
template<typename realT>
realT mx::sigproc::zernikeModeDOCDiffKolmogorov (unsigned noll_j)
 Get the difference in degrees of correction coefficient for Zernike polynomials in Kolmogorov turbulence.
template<typename realT>
realT mx::sigproc::zernikeModeDOCDiffKolmogorov (unsigned noll_j, realT D, realT r_0)
 Get the variance for a single Zernike polynomial in Kolmogorov turbulence.