11 #ifndef CARMA_SERVICES_SELFCAL_H
12 #define CARMA_SERVICES_SELFCAL_H
95 void setEps(
double epsi1 = 1.0e-8,
double epsi2 = 1.0e-4);
127 void setVis(
int ant1,
int ant2,
const Complex& vis,
double weight=1);
142 std::vector<Complex>
getVis(
bool useAmp =
true);
220 void visset(Vis &data,
const Complex &v,
const Complex &m,
double w,
int a1,
int a2);
221 int guess_nants(
int Nbaselines);
222 std::vector<Complex> phasol(
const std::vector<Vis> &data);
223 std::vector<Complex> amphasol(
const std::vector<Vis> &data);
224 void computeRMS(
const std::vector<Complex> &gains);
233 std::string sourceName_;
247 std::vector<int> antIndex_;
253 std::vector<Vis> data_;
259 std::vector<Complex> Verrors_;
263 bool solutionFailed_;
std::complex< double > Complex
convenient definition of a complex number.
std::vector< Complex > getVis(bool useAmp=true)
Return antenna based visibilities (gains really) The returned array will have a length that contains ...
void setPointSourceModel(double flux)
set the flux of a point source model
double getRMSPhase(void) const
get phase RMS error of the current solution
double getRMSAmp(void) const
get amplitude RMS error of the current solution
std::vector< Complex > getVisErrors(void)
Return visibility errors for all inputs.
Computes an amplitude or phase selfcal solution on a set of visibilities.
double getMaxAnt(void) const
get the maximum numbers of antennae.
void setMaxAnt(int maxAnt=0)
set the maximum number of antennae.
void setReferenceAntenna(int refAnt=0)
set the reference antenna.
double getRefAnt(void) const
get the reference antenna.
void setPlanetDiskModel(double flux, double bmaj=0, double bmin=0, double bpa=0)
set the flux and size of a (uniform disk) planet.
void setVis(int ant1, int ant2, const Complex &vis, double weight=1)
accumulate visibilities.
void zero(void)
reset the accumulators for a new solution
void setMaxIter(int maxIter=100)
set the maximum number of iterations.
double getIter(void) const
get the number of iterations it took to get a solution
void setDebug(int debug=0)
set a debug level (0=nothing, 1=a bit, 2=more)
void setEps(double epsi1=1.0e-8, double epsi2=1.0e-4)
set the relative accuracy levels that need to be achieved in the jacobi iteration.
void setSourceName(std::string &sourceName)
set sourcename