gtsam  4.0.0
gtsam
TOAFactor.h
Go to the documentation of this file.
1 /* ----------------------------------------------------------------------------
2 
3  * GTSAM Copyright 2010, Georgia Tech Research Corporation,
4  * Atlanta, Georgia 30332-0415
5  * All Rights Reserved
6  * Authors: Frank Dellaert, et al. (see THANKS for the full author list)
7 
8  * See LICENSE for the license information
9 
10  * -------------------------------------------------------------------------- */
11 
20 #include <gtsam/nonlinear/ExpressionFactor.h>
21 #include <gtsam_unstable/geometry/Event.h>
22 
23 namespace gtsam {
24 
26 class TOAFactor: public ExpressionFactor<double> {
27 
29 
30 public:
31 
39  TOAFactor(const Expression<Event>& eventExpression,
40  const Expression<Point3>& microphone_, double toaMeasurement,
41  const SharedNoiseModel& model) :
42  ExpressionFactor<double>(model, toaMeasurement,
43  Double_(&Event::toa, eventExpression, microphone_)) {
44  }
45 
46 };
47 
48 } //\ namespace gtsam
49 
A "Time of Arrival" factor - so little code seems hardly worth it :-)
Definition: TOAFactor.h:26
TOAFactor(const Expression< Event > &eventExpression, const Expression< Point3 > &microphone_, double toaMeasurement, const SharedNoiseModel &model)
Constructor.
Definition: TOAFactor.h:39
Factor that supports arbitrary expressions via AD.
Definition: Expression.h:38
Global functions in a separate testing namespace.
Definition: chartTesting.h:28
noiseModel::Base::shared_ptr SharedNoiseModel
Note, deliberately not in noiseModel namespace.
Definition: NoiseModel.h:1072