Jpp  17.0.0-rc.1
the software that should make you happy
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
JDispersionInterface.hh
Go to the documentation of this file.
1 #ifndef __JPHYSICS__JDISPERSIONINTERFACE__
2 #define __JPHYSICS__JDISPERSIONINTERFACE__
3 
4 #include <cmath>
5 
6 
7 /**
8  * \author mdejong
9  */
10 
11 namespace JPHYSICS {}
12 namespace JPP { using namespace JPHYSICS; }
13 
14 namespace JPHYSICS {
15 
16  /**
17  * Light dispersion inteface.
18  */
20  public:
21  /**
22  * Virtual destructor.
23  */
25  {}
26 
27 
28  /**
29  * Index of refraction for phase velocity.
30  *
31  * \param lambda wavelenth [nm]
32  * \return index of refraction
33  */
34  virtual double getIndexOfRefractionPhase(const double lambda) const = 0;
35 
36 
37  /**
38  * Dispersion of light for phase velocity.
39  *
40  * \param lambda wavelength of light [nm]
41  * \return dn/dlambda
42  */
43  virtual double getDispersionPhase(const double lambda) const = 0;
44 
45 
46  /**
47  * Index of refraction for group velocity.
48  *
49  * \param lambda wavelenth [nm]
50  * \return index of refraction
51  */
52  virtual double getIndexOfRefractionGroup(const double lambda) const
53  {
54  const double n = getIndexOfRefractionPhase(lambda);
55  const double y = getDispersionPhase(lambda);
56 
57  return n / (1.0 + y*lambda/n);
58  }
59 
60 
61  /**
62  * Dispersion of light for group velocity.
63  *
64  * \param lambda wavelength of light [nm]
65  * \return dn/dlambda
66  */
67  virtual double getDispersionGroup(const double lambda) const = 0;
68 
69 
70  /**
71  * Get effective index of refraction for muon light.
72  *
73  * \param lambda wavelength of light [nm]
74  * \return index of refraction
75  */
76  double getKappa(const double lambda) const
77  {
78  const double n = getIndexOfRefractionPhase(lambda);
79  const double ng = getIndexOfRefractionGroup(lambda);
80 
81  return (ng * n - 1.0) / sqrt(n*n - 1.0);
82  }
83 
84 
85  /**
86  * Get smallest index of refraction for Bremsstrahlung light (i.e.\ point at which dt/dz = 0).
87  *
88  * \param lambda wavelength of light [nm]
89  * \return index of refraction
90  */
91  double getKmin(const double lambda) const
92  {
93  const double ng = getIndexOfRefractionGroup(lambda);
94 
95  return sqrt(ng*ng - 1.0);
96  }
97  };
98 }
99 
100 #endif
double getKmin(const double lambda) const
Get smallest index of refraction for Bremsstrahlung light (i.e. point at which dt/dz = 0)...
virtual double getDispersionGroup(const double lambda) const =0
Dispersion of light for group velocity.
virtual ~JDispersionInterface()
Virtual destructor.
const int n
Definition: JPolint.hh:676
virtual double getIndexOfRefractionPhase(const double lambda) const =0
Index of refraction for phase velocity.
virtual double getIndexOfRefractionGroup(const double lambda) const
Index of refraction for group velocity.
double getKappa(const double lambda) const
Get effective index of refraction for muon light.
Light dispersion inteface.
virtual double getDispersionPhase(const double lambda) const =0
Dispersion of light for phase velocity.