Commit 382cdeac1ca7f2f440a21990b9eeb33a2726f098

Authored by Jürgen Knödlseder
1 parent 7ec5a316

Change const references to members in integration kernel helper classes. This sh…

…ould fix the bug #1556.
include/GModelSpectralExpPlaw.hpp
1 1 /***************************************************************************
2 2 * GModelSpectralExpPlaw.hpp - Exponential cut off power law model *
3 3 * ----------------------------------------------------------------------- *
4   - * copyright (C) 2010-2014 by Juergen Knoedlseder *
  4 + * copyright (C) 2010-2015 by Juergen Knoedlseder *
5 5 * ----------------------------------------------------------------------- *
6 6 * *
7 7 * This program is free software: you can redistribute it and/or modify *
... ... @@ -124,10 +124,10 @@ protected:
124 124 m_inv_ecut(1.0/ecut) {}
125 125 double eval(const double& eng);
126 126 protected:
127   - const double& m_norm; //!< Normalization
128   - const double& m_index; //!< Index
129   - double m_inv_pivot; //!< 1 / Pivot energy
130   - double m_inv_ecut; //!< 1 / Cut off energy
  127 + double m_norm; //!< Normalization
  128 + double m_index; //!< Index
  129 + double m_inv_pivot; //!< 1 / Pivot energy
  130 + double m_inv_ecut; //!< 1 / Cut off energy
131 131 };
132 132  
133 133 // Energy flux integration kernel
... ... @@ -143,10 +143,10 @@ protected:
143 143 m_inv_ecut(1.0/ecut) {}
144 144 double eval(const double& eng);
145 145 protected:
146   - const double& m_norm; //!< Normalization
147   - const double& m_index; //!< Index
148   - double m_inv_pivot; //!< 1 / Pivot energy
149   - double m_inv_ecut; //!< 1 / Cut off energy
  146 + double m_norm; //!< Normalization
  147 + double m_index; //!< Index
  148 + double m_inv_pivot; //!< 1 / Pivot energy
  149 + double m_inv_ecut; //!< 1 / Cut off energy
150 150 };
151 151  
152 152 // Protected members
... ...
include/GModelSpectralGauss.hpp
1 1 /***************************************************************************
2 2 * GModelSpectralGauss.hpp - Spectral Gaussian model class *
3 3 * ----------------------------------------------------------------------- *
4   - * copyright (C) 2014 by Christoph Deil & Ellis Owen *
  4 + * copyright (C) 2014-2015 by Christoph Deil & Ellis Owen *
5 5 * ----------------------------------------------------------------------- *
6 6 * *
7 7 * This program is free software: you can redistribute it and/or modify *
... ... @@ -116,9 +116,9 @@ protected:
116 116 m_sigma(sigma) {}
117 117 double eval(const double& eng);
118 118 protected:
119   - const double& m_norm; //!< Normalization
120   - const double& m_mean; //!< Mean
121   - const double& m_sigma; //!< Sigma
  119 + double m_norm; //!< Normalization
  120 + double m_mean; //!< Mean
  121 + double m_sigma; //!< Sigma
122 122 };
123 123  
124 124 // Protected members
... ...
include/GModelSpectralLogParabola.hpp
1 1 /***************************************************************************
2 2 * GModelSpectralLogParabola.hpp - Log parabola spectral model class *
3 3 * ----------------------------------------------------------------------- *
4   - * copyright (C) 2012-2014 by Michael Mayer *
  4 + * copyright (C) 2012-2015 by Michael Mayer *
5 5 * ----------------------------------------------------------------------- *
6 6 * *
7 7 * This program is free software: you can redistribute it and/or modify *
... ... @@ -135,13 +135,13 @@ protected:
135 135  
136 136 // Members
137 137 protected:
138   - const double& m_norm; //!< Normalization
139   - const double& m_index; //!< Spectral index at pivot
140   - const double& m_curvature; //!< Curvature
141   - const GEnergy& m_pivot; //!< Pivot energy
  138 + double m_norm; //!< Normalization
  139 + double m_index; //!< Spectral index at pivot
  140 + double m_curvature; //!< Curvature
  141 + GEnergy m_pivot; //!< Pivot energy
142 142 };
143 143  
144   - // Class to determine the integral energyflux, derviation of flux_kern
  144 + // Class to determine the integral energy flux, derviation of flux_kern
145 145 class eflux_kern : public flux_kern {
146 146 public:
147 147 // Constructor
... ...
include/GModelSpectralSuperExpPlaw.hpp
1 1 /***************************************************************************
2 2 * GModelSpectralSuperExpPlaw.hpp - Super exp. cut off power law model *
3 3 * ----------------------------------------------------------------------- *
4   - * copyright (C) 2014 by Michael Mayer *
  4 + * copyright (C) 2014-2015 by Michael Mayer *
5 5 * ----------------------------------------------------------------------- *
6 6 * *
7 7 * This program is free software: you can redistribute it and/or modify *
... ... @@ -131,11 +131,11 @@ protected:
131 131 m_index2(index2) {}
132 132 double eval(const double& eng);
133 133 protected:
134   - const double& m_norm; //!< Normalization
135   - const double& m_index1; //!< Index1
136   - double m_inv_pivot; //!< 1 / Pivot energy
137   - double m_inv_ecut; //!< 1 / Cut off energy
138   - const double& m_index2; //!< Index2
  134 + double m_norm; //!< Normalization
  135 + double m_index1; //!< Index1
  136 + double m_inv_pivot; //!< 1 / Pivot energy
  137 + double m_inv_ecut; //!< 1 / Cut off energy
  138 + double m_index2; //!< Index2
139 139 };
140 140  
141 141 // Energy flux integration kernel
... ... @@ -153,11 +153,11 @@ protected:
153 153 m_index2(index2) {}
154 154 double eval(const double& eng);
155 155 protected:
156   - const double& m_norm; //!< Normalization
157   - const double& m_index1; //!< Index1
158   - double m_inv_pivot; //!< 1 / Pivot energy
159   - double m_inv_ecut; //!< 1 / Cut off energy
160   - const double& m_index2; //!< Index2
  156 + double m_norm; //!< Normalization
  157 + double m_index1; //!< Index1
  158 + double m_inv_pivot; //!< 1 / Pivot energy
  159 + double m_inv_ecut; //!< 1 / Cut off energy
  160 + double m_index2; //!< Index2
161 161 };
162 162  
163 163 // Protected members
... ...
include/GResponse.hpp
... ... @@ -31,6 +31,7 @@
31 31 #include <string>
32 32 #include "GBase.hpp"
33 33 #include "GFunction.hpp"
  34 +#include "GTime.hpp"
34 35  
35 36 /* __ Forward declarations _______________________________________________ */
36 37 class GEvent;
... ... @@ -38,7 +39,6 @@ class GPhoton;
38 39 class GSource;
39 40 class GEnergy;
40 41 class GEbounds;
41   -class GTime;
42 42 class GObservation;
43 43 class GModelSky;
44 44  
... ...