Line data Source code
1 : // -*- C++ -*- 2 : //# EVLAConvFunc.h: Definition of the EVLAConvFunc class 3 : //# Copyright (C) 1997,1998,1999,2000,2001,2002,2003 4 : //# Associated Universities, Inc. Washington DC, USA. 5 : //# 6 : //# This library is free software; you can redistribute it and/or modify it 7 : //# under the terms of the GNU Library General Public License as published by 8 : //# the Free Software Foundation; either version 2 of the License, or (at your 9 : //# option) any later version. 10 : //# 11 : //# This library is distributed in the hope that it will be useful, but WITHOUT 12 : //# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 13 : //# FITNESS FOR A PARTICULAR PURPOSE. See the GNU Library General Public 14 : //# License for more details. 15 : //# 16 : //# You should have received a copy of the GNU Library General Public License 17 : //# along with this library; if not, write to the Free Software Foundation, 18 : //# Inc., 675 Massachusetts Ave, Cambridge, MA 02139, USA. 19 : //# 20 : //# Correspondence concerning AIPS++ should be addressed as follows: 21 : //# Internet email: aips2-request@nrao.edu. 22 : //# Postal address: AIPS++ Project Office 23 : //# National Radio Astronomy Observatory 24 : //# 520 Edgemont Road 25 : //# Charlottesville, VA 22903-2475 USA 26 : //# 27 : //# $Id$ 28 : // 29 : #ifndef SYNTHESIS_EVLACONVFUNC_H 30 : #define SYNTHESIS_EVLACONVFUNC_H 31 : 32 : #include <casacore/images/Images/ImageInterface.h> 33 : #include <synthesis/TransformMachines/Utils.h> 34 : #include <synthesis/TransformMachines/BeamCalc.h> 35 : #include <synthesis/TransformMachines/CFStore.h> 36 : #include <synthesis/TransformMachines/VLACalcIlluminationConvFunc.h> 37 : //#include <synthesis/MeasurementComponents/IlluminationConvFunc.h> 38 : //#include <synthesis/MeasurementComponents/PixelatedConvFunc.h> 39 : #include <synthesis/TransformMachines/ConvolutionFunction.h> 40 : #include <casacore/coordinates/Coordinates/DirectionCoordinate.h> 41 : #include <casacore/coordinates/Coordinates/SpectralCoordinate.h> 42 : #include <casacore/coordinates/Coordinates/StokesCoordinate.h> 43 : #include <casacore/lattices/LatticeMath/LatticeFFT.h> 44 : #include <casacore/casa/Logging/LogIO.h> 45 : #include <casacore/casa/Logging/LogSink.h> 46 : #include <casacore/casa/Logging/LogOrigin.h> 47 : #include <casacore/casa/Arrays/ArrayFwd.h> 48 : 49 : namespace casacore{ 50 : 51 : template<class T> class ImageInterface; 52 : 53 : } 54 : 55 : namespace casa { //# NAMESPACE CASA - BEGIN 56 : class VisBuffer; 57 : class EVLAConvFunc : public ConvolutionFunction 58 : { 59 : public: 60 : // EVLAConvFunc(const casacore::CountedPtr<IlluminationConvFunc> ATerm): 61 : // ConvolutionFunction(),bandID_p(-1), polMap_p(), feedStokes_p(), ATerm_p(ATerm) 62 : EVLAConvFunc(): 63 : ConvolutionFunction(),bandID_p(-1), polMap_p(), feedStokes_p() 64 : {}; 65 : ~EVLAConvFunc() {}; 66 : EVLAConvFunc& operator=(const EVLAConvFunc& other); 67 : casacore::Int getVLABandID(casacore::Double& freq,casacore::String&telescopeName); 68 : casacore::Bool findSupport(casacore::Array<casacore::Complex>& func, casacore::Float& threshold,casacore::Int& origin, casacore::Int& R); 69 : void makeConvFunction(const casacore::ImageInterface<casacore::Complex>& image, 70 : const VisBuffer& vb, 71 : const casacore::Int wConvSize, 72 : const casacore::Float pa, 73 : const casacore::Float dpa, 74 : CFStore& cfs, 75 : CFStore& cfwts, casacore::Bool fillCF=true); 76 : int getVisParams(const VisBuffer& vb); 77 : casacore::Int makePBPolnCoords(const VisBuffer&vb, 78 : const casacore::Vector<casacore::Int>& polMap, 79 : const casacore::Int& convSize, 80 : const casacore::Int& convSampling, 81 : const casacore::CoordinateSystem& skyCoord, 82 : const casacore::Int& skyNx, const casacore::Int& skyNy, 83 : casacore::CoordinateSystem& feedCoord, 84 : casacore::Vector<casacore::Int>& cfStokes); 85 : // 86 : // Overloading these functions from ConvolutionFunction class 87 : // 88 : void setPolMap(const casacore::Vector<casacore::Int>& polMap); 89 : void setFeedStokes(const casacore::Vector<casacore::Int>& feedStokes); 90 : private: 91 : casacore::Int bandID_p; 92 : casacore::Float Diameter_p, Nant_p, HPBW, sigma; 93 : 94 0 : casacore::LogIO& logIO() {return logIO_p;} 95 : casacore::LogIO logIO_p; 96 : casacore::Vector<casacore::Int> polMap_p; 97 : casacore::Vector<casacore::Int> feedStokes_p; 98 : casacore::CountedPtr<IlluminationConvFunc> ATerm_p; 99 : }; 100 : }; 101 : #endif