work/mixpp/libPF.h

Go to the documentation of this file.
00001 
00013 #ifndef PF_H
00014 #define PF_H
00015 
00016 #include <itpp/itbase.h>
00017 #include "libBM.h"
00018 #include "libDC.h"
00019 
00020 using namespace itpp;
00021 
00022 enum RESAMPLING_METHOD { MULTINOMIAL = 0, DETERMINISTIC = 1, RESIDUAL = 2, SYSTEMATIC = 3 };
00023 
00029 class PF : public BM { 
00030 protected:
00031         int n; //number of particles
00032         vec w; //particle weights
00033         
00034 public:
00036         ivec resample(RESAMPLING_METHOD method = SYSTEMATIC);
00037         //TODO get them on the web
00038 };
00039 
00046 class TrivialPF : public PF {
00047         Array<vec> ptcls;
00048         
00049         bool is_proposal;
00050         mpdf *prop;
00051         mpdf *par;
00052         mpdf *obs;
00053         
00054         public:
00055         TrivialPF(mpdf &par, mpdf &obs, mpdf &prop, int n0);
00056         TrivialPF(mpdf &par, mpdf &obs, int n0);
00057         void bayes(const vec &dt, bool evalll);
00058 };
00059 
00060 class MPF : public TrivialPF {
00061         Array<BM> Bms;
00062         public:
00063         MPF(BM &B, mpdf &prop, mpdf &obs, mpdf &par);
00064         void bayes(vec &dt);    
00065 };
00066 
00067 #endif // KF_H
00068 
00069 

Generated on Wed Jan 23 11:30:10 2008 for mixpp by  doxygen 1.5.3