LCOV - code coverage report
Current view: top level - synthesis/TransformMachines2 - EVLAAperture.h (source / functions) Hit Total Coverage
Test: casacpp_coverage.info Lines: 0 5 0.0 %
Date: 2024-10-28 15:53:10 Functions: 0 5 0.0 %

          Line data    Source code
       1             : // -*- C++ -*-
       2             : //# EVLAAperture.h: Definition of the EVLAAperture 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: casa-feedback@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_TRANSFORM2_EVLAAPERTURE_H
      30             : #define SYNTHESIS_TRANSFORM2_EVLAAPERTURE_H
      31             : 
      32             : #include <synthesis/TransformMachines2/Utils.h>
      33             : #include <casacore/images/Images/ImageInterface.h>
      34             : #include <synthesis/TransformMachines/BeamCalc.h>
      35             : //#include <synthesis/MeasurementComponents/ATerm.h>
      36             : #include <synthesis/TransformMachines2/AzElAperture.h>
      37             : #include <casacore/coordinates/Coordinates/CoordinateSystem.h>
      38             : #include <casacore/casa/Arrays/ArrayFwd.h>
      39             : //
      40             : //---------------------------------------------------------------------
      41             : //
      42             : 
      43             : namespace casa { //# NAMESPACE CASA - BEGIN
      44             :   
      45             :   class VisBuffer;
      46             :   //  class EVLAAperture : public ATerm
      47             :   namespace refim{
      48             :   class EVLAAperture : public AzElAperture
      49             :   {
      50             :   public:
      51             :     //    EVLAAperture(): ATerm(), polMap_p(), feedStokes_p() {};
      52             :     EVLAAperture();
      53           0 :     ~EVLAAperture() {};
      54             :     EVLAAperture& operator=(const EVLAAperture& other);
      55             :     //
      56             :     // Overload these functions.  They are pure virtual in the base class (ATerm).
      57             :     //
      58           0 :     virtual casacore::String name() {return casacore::String("EVLA Aperture");};
      59             : 
      60             :     virtual void makeFullJones(casacore::ImageInterface<casacore::Complex>& pbImage,
      61             :                                const VisBuffer2& vb,
      62             :                                casacore::Bool doSquint, casacore::Int& bandID, casacore::Double freqVal);
      63             : 
      64             :     virtual void applySky(casacore::ImageInterface<casacore::Float>& outputImages,
      65             :                           const VisBuffer2& vb, 
      66             :                           const casacore::Bool doSquint=true,
      67             :                           const casacore::Int& cfKey=0,
      68             :                           const casacore::Int& muellerTerm=0,
      69             :                           const casacore::Double freqVal=-1.0);
      70             :     virtual void applySky(casacore::ImageInterface<casacore::Complex>& outputImages,
      71             :                           const VisBuffer2& vb, 
      72             :                           const casacore::Bool doSquint=true,
      73             :                           const casacore::Int& cfKey=0,
      74             :                           const casacore::Int& muellerTerm=0,
      75             :                           const casacore::Double freqVal=-1.0);
      76             :     virtual void applySky(casacore::ImageInterface<casacore::Complex>& outImages,
      77             :                           const casacore::Double& pa,
      78             :                           const casacore::Bool doSquint,
      79             :                           const casacore::Int& cfKey,
      80             :                           const casacore::Int& muellerTerm,
      81             :                           const casacore::Double freqVal=-1.0);
      82             :     //Average RR and LL beam 
      83             :     //This is the best to avoid considering the squint of the VLA R and L receptors 
      84             :     void applyAvgSkyJones(casacore::ImageInterface<casacore::Complex> &outImages);
      85             :     //This will generate  the diagonal BeamSkyJones (RR, RL, LR, LL) including the squint at given pa
      86             :     // This returns the diagonal Mueller terms PB in the 4 planes  (i.e Mueller term 0, 5, 10 , 15)
      87             :     // this is not for heterogenous antennas R and L are assumed to come from exactly similar
      88             :     //  antennas
      89             :     void applyDiagSkyJones(casacore::ImageInterface<casacore::Complex>& outImages,
      90             :                                                  const casacore::Double pa);
      91             : 
      92             :     // you have to call the following to set between VLA and EVLA (otherwise default is EVLA)
      93             :     void cacheVBInfo(const casacore::String& telescopeName, const casacore::Float& diameter);
      94             :     void cacheVBInfo(const VisBuffer2& vb);
      95             :     casacore::Int getBandID(const casacore::Double& freq, const casacore::String& telescopeName, const casacore::String& bandName);
      96             :     //As this is a specialization for VLA or EVLA
      97             :     static casacore::String getVLABandName(const casacore::Double& freq, const casacore::String& tel="EVLA");
      98             :     casacore::Int getBandID(const casacore::Double& freq, const casacore::String& bandname="");
      99           0 :     virtual casacore::Vector<casacore::Int> vbRow2CFKeyMap(const VisBuffer2& vb, casacore::Int& nUnique)
     100           0 :     {casacore::Vector<casacore::Int> tmp; tmp.resize(vb.nRows()); tmp=0; nUnique=1; return tmp;}
     101             : 
     102           0 :     virtual void getPolMap(casacore::Vector<casacore::Int>& polMap) {polMap.resize(0);polMap=polMap_p;};
     103             : 
     104             :     // For this class, these will be served from the base classs (ATerm.h)
     105             :     // virtual casacore::Int getConvSize() {return CONVSIZE;};
     106             :     // virtual casacore::Int getOversampling() {return OVERSAMPLING;}
     107             :     // virtual casacore::Float getConvWeightSizeFactor() {return CONVWTSIZEFACTOR;};
     108             :     // virtual casacore::Float getSupportThreshold() {return THRESHOLD;};
     109             : 
     110             :   protected:
     111             :     int getVisParams(const VisBuffer2& vb,const casacore::CoordinateSystem& skyCoord=casacore::CoordinateSystem());
     112             :     casacore::Bool findSupport(casacore::Array<casacore::Complex>& func, casacore::Float& threshold,casacore::Int& origin, casacore::Int& R);
     113             :     casacore::Int getVLABandID(casacore::Double& freq,casacore::String&telescopeName, const casacore::CoordinateSystem& skyCoord=casacore::CoordinateSystem());
     114             :     casacore::Int makePBPolnCoords(const VisBuffer2&vb,
     115             :                          const casacore::Int& convSize,
     116             :                          const casacore::Int& convSampling,
     117             :                          const casacore::CoordinateSystem& skyCoord,
     118             :                          const casacore::Int& skyNx, const casacore::Int& skyNy,
     119             :                          casacore::CoordinateSystem& feedCoord);
     120             :     void setApertureParams(ApertureCalcParams& ap,
     121             :                            const casacore::Float& Freq, const casacore::Float& pa, 
     122             :                            const casacore::Int& bandID,
     123             :                            const casacore::IPosition& skyShape,
     124             :                            const casacore::Vector<casacore::Double>& uvIncr);
     125             : 
     126             :   private:
     127             :     casacore::Vector<casacore::Int> polMap_p;
     128             :     casacore::Vector<casacore::Int> feedStokes_p;
     129             :   };
     130             : };
     131             : };
     132             : #endif

Generated by: LCOV version 1.16