casa  5.7.0-16
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
SolvableVJMBuf.h
Go to the documentation of this file.
1 //# SolvableVJMBuf.h: SolvableVisJones calibration main table buffer
2 //# Copyright (C) 1996,1997,1998,2001,2002,2003
3 //# Associated Universities, Inc. Washington DC, USA.
4 //#
5 //# This library is free software; you can redistribute it and/or modify it
6 //# under the terms of the GNU Library General Public License as published by
7 //# the Free Software Foundation; either version 2 of the License, or (at your
8 //# option) any later version.
9 //#
10 //# This library is distributed in the hope that it will be useful, but WITHOUT
11 //# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
12 //# FITNESS FOR A PARTICULAR PURPOSE. See the GNU Library General Public
13 //# License for more details.
14 //#
15 //# You should have received a copy of the GNU Library General Public License
16 //# along with this library; if not, write to the Free Software Foundation,
17 //# Inc., 675 Massachusetts Ave, Cambridge, MA 02139, USA.
18 //#
19 //# Correspondence concerning AIPS++ should be adressed as follows:
20 //# Internet email: aips2-request@nrao.edu.
21 //# Postal address: AIPS++ Project Office
22 //# National Radio Astronomy Observatory
23 //# 520 Edgemont Road
24 //# Charlottesville, VA 22903-2475 USA
25 //#
26 //#
27 //# $Id$
28 
29 #ifndef CALIBRATION_SOLVABLEVJMBUF_H
30 #define CALIBRATION_SOLVABLEVJMBUF_H
31 
35 
36 namespace casa { //# NAMESPACE CASA - BEGIN
37 
38 // <summary>
39 // SolvableVisJonesMBuf: SolvableVisJones calibration main table buffer
40 // </summary>
41 
42 // <use visibility=export>
43 
44 // <reviewed reviewer="" date="" tests="" demos="">
45 
46 // <prerequisite>
47 // <li> <linkto class="CalMainBuffer">CalMainBuffer</linkto> module
48 // <li> <linkto class="TimeVarVisJonesMBuf">TimeVarVisJonesMBuf</linkto> module
49 // </prerequisite>
50 //
51 // <etymology>
52 // From "solvable visibility Jones matrix", "cal main table" and "buffer"
53 // </etymology>
54 //
55 // <synopsis>
56 // The SolvableVisJonesMBuf class holds a buffer, optionally connected to a
57 // SolvableVisJones calibration main table iterator (of base type
58 // CalIterBase). Specializations for different solvable Jones matrix
59 // types are provided through inheritance.
60 // </synopsis>
61 //
62 // <example>
63 // <srcblock>
64 // </srcblock>
65 // </example>
66 //
67 // <motivation>
68 // Encapsulate SolvableVisJones calibration main table data buffers.
69 // </motivation>
70 //
71 // <todo asof="01/08/01">
72 // (i) Deal with non-standard columns.
73 // </todo>
74 
76 {
77  public:
78  // Default constructor. No connection to an underlying
79  // calibration table iterator in this case.
81 
82  // Construct from a set of calibration buffer indices and
83  // their specified values. Non-index columns will be set
84  // to default values, and there is no connection to an
85  // underlying calibration table iterator in this case.
88 
89  // Construct from a calibration table iterator. The calibration
90  // buffer will remain synchronized with the iterator.
92 
93  // Write the current buffer at the end of a specified cal table;
94  // returns the number of rows appended
95  virtual casacore::Int append (CalTable& calTable);
96 
97  // Maximum number of rows in the calibration buffer
98  virtual casacore::Int nRow();
99 
100  // casacore::Data field accessors
109 
110  protected:
111  // Factory method to create a columns accessor object of the appropriate type
113  return new
114  SolvableVisJonesMCol(dynamic_cast<SolvableVisJonesTable&>(calTable));};
115 
116  // Calibration table columns accessor
118  {return dynamic_cast<SolvableVisJonesMCol*>(CalMainBuffer::calMainCol());};
119 
120  // Invalidate the current cache.
121  virtual void invalidate();
122 
123  // <group>
124  // Fill the cal buffer attribute columns in an empty cal buffer,
125  // after the cal indices have been set using fillIndices(). The
126  // cal indices, specified as enums from class MSCalEnums, are excluded
127  // as non-attribute columns
128  //
129  // Use a visibility buffer to define the attribute values (NYI)
130  virtual void fillAttributes(const casacore::Vector<casacore::Int>& /*calIndices*/,
131  const VisBuffer& /*vb*/) {};
132  //
133  // Set default attribute values
134  virtual void fillAttributes(const casacore::Vector<casacore::Int>& calIndices);
135  // </group>
136 
137  private:
138  // Buffer fields
147 
148  // Buffer field status flags
157 };
158 
159 // <summary>
160 // GJonesMBuf: GJones calibration main table buffer
161 // </summary>
162 
163 // <use visibility=export>
164 
165 // <reviewed reviewer="" date="" tests="" demos="">
166 
167 // <prerequisite>
168 // <li> <linkto class="CalMainBuffer">CalMainBuffer</linkto> module
169 // <li> <linkto class="SolvableVisJonesMBuf">SolvableVisJonesMBuf</linkto> module
170 // </prerequisite>
171 //
172 // <etymology>
173 // From "GJones matrix", "cal main table" and "buffer"
174 // </etymology>
175 //
176 // <synopsis>
177 // The GJonesMBuf class holds a buffer, optionally connected to a
178 // GJones calibration main table iterator (of base type CalIterBase).
179 // The GJones matrix contains electronic gain correction terms.
180 // </synopsis>
181 //
182 // <example>
183 // <srcblock>
184 // </srcblock>
185 // </example>
186 //
187 // <motivation>
188 // Encapsulate GJones calibration main table data buffers.
189 // </motivation>
190 //
191 // <todo asof="01/08/01">
192 // (i) Deal with non-standard columns.
193 // </todo>
194 
196 {
197  public:
198  // Default constructor. No connection to an underlying
199  // calibration table iterator in this case.
200  GJonesMBuf();
201 
202  // Construct from a set of calibration buffer indices and
203  // their specified values. Non-index columns will be set
204  // to default values, and there is no connection to an
205  // underlying calibration table iterator in this case.
206  GJonesMBuf (const casacore::Vector<casacore::Int>& calIndices,
207  const casacore::Block<casacore::Vector<casacore::Int> >& indexValues);
208 
209  // Construct from a calibration table iterator. The calibration
210  // buffer will remain synchronized with the iterator.
211  GJonesMBuf (CalIterBase& calIter);
212 
213  // Update the calibration solution in each of a set of buffer rows
215  const casacore::String& sFreqGrpName,
216  const casacore::Complex& sGain,
217  const casacore::MFrequency& sRefFreq,
218  const casacore::Int& sRefAnt);
219  protected:
220 
221  private:
222 };
223 
224 // <summary>
225 // DJonesMBuf: DJones calibration main table buffer
226 // </summary>
227 
228 // <use visibility=export>
229 
230 // <reviewed reviewer="" date="" tests="" demos="">
231 
232 // <prerequisite>
233 // <li> <linkto class="CalMainBuffer">CalMainBuffer</linkto> module
234 // <li> <linkto class="SolvableVisJonesMBuf">SolvableVisJonesMBuf</linkto> module
235 // </prerequisite>
236 //
237 // <etymology>
238 // From "DJones matrix", "cal main table" and "buffer"
239 // </etymology>
240 //
241 // <synopsis>
242 // The DJonesMBuf class holds a buffer, optionally connected to a
243 // DJones calibration main table iterator (of base type CalIterBase).
244 // The DJones matrix contains instrumental polarization corrections.
245 // </synopsis>
246 //
247 // <example>
248 // <srcblock>
249 // </srcblock>
250 // </example>
251 //
252 // <motivation>
253 // Encapsulate DJones calibration main table data buffers.
254 // </motivation>
255 //
256 // <todo asof="01/08/01">
257 // (i) Deal with non-standard columns.
258 // </todo>
259 
261 {
262  public:
263  // Default constructor. No connection to an underlying
264  // calibration table iterator in this case.
265  DJonesMBuf();
266 
267  // Construct from a set of calibration buffer indices and
268  // their specified values. Non-index columns will be set
269  // to default values, and there is no connection to an
270  // underlying calibration table iterator in this case.
271  DJonesMBuf (const casacore::Vector<casacore::Int>& calIndices,
272  const casacore::Block<casacore::Vector<casacore::Int> >& indexValues);
273 
274  // Construct from a calibration table iterator. The calibration
275  // buffer will remain synchronized with the iterator.
276  DJonesMBuf (CalIterBase& calIter);
277 
278  protected:
279 
280  private:
281 };
282 
283 // <summary>
284 // TJonesMBuf: TJones calibration main table buffer
285 // </summary>
286 
287 // <use visibility=export>
288 
289 // <reviewed reviewer="" date="" tests="" demos="">
290 
291 // <prerequisite>
292 // <li> <linkto class="CalMainBuffer">CalMainBuffer</linkto> module
293 // <li> <linkto class="SolvableVisJonesMBuf">SolvableVisJonesMBuf</linkto> module
294 // </prerequisite>
295 //
296 // <etymology>
297 // From "TJones matrix", "cal main table" and "buffer"
298 // </etymology>
299 //
300 // <synopsis>
301 // The TJonesMBuf class holds a buffer, optionally connected to a
302 // TJones calibration main table iterator (of base type CalIterBase).
303 // The TJones matrix contains atmospheric corrections.
304 // </synopsis>
305 //
306 // <example>
307 // <srcblock>
308 // </srcblock>
309 // </example>
310 //
311 // <motivation>
312 // Encapsulate TJones calibration main table data buffers.
313 // </motivation>
314 //
315 // <todo asof="01/08/01">
316 // (i) Deal with non-standard columns.
317 // </todo>
318 
320 {
321  public:
322  // Default constructor. No connection to an underlying
323  // calibration table iterator in this case.
324  TJonesMBuf();
325 
326  // Construct from a set of calibration buffer indices and
327  // their specified values. Non-index columns will be set
328  // to default values, and there is no connection to an
329  // underlying calibration table iterator in this case.
330  TJonesMBuf (const casacore::Vector<casacore::Int>& calIndices,
331  const casacore::Block<casacore::Vector<casacore::Int> >& indexValues);
332 
333  // Construct from a calibration table iterator. The calibration
334  // buffer will remain synchronized with the iterator.
335  TJonesMBuf (CalIterBase& calIter);
336 
337  protected:
338 
339  private:
340 };
341 
342 
343 } //# NAMESPACE CASA - END
344 
345 #endif
346 
347 
348 
349 
350 
GJonesMBuf: GJones calibration main table buffer.
int Int
Definition: aipstype.h:50
virtual casacore::Bool fillMatchingRows(const casacore::Vector< casacore::Int > &matchingRows, const casacore::String &sFreqGrpName, const casacore::Complex &sGain, const casacore::MFrequency &sRefFreq, const casacore::Int &sRefAnt)
Update the calibration solution in each of a set of buffer rows.
virtual SolvableVisJonesMCol * newCalMainCol(CalTable &calTable)
Factory method to create a columns accessor object of the appropriate type.
GJonesMBuf()
Default constructor.
casacore::Array< casacore::Float > snr_p
casacore::Array< casacore::Bool > flag_p
DJonesMBuf: DJones calibration main table buffer.
virtual casacore::Vector< casacore::Bool > & totalSolnOk()
casacore::Data field accessors
virtual void invalidate()
Invalidate the current cache.
virtual SolvableVisJonesMCol * calMainCol()
Calibration table columns accessor.
virtual casacore::Array< casacore::Bool > & solnOk()
casacore::Vector< casacore::Float > totalFitWgt_p
casacore::Vector< casacore::Bool > totalSolnOk_p
Buffer fields.
TJonesMBuf()
Default constructor.
casacore::Vector< casacore::Float > totalFit_p
CalTable: Calibration table access and creation.
Definition: CalTable.h:82
A Measure: wave characteristics.
Definition: MFrequency.h:161
virtual casacore::Int append(CalTable &calTable)
Write the current buffer at the end of a specified cal table; returns the number of rows appended...
CalIterBase: Base class for calibration table iterators.
Definition: CalIterBase.h:74
SolvableVisJonesMBuf: SolvableVisJones calibration main table buffer.
virtual casacore::Array< casacore::Bool > & flag()
virtual casacore::Int nRow()
Maximum number of rows in the calibration buffer.
virtual void fillAttributes(const casacore::Vector< casacore::Int > &, const VisBuffer &)
Fill the cal buffer attribute columns in an empty cal buffer, after the cal indices have been set usi...
SolvableVisJonesMCol: RW SolvableVisJones cal_main column access.
casacore::Bool totalSolnOkOK_p
Buffer field status flags.
virtual casacore::Array< casacore::Float > & fit()
bool Bool
Define the standard types used by Casacore.
Definition: aipstype.h:42
SolvableVisJonesMBuf()
Default constructor.
virtual casacore::Array< casacore::Float > & fitWgt()
simple 1-D array
DJonesMBuf()
Default constructor.
casacore::Array< casacore::Bool > solnOk_p
virtual casacore::Array< casacore::Float > & snr()
virtual casacore::Vector< casacore::Float > & totalFit()
virtual CalMainColumns * calMainCol()
Access to the columns accessor object.
TimeVarVisJonesMBuf: TimeVarVisJones calibration main table buffer.
Definition: TimeVarVJMBuf.h:73
casacore::Bool totalFitWgtOK_p
String: the storage and methods of handling collections of characters.
Definition: String.h:223
VisBuffers encapsulate one chunk of visibility data for processing.
Definition: VisBuffer.h:153
casacore::Array< casacore::Float > fitWgt_p
TJonesMBuf: TJones calibration main table buffer.
virtual casacore::Vector< casacore::Float > & totalFitWgt()
casacore::Array< casacore::Float > fit_p