Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members

Arroyo::zernike Class Reference

#include <zernike.h>

Inheritance diagram for Arroyo::zernike:

Arroyo::AO_sim_base Arroyo::modal_expansion Arroyo::pixel_array< double > List of all members.

Public Member Functions

 zernike ()
 zernike (long order)
 ~zernike ()
 zernike (const zernike &iznke)
 zernike (const char *filename)
 zernike (const iofits &iof)
 zernike (const Arroyo::pixel_array< double > &pixarr, double pixscale, long order, const circular_aperture &circ_ap)
zernikeoperator= (const Arroyo::pixel_array< double > &pixarr)
zernikeoperator= (const zernike &znke)
void read (const char *filename)
void read (const Arroyo::iofits &iof)
void write (const char *filename) const
void write (Arroyo::iofits &iof) const
double get_cos_coeff (int order, int level) const
void set_cos_coeff (int order, int level, double coeff)
double get_sin_coeff (int order, int level) const
void set_sin_coeff (int order, int level, double coeff)
void print (std::ostream &os, const char *prefix="") const
long get_order () const
Arroyo::pixel_array< double > get_pixel_array (const std::vector< long > &axes, double pixscale, const circular_aperture &circ_ap) const

Detailed Description

A class to hold zernike polynomial coefficients. The polynomials used for this class are those of Born & Wolf - section 9.2.1 equations 5 and 10. This class uses the real polynomial expansion in which radial polynomials are multiplied by cos(m*phi) and sin(m*phi). For each order n of the expansion, there are n/2+1 possible levels m, given by m = n%2, n%2+2, ... n for both cos and sin terms. However, for m==0 there is no sin term.

Coefficients are stored in the one dimensional pixel_array inherited by this class.


Constructor & Destructor Documentation

Arroyo::zernike::zernike  ) 
 

Null constructor

Arroyo::zernike::zernike long  order  )  [inline]
 

Construct a null instance sized to hold order orders of zernike polynomials.

Arroyo::zernike::~zernike  )  [inline]
 

Destructor

Arroyo::zernike::zernike const zernike iznke  )  [inline]
 

Copy constructor

Arroyo::zernike::zernike const char *  filename  )  [inline]
 

Construct from file

Arroyo::zernike::zernike const iofits iof  )  [inline]
 

Construct from an iofits object

Arroyo::zernike::zernike const Arroyo::pixel_array< double > &  pixarr,
double  pixscale,
long  order,
const circular_aperture circ_ap
 

Construct from a pixel array by expanding the pixel array up to the given order. The pixel array is assumed to be bound by the circular aperture circ_ap, with pixscale specifying the pixel scale.

Currently, pixels on the edge whose centers are outside the aperture are not included in the expansion, regardless of whether circ_ap has its areal_weighting flag set


Member Function Documentation

double Arroyo::zernike::get_cos_coeff int  order,
int  level
const
 

Function to get a coefficient of particular order and level to cos zernike

long Arroyo::zernike::get_order  )  const
 

Function to return the largest radial order in the expansion.

If there are no terms in the expansion, this function returns -1

Arroyo::pixel_array<double> Arroyo::zernike::get_pixel_array const std::vector< long > &  axes,
double  pixscale,
const circular_aperture circ_ap
const
 

Returns a pixel_array with the given axes and pixel scale, defined by the circular aperture circ_ap.

If circ_ap has its areal_weighting flag set, then this function will take into account pixels that lie on the boundary but whose centers lie outside the aperture. In these cases the phase will be set to the value given by the expansion.

double Arroyo::zernike::get_sin_coeff int  order,
int  level
const
 

Function to get a coefficient of particular order and level to sin zernike

zernike& Arroyo::zernike::operator= const zernike znke  ) 
 

Operator =

zernike& Arroyo::zernike::operator= const Arroyo::pixel_array< double > &  pixarr  )  [inline]
 

Operator =

Forced to do this because compiler cannot seem to find this function itself.

void Arroyo::zernike::print std::ostream &  os,
const char *  prefix = ""
const [virtual]
 

Function to print the coefficients

Implements Arroyo::modal_expansion.

void Arroyo::zernike::read const Arroyo::iofits iof  )  [virtual]
 

read from an iofits object

Implements Arroyo::modal_expansion.

void Arroyo::zernike::read const char *  filename  )  [virtual]
 

read from a file

Implements Arroyo::modal_expansion.

void Arroyo::zernike::set_cos_coeff int  order,
int  level,
double  coeff
 

Function to set a coefficient of particular order and level to cos zernike

void Arroyo::zernike::set_sin_coeff int  order,
int  level,
double  coeff
 

Function to set a coefficient of particular order and level to sin zernike

void Arroyo::zernike::write Arroyo::iofits iof  )  const [virtual]
 

write to an iofits object

Implements Arroyo::modal_expansion.

void Arroyo::zernike::write const char *  filename  )  const [virtual]
 

write to a file

Implements Arroyo::modal_expansion.


The documentation for this class was generated from the following file:
Generated on Thu Nov 29 17:16:38 2007 for arroyo by  doxygen 1.3.9.1