Source
//#pragma omp parallel default(none) firstprivate(Er, El, nx, ny, localWhichPoln) private(i,j) shared(ap, a, p, L0) num_threads(Nth)
//# BeamCalc.cc: Implementation for BeamCalc
//# Copyright (C) 1996,1997,1998,1999,2000,2002
//# Associated Universities, Inc. Washington DC, USA.
//#
//# This library is free software; you can redistribute it and/or modify it
//# under the terms of the GNU Library General Public License as published by
//# the Free Software Foundation; either version 2 of the License, or (at your
//# option) any later version.
//#
//# This library is distributed in the hope that it will be useful, but WITHOUT
//# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
//# FITNESS FOR A PARTICULAR PURPOSE. See the GNU Library General Public
//# License for more details.
//#
//# You should have received a copy of the GNU Library General Public License
//# along with this library; if not, write to the Free Software Foundation,
//# Inc., 675 Massachusetts Ave, Cambridge, MA 02139, USA.
//#
//# Correspondence concerning AIPS++ should be adressed as follows:
//# Internet email: aips2-request@nrao.edu.
//# Postal address: AIPS++ Project Office
//# National Radio Astronomy Observatory
//# 520 Edgemont Road
//# Charlottesville, VA 22903-2475 USA
//#
//#
//# $Id$
//#include <stdio.h>
//#include <complex.h>
//#include <stdlib.h>
//#include <string.h>
using namespace std;
using namespace casacore;
namespace casa{
const Double BeamCalc::METER_INCH = 39.37008;
const Double BeamCalc::INCH_METER = (1.0/BeamCalc::METER_INCH);
const Double BeamCalc::NS_METER = 0.299792458; // Exact
const Double BeamCalc::METER_NS = (1.0/BeamCalc::NS_METER);
const Double BeamCalc::DEG_RAD = M_PI/180.0;
const Double BeamCalc::RAD_DEG = 180.0/M_PI;
BeamCalc* BeamCalc::instance_p = 0;
BeamCalc::BeamCalc():
obsName_p(""),
antType_p(""),
obsTime_p(),
BeamCalc_NumBandCodes_p(0),
BeamCalcGeometries_p(0),
bandMinFreq_p(0),
bandMaxFreq_p(0),
antRespPath_p(""){
}
BeamCalc* BeamCalc::Instance(){
if(instance_p==0){
instance_p = new BeamCalc();
}
return instance_p;
}
// initialise the beam calculation parameters
void BeamCalc::setBeamCalcGeometries(const String& obsName,
const String& antType,
const MEpoch& obsTime,
const String& otherAntRayPath){