Spacecraft Control Framework 1.0
Spacecraft Control Library
sc_beam_contour.h
Go to the documentation of this file.
1/*
2 * sc_beam_contour.h
3 * SCControl
4 *
5 * Created by Joseph Mueller on 1/29/13.
6 * Copyright 2013 Princeton Satellite Systems. All rights reserved.
7*/
8
14#ifndef SCControl_beam_contour_h
15#define SCControl_beam_contour_h
16
17#ifdef AS_OS_WINDOWS
18#include "matrixlib.h"
19#else
20#include <MatrixLib/MatrixLib.h>
21#endif
22
23
29{
30
31private:
32
33 // beam data
34 double lat0;
35 double lon0;
36 double alt0;
37 double beamWidth;
38 double azim;
39 double elev;
40
41 int nPts;
42 int nPts_2;
43 double Rp;
44
45 bool intersection;
46 bool partialHorizon;
47 bool fullHorizon;
48 ml_matrix rEFc;
49 ml_matrix latc;
50 ml_matrix lonc;
51
52public:
53
56
58 beam_contour(double lat0, double lon0, double alt0, double beamWidth);
59 beam_contour(double lat0, double lon0, double alt0, double beamWidth, double azim, double elev);
60
62 void update(double lat0, double lon0, double alt0, double beamWidth, double azim, double elev);
63
65 void update();
66
68 void rotateAxis( const ml_matrix& u, double roll, double pitch );
69
71 void rotateAxis(double lat0, double lon0, double alt0, double beamWidth, const ml_matrix& u, double roll, double pitch );
72
74 void point(double azim, double elev);
75
77 void move(double lat0, double lon0, double alt0);
78
80 void verify_inputs();
81
83 ml_matrix get_lat(){ return latc; };
84
86 ml_matrix get_lon(){ return lonc; };
87
89 ml_matrix get_r(){ return rEFc; };
90
92 ml_matrix* get_lat_ptr(){ return &latc; };
93
95 ml_matrix* get_lon_ptr(){ return &lonc; };
96
98 ml_matrix* get_r_ptr(){ return &rEFc; };
99
101 bool exist(){ return (intersection | partialHorizon | fullHorizon); };
102
104 bool horizon(){ return (partialHorizon | fullHorizon); };
105
106};
107
108#endif
Model beam contours.
Definition: sc_beam_contour.h:29
beam_contour()
Constructor.
Definition: sc_beam_contour.cc:21
void point(double azim, double elev)
point - recompute the contour with a new beam direction
Definition: sc_beam_contour.cc:121
bool horizon()
Return flag to say whether the contour has a horizon segment or not.
Definition: sc_beam_contour.h:104
ml_matrix * get_lon_ptr()
Get pointer to the longitude points of the beam contour.
Definition: sc_beam_contour.h:95
void update()
Update - recompute the contour with current data.
Definition: sc_beam_contour.cc:224
ml_matrix get_lat()
Get the latitude points of the beam contour.
Definition: sc_beam_contour.h:83
ml_matrix * get_r_ptr()
Get the Earth-fixed position points of the beam contour.
Definition: sc_beam_contour.h:98
bool exist()
Return flag to say whether the contour exists or not.
Definition: sc_beam_contour.h:101
ml_matrix get_lon()
Get the longitude points of the beam contour.
Definition: sc_beam_contour.h:86
ml_matrix * get_lat_ptr()
Get pointer to the latitude points of the beam contour.
Definition: sc_beam_contour.h:92
void move(double lat0, double lon0, double alt0)
Rotate - recompute the contour with a new beam direction.
Definition: sc_beam_contour.cc:212
void verify_inputs()
Verify inputs.
Definition: sc_beam_contour.cc:187
ml_matrix get_r()
Get the Earth-fixed position points of the beam contour.
Definition: sc_beam_contour.h:89
void rotateAxis(const ml_matrix &u, double roll, double pitch)
Rotate a body axis through roll, pitch. Zero angles result in +z body pointing down.
Definition: sc_beam_contour.cc:138