Bayes Filters Library
ParticleSet.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2016-2019 Istituto Italiano di Tecnologia (IIT)
3  *
4  * This software may be modified and distributed under the terms of the
5  * BSD 3-Clause license. See the accompanying LICENSE file for details.
6  */
7 
8 #ifndef PARTICLESET_H
9 #define PARTICLESET_H
10 
12 
13 #include <vector>
14 
15 namespace bfl {
16  class ParticleSet;
17 }
18 
19 
21 {
22 public:
23  ParticleSet() noexcept;
24 
25  ParticleSet(const std::size_t components, const std::size_t dim) noexcept;
26 
27  ParticleSet(const std::size_t components, const std::size_t dim_linear, const std::size_t dim_circular, const bool use_quaternion = false) noexcept;
28 
29  virtual ~ParticleSet() noexcept = default;
30 
31  void resize(const std::size_t components, const std::size_t dim_linear, const std::size_t dim_circular = 0) override;
32 
33  ParticleSet& operator+=(const ParticleSet& rhs);
34 
35  Eigen::Ref<Eigen::MatrixXd> state();
36 
37  Eigen::Ref<Eigen::MatrixXd> state(const std::size_t i);
38 
39  double& state(const std::size_t i, const std::size_t j);
40 
41  const Eigen::Ref<const Eigen::MatrixXd> state() const;
42 
43  const Eigen::Ref<const Eigen::MatrixXd> state(const std::size_t i) const;
44 
45  const double& state(const std::size_t i, const std::size_t j) const;
46 
47 
48 protected:
49  Eigen::MatrixXd state_;
50 };
51 
52 
54 
55 #endif /* PARTICLESET_H */
bfl::ParticleSet::ParticleSet
ParticleSet() noexcept
Definition: ParticleSet.cpp:13
bfl::GaussianMixture::dim_circular
std::size_t dim_circular
Definition: GaussianMixture.h:77
bfl
Port of boost::any for C++11 compilers.
Definition: AdditiveMeasurementModel.h:13
bfl::GaussianMixture::components
std::size_t components
Definition: GaussianMixture.h:67
bfl::GaussianMixture::dim_linear
std::size_t dim_linear
Definition: GaussianMixture.h:75
bfl::ParticleSet::resize
void resize(const std::size_t components, const std::size_t dim_linear, const std::size_t dim_circular=0) override
Definition: ParticleSet.cpp:35
GaussianMixture.h
bfl::ParticleSet::~ParticleSet
virtual ~ParticleSet() noexcept=default
bfl::GaussianMixture::dim
std::size_t dim
Definition: GaussianMixture.h:73
operator+
bfl::ParticleSet operator+(bfl::ParticleSet lhs, const bfl::ParticleSet &rhs)
Definition: ParticleSet.cpp:76
bfl::GaussianMixture::use_quaternion
bool use_quaternion
Definition: GaussianMixture.h:69
bfl::ParticleSet::state_
Eigen::MatrixXd state_
Definition: ParticleSet.h:49
bfl::ParticleSet::state
Eigen::Ref< Eigen::MatrixXd > state()
Definition: ParticleSet.cpp:84
bfl::ParticleSet
Definition: ParticleSet.h:20
bfl::GaussianMixture
Definition: GaussianMixture.h:20
bfl::ParticleSet::operator+=
ParticleSet & operator+=(const ParticleSet &rhs)
Definition: ParticleSet.cpp:54