casa  $Rev:20696$
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines
Public Member Functions | Static Public Member Functions | Static Public Attributes
casa::GaussianSpectralElement Class Reference

Describes a Gaussian spectral line. More...

#include <GaussianSpectralElement.h>

Inheritance diagram for casa::GaussianSpectralElement:
casa::PCFSpectralElement casa::SpectralElement

List of all members.

Public Member Functions

 GaussianSpectralElement ()
 Default constructor creates a default Gaussian element with an amplitude of 1; an integral (sigma=2sqrt(ln2)/pi) of 1; a central frequency of zero.
 GaussianSpectralElement (const Double ampl, const Double center, const Double sigma)
 Construct with given type and values.
 GaussianSpectralElement (const Vector< Double > &param)
 Construct the given tp with the given param.
 GaussianSpectralElement (const GaussianSpectralElement &other)
 Copy constructor (deep copy)
 ~GaussianSpectralElement ()
 Destructor.
SpectralElementclone () const
GaussianSpectralElementoperator= (const GaussianSpectralElement &other)
 Assignment (copy semantics)
Double operator() (const Double x) const
 Evaluate the value of the element at x.
Double getSigma () const
Double getFWHM () const
 Get the width.
Double getSigmaErr () const
Double getFWHMErr () const
 Get the width error estimate.
void setSigma (Double sigma)
void setFWHM (Double fwhm)
void fixSigma (const Bool fix=True)
Bool fixedSigma () const
Double getIntegral () const
 get the integral from -inf to inf
Bool toRecord (RecordInterface &out) const
 Save to a record.

Static Public Member Functions

static Double sigmaFromFWHM (const Double fwhm)
 Sigma to FWHM Convert from sigma to FWHM and vice versa.
static Double sigmaToFWHM (const Double sigma)

Static Public Attributes

static const Double SigmaToFWHM
 Sigma to FWHM conversion factor.

Detailed Description

Describes a Gaussian spectral line.

Intended use:

Public interface

Review Status

Date Reviewed:
yyyy/mm/dd
Test programs:
tSpectralFit

Prerequisite

Etymology

From Gaussian and spectral line and element

Synopsis

The GaussianSpectralElement class describes a Gaussian spectral line.

Example

Motivation

To have a container for data descrbing a Gaussian spectral profile for fitting to an observed spectrum

Definition at line 64 of file GaussianSpectralElement.h.


Constructor & Destructor Documentation

Default constructor creates a default Gaussian element with an amplitude of 1; an integral (sigma=2sqrt(ln2)/pi) of 1; a central frequency of zero.

casa::GaussianSpectralElement::GaussianSpectralElement ( const Double  ampl,
const Double  center,
const Double  sigma 
)

Construct with given type and values.

Thrown Exceptions

Construct the given tp with the given param.

Thrown Exceptions

  • AipsError if incorrect number of parameters (e.g. not 3 for GAUSSIAN)
  • AipsError if sigma == 0.0

Copy constructor (deep copy)

Thrown Exceptions

Destructor.


Member Function Documentation

Implements casa::SpectralElement.

Get the width.

Reimplemented from casa::PCFSpectralElement.

Get the width error estimate.

Reimplemented from casa::PCFSpectralElement.

get the integral from -inf to inf

Implements casa::PCFSpectralElement.

Double casa::GaussianSpectralElement::operator() ( const Double  x) const [virtual]

Evaluate the value of the element at x.

Implements casa::SpectralElement.

GaussianSpectralElement& casa::GaussianSpectralElement::operator= ( const GaussianSpectralElement other)

Assignment (copy semantics)

Thrown Exceptions

Reimplemented from casa::PCFSpectralElement.

Sigma to FWHM Convert from sigma to FWHM and vice versa.

static Double casa::GaussianSpectralElement::sigmaToFWHM ( const Double  sigma) [static]

Save to a record.

For Gaussian elements, the width is defined as a FWHM in the record interface.

Reimplemented from casa::SpectralElement.


Member Data Documentation

Sigma to FWHM conversion factor.

Definition at line 69 of file GaussianSpectralElement.h.


The documentation for this class was generated from the following file: