annotate Allan.h @ 135:77539f2597b1

Code cleanup
author Daniele Nicolodi <daniele.nicolodi@obspm.fr>
date Wed, 22 Jan 2014 12:29:38 +0100
parents bd28161e5ac2
children 7b9cf3d4346e
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
Daniele Nicolodi <daniele.nicolodi@obspm.fr>
parents:
diff changeset
1 #include "YLCStuff.h"
Daniele Nicolodi <daniele.nicolodi@obspm.fr>
parents:
diff changeset
2
Daniele Nicolodi <daniele.nicolodi@obspm.fr>
parents:
diff changeset
3 #define ALLAN_MAXPOINTSNUMBER 13 // can compute Allan dev for tau from 1s to 2^13 s =8192 s ~ 2h15' < 10000 s
Daniele Nicolodi <daniele.nicolodi@obspm.fr>
parents:
diff changeset
4
Daniele Nicolodi <daniele.nicolodi@obspm.fr>
parents:
diff changeset
5
Daniele Nicolodi <daniele.nicolodi@obspm.fr>
parents:
diff changeset
6 // Allan_Data : the data of crypto class Allan
Daniele Nicolodi <daniele.nicolodi@obspm.fr>
parents:
diff changeset
7
Daniele Nicolodi <daniele.nicolodi@obspm.fr>
parents:
diff changeset
8 typedef struct {
Daniele Nicolodi <daniele.nicolodi@obspm.fr>
parents:
diff changeset
9 PanelHandle AllanPanel ; // le handle sur le graphe
Daniele Nicolodi <daniele.nicolodi@obspm.fr>
parents:
diff changeset
10 double AllanVar[ALLAN_MAXPOINTSNUMBER] ; // the values of variances for each tau = 2^n.tau_0 (with n from 0 to ALLAN_MAXPOINTSNUMBER)
Daniele Nicolodi <daniele.nicolodi@obspm.fr>
parents:
diff changeset
11 double FirstMean[ALLAN_MAXPOINTSNUMBER] ; // the means of the first block of 2^n data for which averaging was completed
Daniele Nicolodi <daniele.nicolodi@obspm.fr>
parents:
diff changeset
12 double LastMean[ALLAN_MAXPOINTSNUMBER] ; // the means of the last block of 2^n data for which averaging was completed
Daniele Nicolodi <daniele.nicolodi@obspm.fr>
parents:
diff changeset
13 int BlocksNumber[ALLAN_MAXPOINTSNUMBER] ; // the number of blocks of 2^n data (averaged) used for computing AVAR(2^ntau)
Daniele Nicolodi <daniele.nicolodi@obspm.fr>
parents:
diff changeset
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
Daniele Nicolodi <daniele.nicolodi@obspm.fr>
parents:
diff changeset
15 int NbCurrentAverage[ALLAN_MAXPOINTSNUMBER] ; // number of data point being summed in CurrentAverage (from 0 up to 2^n)
Daniele Nicolodi <daniele.nicolodi@obspm.fr>
parents:
diff changeset
16 double Drift, Mean ; // the drift rate of the data (in Hz/s), and the mean value (in Hz) : only usefull for dedrifting...
135
77539f2597b1 Code cleanup
Daniele Nicolodi <daniele.nicolodi@obspm.fr>
parents: 134
diff changeset
17 double normalization;
77539f2597b1 Code cleanup
Daniele Nicolodi <daniele.nicolodi@obspm.fr>
parents: 134
diff changeset
18 int autoscale;
134
bd28161e5ac2 Major code cleanup
Daniele Nicolodi <daniele.nicolodi@obspm.fr>
parents: 0
diff changeset
19 int active;
bd28161e5ac2 Major code cleanup
Daniele Nicolodi <daniele.nicolodi@obspm.fr>
parents: 0
diff changeset
20 int parent;
bd28161e5ac2 Major code cleanup
Daniele Nicolodi <daniele.nicolodi@obspm.fr>
parents: 0
diff changeset
21 int control;
bd28161e5ac2 Major code cleanup
Daniele Nicolodi <daniele.nicolodi@obspm.fr>
parents: 0
diff changeset
22 } Allan_Data ;
0
Daniele Nicolodi <daniele.nicolodi@obspm.fr>
parents:
diff changeset
23
Daniele Nicolodi <daniele.nicolodi@obspm.fr>
parents:
diff changeset
24
Daniele Nicolodi <daniele.nicolodi@obspm.fr>
parents:
diff changeset
25 // The functions of crypto class Allan
Daniele Nicolodi <daniele.nicolodi@obspm.fr>
parents:
diff changeset
26
135
77539f2597b1 Code cleanup
Daniele Nicolodi <daniele.nicolodi@obspm.fr>
parents: 134
diff changeset
27 void Allan_InitPanel(Allan_Data * Instance, const char * title, double Normalizer, int parent, int control) ;
77539f2597b1 Code cleanup
Daniele Nicolodi <daniele.nicolodi@obspm.fr>
parents: 134
diff changeset
28 void Allan_ClosePanel(Allan_Data * Instance) ;
77539f2597b1 Code cleanup
Daniele Nicolodi <daniele.nicolodi@obspm.fr>
parents: 134
diff changeset
29 void Allan_AddFrequency(Allan_Data * Instance, double Freq) ;
0
Daniele Nicolodi <daniele.nicolodi@obspm.fr>
parents:
diff changeset
30