PearsonVI.h
1 //-*-C++-*-
2 /***************************************************************************
3  *
4  * Copyright (C) 2008 - 2023 by Andrew Jameson and Willem van Straten
5  * Licensed under the Academic Free License version 2.1
6  *
7  ***************************************************************************/
8 
9 #ifndef __dsp_Signal_Statistics_PearsonVI_h
10 #define __dsp_Signal_Statistics_PearsonVI_h
11 
12 #include "dsp/ProbabilityDensity.h"
13 
14 namespace dsp {
15 
17  class PearsonVI : public ProbabilityDensity {
18 
19  public:
20 
21  class Parameters
22  {
23  public:
24  double mu1;
25  double mu2;
26  double mu3;
27  double mu4;
28 
29  double get_alpha();
30  double get_beta();
31  double get_sqrt(); // returns the common term (inside the sqrt) in alpha and beta
32  };
33 
34  PearsonVI (const Parameters&);
35 
37  double evaluate (double x);
38 
39  double get_alpha () { return alpha; }
40  double get_beta () { return beta; }
41  double get_delta () { return delta; }
42 
43  private:
44 
46  void prepare();
47 
49  Parameters stats;
50 
51  double alpha;
52  double beta;
53  double delta;
54 
55  // natural logarithm of Pearson type VI normalisation factor
56  double logk;
57  };
58 }
59 
60 #endif
Contains all Baseband Data Reduction Library classes.
Definition: ASCIIObservation.h:17
const ScalarMath pow(const ScalarMath &x, const ScalarMath &y)
double evaluate(double x)
Compute the PDF(x) of Pearson IV.
Definition: PearsonVI.C:78
const ScalarMath sqrt(const ScalarMath &x)
Pearson VI probability density function.
Definition: PearsonVI.h:22

Generated using doxygen 1.8.17