37 typedef boost::shared_ptr<GaussianDensity> shared_ptr;
48 throw std::invalid_argument(
"GaussianDensity can only be created from a conditional with no parents");
52 GaussianDensity(
Key key,
const Vector& d,
const Matrix& R,
const SharedDiagonal& noiseModel = SharedDiagonal()) :
56 static GaussianDensity FromMeanAndStddev(
Key key,
const Vector& mean,
const double& sigma);
59 void print(
const std::string& =
"GaussianDensity",
60 const KeyFormatter& formatter = DefaultKeyFormatter)
const;
66 Matrix covariance()
const;
A conditional Gaussian functions as the node in a Bayes network It has a set of parents y,...
Definition: GaussianConditional.h:36
Conditional Gaussian Base class.
void print(const Matrix &A, const string &s, ostream &stream)
print without optional string, must specify cout yourself
Definition: Matrix.cpp:141
A Gaussian density.
Definition: GaussianDensity.h:33
std::uint64_t Key
Integer nonlinear key type.
Definition: types.h:57
boost::function< std::string(Key)> KeyFormatter
Typedef for a function to format a key, i.e. to convert it to a string.
Definition: Key.h:33
GaussianDensity(Key key, const Vector &d, const Matrix &R, const SharedDiagonal &noiseModel=SharedDiagonal())
constructor using d, R
Definition: GaussianDensity.h:52
GaussianDensity(const GaussianConditional &conditional)
Copy constructor from GaussianConditional.
Definition: GaussianDensity.h:45
size_t nrParents() const
return the number of parents
Definition: Conditional.h:87
Global functions in a separate testing namespace.
Definition: chartTesting.h:28
GaussianDensity()
default constructor needed for serialization
Definition: GaussianDensity.h:40