WarpTwin
Documentation for WarpTwin models and classes.
Loading...
Searching...
No Matches
OccultationModel.h
Go to the documentation of this file.
1/******************************************************************************
2* Copyright (c) ATTX INC 2025. All Rights Reserved.
3*
4* This software and associated documentation (the "Software") are the
5* proprietary and confidential information of ATTX INC. The Software is
6* furnished under a license agreement between ATTX and the user organization
7* and may be used or copied only in accordance with the terms of the agreement.
8* Refer to 'license/attx_license.adoc' for standard license terms.
9*
10* EXPORT CONTROL NOTICE: THIS SOFTWARE MAY INCLUDE CONTENT CONTROLLED UNDER THE
11* INTERNATIONAL TRAFFIC IN ARMS REGULATIONS (ITAR) OR THE EXPORT ADMINISTRATION
12* REGULATIONS (EAR99). No part of the Software may be used, reproduced, or
13* transmitted in any form or by any means, for any purpose, without the express
14* written permission of ATTX INC.
15******************************************************************************/
16/*
17Occultation model header file
18
19Author: Alex Jackson
20*/
21/*
22Metadata for MS GUI:
23imdata = {"displayname" : "Occultation",
24 "exclude" : False,
25 "category" : "Environment"
26}
27aliases = {"r_s" : "Source Object Radius",
28 "r_oc" : "Occulting Object Radius",
29 "pos_ob__f" : "Observer Position",
30 "pos_oc__f" : "Occulting Object Position",
31 "pos_s__f" : "Source Position",
32 "occ_frac" : "Visibility Fraction",
33}
34*/
35
36#ifndef MODELS_ENVIRONMENT_OCCULTATION_MODEL_H
37#define MODELS_ENVIRONMENT_OCCULTATION_MODEL_H
38
39#include "simulation/Model.h"
40#include "frames/Frame.h"
41#include "frames/Node.h"
42#include "frames/frameutils.h"
44
45
46namespace warptwin {
47
48
56 MODEL(OccultationModel)
57 public:
58 // Model params
59 // NAME TYPE DEFAULT VALUE
61 /* This is the radius of the source object. If the object is not spherical,
62 * a representative radius should be used. The default is zero radius (point)
63 */
64 SIGNAL(r_s, double, 0.0)
65 /* This is the radius of the occulting object. If the object is not spherical,
66 * a representative radius should be used. The default is zero radius (point)
67 */
68 SIGNAL(r_oc, double, 0.0)
70
71 // Model inputs
72 // NAME TYPE DEFAULT VALUE
75 SIGNAL(pos_ob__f, CartesianVector3, CartesianVector3({0.0, 0.0, 0.0}))
77 SIGNAL(pos_oc__f, CartesianVector3, CartesianVector3({0.0, 0.0, 0.0}))
79 SIGNAL(pos_s__f, CartesianVector3, CartesianVector3({0.0, 0.0, 0.0}))
81
82 // Model outputs
83 // NAME TYPE DEFAULT VALUE
88 SIGNAL(occ_frac, double, 1.0)
90
91 protected:
92 int16 execute() override;
93
94 // Temporary vectors and variables to carry out our calculations
95 double _a_i;
96 double _d;
97 double _d_1;
98 double _d_2;
99 double _d_e;
100 double _d_i;
101 double _d_o;
102 double _theta;
103 double _tmp;
104 double _tmp1;
105 double _tmp2;
106 double _tmp3;
107 double _tmp4;
108 double _tmp5;
111 };
112
113}
114
115#endif
#define SIGNAL(NAME, TYPE, INITIAL_VALUE)
Definition appmacros.h:27
#define START_PARAMS
Definition appmacros.h:42
#define END_OUTPUTS
Definition appmacros.h:33
#define END_PARAMS
Definition appmacros.h:47
#define START_OUTPUTS
Definition appmacros.h:28
#define END_INPUTS
Definition appmacros.h:40
#define START_INPUTS
Definition appmacros.h:35
#define CartesianVector3
Definition mathmacros.h:43
Class to propagate CR3BP dynamics in characteristic units.
Definition statistics.hpp:22
double _tmp5
Definition OccultationModel.h:108
CartesianVector3 _tmpvec
Definition OccultationModel.h:110
SIGNAL(_mu, double, warpos::earth_wgs84.mu)
double _d_2
Definition OccultationModel.h:98
clockwerk::CartesianVector< 3 > _tmp
Definition CR3BPDynamicsModel.h:116
double _theta
Misalignment angle magnitude and unit vector.
Definition TorqueCoilModel.h:147
double _tmp1
Definition OccultationModel.h:104
double _d_1
Definition OccultationModel.h:97
double _d_o
Definition OccultationModel.h:101
double _tmp2
Definition OccultationModel.h:105
double _tmp4
Definition OccultationModel.h:107
double _tmp3
Definition OccultationModel.h:106
double _d
Definition OccultationModel.h:96
@ MODEL
Simplified dynamics model representing motion in the circular restricted 3 body problem.
Definition ImNode.h:31
MODEL(OccultationModel) public double _a_i
Occultation model using spherical representations of objects.
Definition OccultationModel.h:56
CartesianVector3 _s_ob_vec
Definition OccultationModel.h:109
double _d_i
Definition OccultationModel.h:100
double _d_e
Definition OccultationModel.h:99
int16 execute() override
Function to check monitor input conditions and set trigger flag accordingly. Should be implemented in...