Gyoto
GyotoTorus.h
Go to the documentation of this file.
1 
7 /*
8  Copyright 2011 Thibaut Paumard
9 
10  This file is part of Gyoto.
11 
12  Gyoto is free software: you can redistribute it and/or modify
13  it under the terms of the GNU General Public License as published by
14  the Free Software Foundation, either version 3 of the License, or
15  (at your option) any later version.
16 
17  Gyoto is distributed in the hope that it will be useful,
18  but WITHOUT ANY WARRANTY; without even the implied warranty of
19  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20  GNU General Public License for more details.
21 
22  You should have received a copy of the GNU General Public License
23  along with Gyoto. If not, see <http://www.gnu.org/licenses/>.
24  */
25 
26 #ifndef __GyotoTorus_H_
27 #define __GyotoTorus_H_
28 
29 #include <iostream>
30 #include <fstream>
31 #include <iomanip>
32 #include <string>
33 
34 namespace Gyoto{
35  namespace Astrobj { class Torus; }
36 }
37 
38 #include <GyotoStandardAstrobj.h>
39 #include <GyotoSpectrum.h>
40 #include <GyotoUtils.h>
41 
50  friend class Gyoto::SmartPointer<Gyoto::Astrobj::Torus>;
51 
52 
53  // Data :
54  // -----
55  protected:
61  double c_;
62 
63  SmartPointer<Spectrum::Generic> spectrum_;
64  SmartPointer<Spectrum::Generic> opacity_;
65 
66  // Constructors - Destructor
67  // -------------------------
68  public:
73  Torus();
74 
75  Torus(const Torus& ) ;
76  virtual Torus* clone() const;
77 
78  virtual ~Torus() ;
79 
80  // Accessors
81  // ---------
82  public:
86  double largeRadius() const;
87 
91  double largeRadius(std::string unit) const;
92 
96  double smallRadius() const;
97 
101  double smallRadius(std::string unit) const;
102 
106  void largeRadius(double c);
107 
111  void smallRadius(double a);
112 
116  void largeRadius(double c, std::string unit);
117 
121  void smallRadius(double a, std::string unit);
122 
126  virtual void spectrum(SmartPointer<Spectrum::Generic>);
127 
131  virtual SmartPointer<Spectrum::Generic> spectrum() const;
132 
136  virtual void opacity(SmartPointer<Spectrum::Generic>);
137 
141  virtual SmartPointer<Spectrum::Generic> opacity() const;
142 
143  using Standard::rMax;
144  virtual double rMax();
145 
146  // Outputs
147  // -------
148  public:
149  virtual double operator()(double const coord[4]) ;
150  virtual double deltaMax(double*);
151 
152  protected:
153  virtual void getVelocity(double const pos[4], double vel[4]) ;
154 
155  using Standard::emission;
156  virtual double emission(double nu_em, double dsem, double coord_ph[8],
157  double coord_obj[8]=NULL) const ;
159  virtual double integrateEmission(double nu1, double nu2, double dsem,
160  double c_ph[8], double c_obj[8]=NULL) const;
161 
162  virtual double transmission(double nuem, double dsem, double coord[8]) const ;
163 
164 };
165 
166 #endif
virtual SmartPointer< Spectrum::Generic > opacity() const
Get Torus::opacity_.
#define GYOTO_OBJECT
Declare class::properties and class::getProperties()
Definition: GyotoObject.h:83
virtual SmartPointer< Spectrum::Generic > spectrum() const
Get Torus::spectrum_.
virtual double integrateEmission(double nu1, double nu2, double dsem, double c_ph[8], double c_obj[8]=NULL) const
∫ν1ν2 Iν dν (or jν)
double c_
Large Radius.
Definition: GyotoTorus.h:61
SmartPointer< Spectrum::Generic > opacity_
Absorption law.
Definition: GyotoTorus.h:64
virtual double transmission(double nuem, double dsem, double coord[8]) const
Transmission: exp( αν * dsem )
Optically thin or thick torus in circular rotation.
Definition: GyotoTorus.h:49
virtual double emission(double nu_em, double dsem, double coord_ph[8], double coord_obj[8]=NULL) const
Specific intensity Iν
virtual double rMax()
Get maximal distance from center of coordinate system.
Astronomical objects defined bya a potential/distance.
double largeRadius() const
virtual double emission(double nu_em, double dsem, double coord_ph[8], double coord_obj[8]=NULL) const
Specific intensity Iν
virtual void getVelocity(double const pos[4], double vel[4])
Fluid velocity field.
virtual double rMax()
Get maximal distance from center of coordinate system.
Spectrum of a simple object (e.g. Star)
Namespace for the Gyoto library.
Definition: GyotoAstrobj.h:43
Pointers performing reference counting.
Definition: GyotoProperty.h:41
GYOTO utilities.
SmartPointer< Spectrum::Generic > spectrum_
Emission law.
Definition: GyotoTorus.h:63
Astronomical objects defined bya a potential/distance.
Definition: GyotoStandardAstrobj.h:84
virtual double integrateEmission(double nu1, double nu2, double dsem, double c_ph[8], double c_obj[8]=NULL) const
∫ν1ν2 Iν dν (or jν)
double smallRadius() const
virtual Torus * clone() const
"Virtual" copy constructor