Show
Ignore:
Timestamp:
11/02/09 17:27:29 (15 years ago)
Author:
mido
Message:

mpdf renamed to pdf in the whole library

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • library/bdm/base/bdmbase.h

    r690 r693  
    386386 
    387387//! Conditional probability density, e.g. modeling \f$ f( x | y) \f$, where \f$ x \f$ is random variable, \c rv, and \f$ y \f$ is conditioning variable, \c rvc. 
    388 class mpdf : public root { 
     388class pdf : public root { 
    389389protected: 
    390390        //!dimension of the condition 
     
    403403        //! @{ 
    404404 
    405         mpdf() : dimc ( 0 ), rvc(), dim(0), rv() { } 
    406  
    407         mpdf ( const mpdf &m ) : dimc ( m.dimc ), rvc ( m.rvc ), dim( m.dim), rv( m.rv ) { } 
     405        pdf() : dimc ( 0 ), rvc(), dim(0), rv() { } 
     406 
     407        pdf ( const pdf &m ) : dimc ( m.dimc ), rvc ( m.rvc ), dim( m.dim), rv( m.rv ) { } 
    408408         
    409409        //! copy of the current object - make sure to implement 
    410         virtual mpdf* _copy_() const {return new mpdf(*this);} 
     410        virtual pdf* _copy_() const {return new pdf(*this);} 
    411411        //!@} 
    412412 
     
    467467        //! Load from structure with elements: 
    468468        //!  \code 
    469         //! { class = "mpdf_offspring", 
     469        //! { class = "pdf_offspring", 
    470470        //!   rv = {class="RV", names=(...),}; // RV describing meaning of random variable 
    471471        //!   rvc= {class="RV", names=(...),}; // RV describing meaning of random variable in condition 
     
    491491        //!@} 
    492492}; 
    493 SHAREDPTR ( mpdf ); 
     493SHAREDPTR ( pdf ); 
    494494 
    495495//! Probability density function with numerical statistics, e.g. posterior density. 
    496 class epdf : public mpdf { 
     496class epdf : public pdf { 
    497497 
    498498public: 
     
    509509        @{*/ 
    510510        epdf() {}; 
    511         epdf ( const epdf &e ) : mpdf(e) {}; 
     511        epdf ( const epdf &e ) : pdf(e) {}; 
    512512        void set_parameters ( int dim0 ) { 
    513513                dim = dim0; 
     
    542542 
    543543        //! Return conditional density on the given RV, the remaining rvs will be in conditioning 
    544         virtual shared_ptr<mpdf> condition ( const RV &rv ) const; 
     544        virtual shared_ptr<pdf> condition ( const RV &rv ) const; 
    545545 
    546546        //! Return marginal density on the given RV, the remainig rvs are intergrated out 
     
    633633SHAREDPTR ( epdf ); 
    634634 
    635 //! Mpdf with internal epdf that is modified by function \c condition 
     635//! pdf with internal epdf that is modified by function \c condition 
    636636template <class EPDF> 
    637 class mpdf_internal: public mpdf { 
     637class pdf_internal: public pdf { 
    638638protected : 
    639639        //! Internal epdf used for sampling 
     
    641641public: 
    642642        //! constructor 
    643         mpdf_internal() : mpdf(), iepdf() { 
     643        pdf_internal() : pdf(), iepdf() { 
    644644//              set_ep ( iepdf ); TODO! 
    645645        } 
    646646 
    647         //! Update \c iepdf so that it represents this mpdf conditioned on \c rvc = cond 
     647        //! Update \c iepdf so that it represents this pdf conditioned on \c rvc = cond 
    648648        //! This function provides convenient reimplementation in offsprings 
    649649        virtual void condition ( const vec &cond ) { 
     
    896896}; 
    897897 
    898 //!DataLink is a connection between mpdf and its superordinate (Up) 
     898//!DataLink is a connection between pdf and its superordinate (Up) 
    899899//! This class links 
    900900class datalink_m2m: public datalink_m2e { 
     
    928928 
    929929 
    930 //! \brief Combines RVs from a list of mpdfs to a single one. 
    931 RV get_composite_rv ( const Array<shared_ptr<mpdf> > &mpdfs, bool checkoverlap = false ); 
     930//! \brief Combines RVs from a list of pdfs to a single one. 
     931RV get_composite_rv ( const Array<shared_ptr<pdf> > &pdfs, bool checkoverlap = false ); 
    932932 
    933933/*! \brief Abstract class for discrete-time sources of data. 
     
    11181118        }; 
    11191119        //!Constructs conditional density of 1-step ahead predictor \f$ f(d_{t+1} |d_{t+h-1}, \ldots d_{t}) \f$ 
    1120         virtual mpdf* predictor() const { 
     1120        virtual pdf* predictor() const { 
    11211121                bdm_error ( "Not implemented" ); 
    11221122                return NULL; 
     
    12291229//! array of pointers to epdf 
    12301230typedef Array<shared_ptr<epdf> > epdf_array; 
    1231 //! array of pointers to mpdf 
    1232 typedef Array<shared_ptr<mpdf> > mpdf_array; 
     1231//! array of pointers to pdf 
     1232typedef Array<shared_ptr<pdf> > pdf_array; 
    12331233 
    12341234template<class EPDF> 
    1235 vec mpdf_internal<EPDF>::samplecond ( const vec &cond ) { 
     1235vec pdf_internal<EPDF>::samplecond ( const vec &cond ) { 
    12361236        condition ( cond ); 
    12371237        vec temp = iepdf.sample(); 
     
    12401240 
    12411241template<class EPDF> 
    1242 mat mpdf_internal<EPDF>::samplecond_m ( const vec &cond, int N ) { 
     1242mat pdf_internal<EPDF>::samplecond_m ( const vec &cond, int N ) { 
    12431243        condition ( cond ); 
    12441244        mat temp ( dimension(), N ); 
     
    12531253 
    12541254template<class EPDF> 
    1255 double mpdf_internal<EPDF>::evallogcond ( const vec &yt, const vec &cond ) { 
     1255double pdf_internal<EPDF>::evallogcond ( const vec &yt, const vec &cond ) { 
    12561256        double tmp; 
    12571257        condition ( cond ); 
     
    12611261 
    12621262template<class EPDF> 
    1263 vec mpdf_internal<EPDF>::evallogcond_m ( const mat &Yt, const vec &cond ) { 
     1263vec pdf_internal<EPDF>::evallogcond_m ( const mat &Yt, const vec &cond ) { 
    12641264        condition ( cond ); 
    12651265        return iepdf.evallog_m ( Yt ); 
     
    12671267 
    12681268template<class EPDF> 
    1269 vec mpdf_internal<EPDF>::evallogcond_m ( const Array<vec> &Yt, const vec &cond ) { 
     1269vec pdf_internal<EPDF>::evallogcond_m ( const Array<vec> &Yt, const vec &cond ) { 
    12701270        condition ( cond ); 
    12711271        return iepdf.evallog_m ( Yt );