StokesSpherical.h
1 //-*-C++-*-
2 /***************************************************************************
3  *
4  * Copyright (C) 2006-2009 by Willem van Straten
5  * Licensed under the Academic Free License version 2.1
6  *
7  ***************************************************************************/
8 
9 // psrchive/More/Plotting/Pulsar/StokesSpherical.h
10 
11 #ifndef __Pulsar_StokesSpherical_h
12 #define __Pulsar_StokesSpherical_h
13 
14 #include "Pulsar/MultiPhase.h"
15 #include "Pulsar/StokesPlot.h"
16 #include "Pulsar/PosAngPlot.h"
17 #include "Pulsar/EllAngPlot.h"
18 
19 namespace Pulsar {
20 
22  class StokesSpherical : public MultiPhase {
23 
24  public:
25 
28 
31 
32  // Text interface to the StokesSpherical class
33  class Interface : public TextInterface::To<StokesSpherical> {
34  public:
35  Interface (StokesSpherical* = 0);
36  };
37 
39  void prepare (const Archive*);
40 
42  void set_subint (const Index& _isubint) { isubint = _isubint; }
43  Index get_subint () const { return isubint; }
44 
46  void set_chan (const Index& _ichan) { ichan = _ichan; }
47  Index get_chan () const { return ichan; }
48 
50  StokesPlot* get_flux () { return &flux; }
51 
53  PosAngPlot* get_orientation () { return &orientation; }
54 
56  EllAngPlot* get_ellipticity () { return &ellipticity; }
57 
58  protected:
59 
60  StokesPlot flux;
61  PosAngPlot orientation;
62  EllAngPlot ellipticity;
63  Index isubint;
64  Index ichan;
65 
66  template<class T> void prepare (T* plot, const Archive* data = 0)
67  {
68  plot->set_subint (isubint);
69  plot->set_chan (ichan);
70  if (data)
71  plot->prepare (data);
72  }
73 
74  };
75 
76 }
77 
78 #endif
void prepare(const Archive *)
Ensure that frames are properly initialized.
Definition: StokesSpherical.C:58
Combines an index value and integrate flag.
Definition: Index.h:24
EllAngPlot * get_ellipticity()
Get the EllAngPlot.
Definition: StokesSpherical.h:66
void plot(const Archive *)
Plot in the current viewport.
Definition: MultiPlot.C:43
Plots a single pulse profile.
Definition: StokesSpherical.h:27
The primary interface to pulsar observational data.
Definition: Archive.h:45
void set_subint(const Index &_isubint)
Set the sub-integration to plot (where applicable)
Definition: StokesSpherical.h:52
void set_chan(const Index &_ichan)
Set the frequency channel to plot (where applicable)
Definition: StokesSpherical.h:56
StokesSpherical()
Default constructor.
Definition: StokesSpherical.C:13
Plots the ellipticity angle of the polarized radiation.
Definition: EllAngPlot.h:24
PosAngPlot * get_orientation()
Get the PosAngPlot.
Definition: StokesSpherical.h:63
Plots a polarization pulse profile.
Definition: StokesPlot.h:24
TextInterface::Parser * get_interface()
Get the text interface to the configuration attributes.
Definition: StokesSpherical.C:53
Plots the position angle of the linearly polarized radiation.
Definition: PosAngPlot.h:24
StokesPlot * get_flux()
Get the StokesPlot.
Definition: StokesSpherical.h:60
Defines the PSRCHIVE library.
Definition: CalSource.h:17

Generated using doxygen 1.8.17