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

Generated using doxygen 1.8.17