🛰️航天仿真算法库 SpaceAST 0.4.0
载入中...
搜索中...
未找到
BlendingAtmosphere.hpp
浏览该文件的文档.
1
20
21#pragma once
22
23#include "AstGlobal.h"
24#include "AtmosphereBase.hpp"
25#include "AstUtil/ScopedPtr.hpp"
26
27AST_NAMESPACE_BEGIN
28
38constexpr double kDefaultBlendAltitude = 100e3;
39
40
46class AST_CORE_API BlendingAtmosphere : public Atmosphere
47{
48public:
54 BlendingAtmosphere(Atmosphere* mainModel, Atmosphere* lowAltModel, double blendAltitude, double blendRange);
55
56 BlendingAtmosphere(Atmosphere* mainModel, Atmosphere* lowAltModel);
57
58 ~BlendingAtmosphere() override = default;
59
60public: // 重载行为
61 double getDensity(const TimePoint& tp, const Vector3d& posInBodyFixed) const override;
62 Frame* getFrame() const override;
63 BodyShape* getShape() const override;
64public:
66 Atmosphere* mainModel() const { return mainModel_; }
67 void setMainModel(Atmosphere* mainModel) { mainModel_ = mainModel; }
68
70 Atmosphere* lowAltModel() const { return lowAltModel_; }
71 void setLowAltModel(Atmosphere* lowAltModel) { lowAltModel_ = lowAltModel; }
72
74 double blendAltitude() const { return blendAltitude_; }
75 void setBlendAltitude(double blendAltitude) { blendAltitude_ = blendAltitude; }
76
78 double blendRange() const { return blendRange_; }
79 void setBlendRange(double blendRange) { blendRange_ = blendRange; }
80private:
81 ScopedPtr<Atmosphere> mainModel_{};
82 ScopedPtr<Atmosphere> lowAltModel_{};
83 double blendAltitude_{kDefaultBlendAltitude};
84 double blendRange_{0.0};
85};
86
87
90AST_NAMESPACE_END
大气模型基类
定义 Atmosphere.hpp:48
virtual Frame * getFrame() const =0
获取大气模型的参考坐标系
virtual BodyShape * getShape() const
获取大气模型对应的天体形状
定义 Atmosphere.cpp:28
virtual double getDensity(const TimePoint &tp, const Vector3d &posInBodyFixed) const =0
获取大气密度
主/低高度大气密度模型的混合过渡模型
定义 BlendingAtmosphere.hpp:47
double blendRange() const
过渡带宽度
定义 BlendingAtmosphere.hpp:78
double blendAltitude() const
过渡带中心高度
定义 BlendingAtmosphere.hpp:74
Atmosphere * lowAltModel() const
低高度大气模型
定义 BlendingAtmosphere.hpp:70
Atmosphere * mainModel() const
主(高高度)大气模型
定义 BlendingAtmosphere.hpp:66
天体形状基类
定义 BodyShape.hpp:33
坐标系抽象基类
定义 Frame.hpp:74
绝对时间点
定义 TimePoint.hpp:109
constexpr double kDefaultBlendAltitude
主/低高度大气模型的过渡带中心高度默认值
定义 BlendingAtmosphere.hpp:38