IT++ Logo
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
fastica.h
Go to the documentation of this file.
1 
62 #ifndef FASTICA_H
63 #define FASTICA_H
64 
65 #include <itpp/base/mat.h>
66 
67 
69 #define FICA_APPROACH_DEFL 2
70 
71 #define FICA_APPROACH_SYMM 1
72 
74 #define FICA_NONLIN_POW3 10
75 
76 #define FICA_NONLIN_TANH 20
77 
78 #define FICA_NONLIN_GAUSS 30
79 
80 #define FICA_NONLIN_SKEW 40
81 
83 #define FICA_INIT_RAND 0
84 
85 #define FICA_INIT_GUESS 1
86 
88 #define FICA_TOL 1e-9
89 
90 namespace itpp
91 {
92 
97 //---------------------- FastICA --------------------------------------
98 
118 class Fast_ICA
119 {
120 
121 public:
122 
130  Fast_ICA(mat ma_mixed_sig);
131 
137  void separate(void);
138 
146  void set_approach(int in_approach);
147 
155  void set_nrof_independent_components(int in_nrIC);
156 
164  void set_non_linearity(int in_g);
165 
173  void set_fine_tune(bool in_finetune);
174 
182  void set_a1(double fl_a1);
183 
191  void set_a2(double fl_a2);
192 
200  void set_mu(double fl_mu);
201 
209  void set_epsilon(double fl_epsilon);
210 
218  void set_sample_size(double fl_sampleSize);
219 
227  void set_stabilization(bool in_stabilization);
228 
236  void set_max_num_iterations(int in_maxNumIterations);
237 
245  void set_max_fine_tune(int in_maxFineTune);
246 
254  void set_first_eig(int in_firstEig);
255 
263  void set_last_eig(int in_lastEig);
264 
272  void set_pca_only(bool in_PCAonly);
273 
281  void set_init_guess(mat ma_initGuess);
282 
283 
291  mat get_mixing_matrix();
292 
300  mat get_separating_matrix();
301 
310 
319 
328 
336  mat get_whitening_matrix();
337 
346 
354  mat get_white_sig();
355 
356 private:
357 
358  int approach, numOfIC, g, initState;
359  bool finetune, stabilization, PCAonly;
360  double a1, a2, mu, epsilon, sampleSize;
361  int maxNumIterations, maxFineTune;
362 
363  int firstEig, lastEig;
364 
365  mat initGuess;
366 
367  mat mixedSig, A, W, icasig;
368 
369  mat whiteningMatrix;
370  mat dewhiteningMatrix;
371  mat whitesig;
372 
373  mat E, VecPr;
374  vec D;
375 
376 }; // class Fast_ICA
377 
378 } // namespace itpp
379 
380 
381 #endif // #ifndef FASTICA_H
SourceForge Logo

Generated on Fri Mar 21 2014 17:14:14 for IT++ by Doxygen 1.8.1.2