⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 pdf.hpp

📁 dysii是一款非常出色的滤波函数库
💻 HPP
字号:
#ifndef INDII_ML_AUX_PDF_HPP#define INDII_ML_AUX_PDF_HPP#include "vector.hpp"#include "matrix.hpp"namespace indii {  namespace ml {    namespace aux {/** * Abstract probability distribution. * * @author Lawrence Murray <lawrence@indii.org> * @version $Rev: 349 $ * @date $Date: 2007-11-20 20:48:40 +0000 (Tue, 20 Nov 2007) $ */class Pdf {public:  /**   * Destructor.   */  virtual ~Pdf();  /**   * Get the dimensionality of the distribution.   *   * @return Dimensionality of the distribution.   */  virtual unsigned int getDimensions() const = 0;  /**   * Set the dimensionality of the distribution.   *   * @param N Dimensionality of the distribution.   * @param preserve True to preserve the current sufficient   * statistics of the distribution in the lower dimensional space,   * false if these may be discarded.   */  virtual void setDimensions(const unsigned int N,      const bool preserve = false) = 0;  /**   * Get the expected value of the distribution.   *   * @return \f$\mathbf{\mu}\f$; expected value of the distribution.   */  virtual const vector& getExpectation() = 0;  /**   * Get the covariance of the distribution.   *   * @return \f$\Sigma\f$; covariance of the distribution.   */  virtual const symmetric_matrix& getCovariance() = 0;  /**   * Sample from the distribution.   *   * @return A sample from the distribution.   */  virtual vector sample() = 0;  /**   * Calculate the density at a given point.   *   * @param x \f$\mathbf{x}\f$; point at which to evaluate the   * density.   *   * @return \f$p(\mathbf{x})\f$; the density at \f$\mathbf{x}\f$.   */  virtual double densityAt(const vector& x) = 0;private:  /**   * Serialize, or restore from serialization.   */  template<class Archive>  void serialize(Archive& ar, const unsigned int version);  /*   * Boost.Serialization requirements.   */  friend class boost::serialization::access;};    }  }}template<class Archive>void indii::ml::aux::Pdf::serialize(Archive& ar, const unsigned int version) {  //}#endif

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -