comparison Allan.h @ 134:bd28161e5ac2

Major code cleanup
author Daniele Nicolodi <daniele.nicolodi@obspm.fr>
date Wed, 22 Jan 2014 12:29:28 +0100
parents d9aae7d7f2c6
children 77539f2597b1
comparison
equal deleted inserted replaced
133:7540703b8473 134:bd28161e5ac2
5 5
6 // Allan_Data : the data of crypto class Allan 6 // Allan_Data : the data of crypto class Allan
7 7
8 typedef struct { 8 typedef struct {
9 PanelHandle AllanPanel ; // le handle sur le graphe 9 PanelHandle AllanPanel ; // le handle sur le graphe
10 void (*OnClosePanel)(int); // pointer on a function to execute when the panel is closed (argument is the panel Handle)
11 double AllanVar[ALLAN_MAXPOINTSNUMBER] ; // the values of variances for each tau = 2^n.tau_0 (with n from 0 to ALLAN_MAXPOINTSNUMBER) 10 double AllanVar[ALLAN_MAXPOINTSNUMBER] ; // the values of variances for each tau = 2^n.tau_0 (with n from 0 to ALLAN_MAXPOINTSNUMBER)
12 double FirstMean[ALLAN_MAXPOINTSNUMBER] ; // the means of the first block of 2^n data for which averaging was completed 11 double FirstMean[ALLAN_MAXPOINTSNUMBER] ; // the means of the first block of 2^n data for which averaging was completed
13 double LastMean[ALLAN_MAXPOINTSNUMBER] ; // the means of the last block of 2^n data for which averaging was completed 12 double LastMean[ALLAN_MAXPOINTSNUMBER] ; // the means of the last block of 2^n data for which averaging was completed
14 int BlocksNumber[ALLAN_MAXPOINTSNUMBER] ; // the number of blocks of 2^n data (averaged) used for computing AVAR(2^ntau) 13 int BlocksNumber[ALLAN_MAXPOINTSNUMBER] ; // the number of blocks of 2^n data (averaged) used for computing AVAR(2^ntau)
15 double CurrentAverage[ALLAN_MAXPOINTSNUMBER] ; // the sum of the last p data points retrieved (with p<2^2n). used for averaging as soon as p=2^n 14 double CurrentAverage[ALLAN_MAXPOINTSNUMBER] ; // the sum of the last p data points retrieved (with p<2^2n). used for averaging as soon as p=2^n
16 int NbCurrentAverage[ALLAN_MAXPOINTSNUMBER] ; // number of data point being summed in CurrentAverage (from 0 up to 2^n) 15 int NbCurrentAverage[ALLAN_MAXPOINTSNUMBER] ; // number of data point being summed in CurrentAverage (from 0 up to 2^n)
17 double Drift, Mean ; // the drift rate of the data (in Hz/s), and the mean value (in Hz) : only usefull for dedrifting... 16 double Drift, Mean ; // the drift rate of the data (in Hz/s), and the mean value (in Hz) : only usefull for dedrifting...
18 } Allan_Data ; 17 int active;
18 int parent;
19 int control;
20 } Allan_Data ;
19 21
20 22
21 // The functions of crypto class Allan 23 // The functions of crypto class Allan
22 24
23 int Allan_InitPanel(Allan_Data * Instance, char * title, double Normalizer, void (*OnCloseFunc)(int)) ; 25 int Allan_InitPanel(Allan_Data * Instance, const char * title, double Normalizer, int parent, int control) ;
24 int Allan_ClosePanel(Allan_Data * Instance) ; 26 int Allan_ClosePanel(Allan_Data * Instance) ;
25 int Allan_AddFrequency(Allan_Data * Instance, double Freq) ; 27 int Allan_AddFrequency(Allan_Data * Instance, double Freq) ;
26 28
27 int Allan_Reset(Allan_Data * Instance) ; 29 int Allan_Reset(Allan_Data * Instance) ;
28 int Allan_AddFrequency(Allan_Data * Instance, double Freq); 30 int Allan_AddFrequency(Allan_Data * Instance, double Freq);