Program Listing for File StandardPosVelAtt.hpp

Return to documentation for file (src/navtk/inertial/StandardPosVelAtt.hpp)

#pragma once

#include <navtk/aspn.hpp>
#include <navtk/factory.hpp>
#include <navtk/inertial/InertialPosVelAtt.hpp>
#include <navtk/linear_algebra.hpp>

namespace navtk {
namespace inertial {

class StandardPosVelAtt : public InertialPosVelAtt {
public:
    StandardPosVelAtt(
        const aspn_xtensor::TypeTimestamp& time = aspn_xtensor::TypeTimestamp((int64_t)0),
        Vector3 llh                             = zeros(3),
        Vector3 vned                            = zeros(3),
        Matrix3 C_s_to_ned                      = eye(3),
        AspnMessageType message_type            = ASPN_EXTENDED_BEGIN);

    StandardPosVelAtt(const aspn_xtensor::TypeTimestamp& time,
                      const std::tuple<Vector3, Vector3, Matrix3>& tup,
                      AspnMessageType message_type = ASPN_EXTENDED_BEGIN);

    std::shared_ptr<InertialPosVelAtt> clone() const override;

    Vector3 get_llh() const override;
    Vector3 get_vned() const override;
    Matrix3 get_C_s_to_ned() const override;

    std::pair<Matrix3, double> get_C_n_to_e_h() const override;

    Vector3 get_vn() const override;

    Matrix3 get_C_s_to_l() const override;

    std::pair<Matrix3, double> get_C_n_to_e_h(double wander) const;

    Vector3 get_vn(double wander) const;

    Matrix3 get_C_s_to_l(double wander) const;

    bool is_wander_capable() const override { return false; }

private:
    Vector3 llh;
    Vector3 vned;
    Matrix3 C_s_to_ned;
};

}  // namespace inertial
}  // namespace navtk