WSF
MTT_EmbryonicTrack.hpp
Go to the documentation of this file.
1// ****************************************************************************
2// CUI//REL TO USA ONLY
3//
4// The Advanced Framework for Simulation, Integration, and Modeling (AFSIM)
5//
6// Copyright 2003-2015 The Boeing Company. All rights reserved.
7//
8// The use, dissemination or disclosure of data in this file is subject to
9// limitation or restriction. See accompanying README and LICENSE for details.
10// ****************************************************************************
11
12#ifndef MTT_EMBRYONIC_TRACK_HPP
13#define MTT_EMBRYONIC_TRACK_HPP
14
15#include <fstream>
16#include <string>
17
18#include "MTT_Track.hpp"
19#include "SupBlock.hpp"
20#include "UtMatrix.hpp"
21
24{
25public:
26 class Data : public MTT_Track::Data
27 {
28 public:
30 : mErrorInfoMatrix(4, 4)
34 {
35 }
36
37 MTT_Track::Data* Clone() const override { return new Data(*this); }
38
39 ~Data() override {}
40 // Suppressor offset (385 block, same as 386)
41 UtMatrixd mErrorInfoMatrix; // 0-31 (4x4 = 16 doubles)
42 UtMatrixd mHorizontalState; // 32-39 (4x1 = 4 doubles)
43 UtMatrixd mVerticalErrorInfoMatrix; // 40-47 (2x2 = 4 doubles)
44 UtMatrixd mVerticalState; // 48-51 (2x1 = 2 doubles)
45
46 void ConvertFrom(const SupBlock& aBlock) override
47 {
48 mErrorInfoMatrix.CopyFrom(aBlock.mDoubleBlock + 0); // 0-31 (4x4 = 16 doubles)
49 mHorizontalState.CopyFrom(aBlock.mDoubleBlock + 16); // 32-39 (4x1 = 4 doubles)
50 mVerticalErrorInfoMatrix.CopyFrom(aBlock.mDoubleBlock + 20); // 40-47 (2x2 = 4 doubles)
51 mVerticalState.CopyFrom(aBlock.mDoubleBlock + 24); // 48-51 (2x1 = 2 doubles)
52 }
53
54 void Log(std::fstream& aFS) override
55 {
56 aFS << mErrorInfoMatrix << std::endl;
57 aFS << mHorizontalState << std::endl;
58 aFS << mVerticalErrorInfoMatrix << std::endl;
59 aFS << mVerticalState << std::endl;
60 }
61 };
62
63public:
65
67 : MTT_Track(aSrc)
68 {
69 }
70
71 ~MTT_EmbryonicTrack() override {}
72
73 void SetData(const Data& aData)
74 {
75 if (mDataPtr != nullptr)
76 {
77 delete mDataPtr;
78 }
79 mDataPtr = new Data(aData);
80 }
81
83};
84
85#endif
Definition MTT_EmbryonicTrack.hpp:27
UtMatrixd mErrorInfoMatrix
Definition MTT_EmbryonicTrack.hpp:41
Data()
Definition MTT_EmbryonicTrack.hpp:29
UtMatrixd mVerticalState
Definition MTT_EmbryonicTrack.hpp:44
MTT_Track::Data * Clone() const override
Definition MTT_EmbryonicTrack.hpp:37
void ConvertFrom(const SupBlock &aBlock) override
Definition MTT_EmbryonicTrack.hpp:46
~Data() override
Definition MTT_EmbryonicTrack.hpp:39
UtMatrixd mHorizontalState
Definition MTT_EmbryonicTrack.hpp:42
void Log(std::fstream &aFS) override
Definition MTT_EmbryonicTrack.hpp:54
UtMatrixd mVerticalErrorInfoMatrix
Definition MTT_EmbryonicTrack.hpp:43
MTT_EmbryonicTrack(const MTT_EmbryonicTrack &aSrc)
Definition MTT_EmbryonicTrack.hpp:66
~MTT_EmbryonicTrack() override
Definition MTT_EmbryonicTrack.hpp:71
MTT_EmbryonicTrack()
Definition MTT_EmbryonicTrack.hpp:64
MTT_EmbryonicTrack::Data & GetData() const
Definition MTT_EmbryonicTrack.hpp:82
void SetData(const Data &aData)
Definition MTT_EmbryonicTrack.hpp:73
Definition MTT_Track.hpp:26
MTT_Track()
Definition MTT_Track.hpp:35
Data * mDataPtr
Definition MTT_Track.hpp:67
Definition SupBlock.hpp:21
double * mDoubleBlock
Definition SupBlock.hpp:46
Copyrights Multiple, All Rights Reserved