当前位置: 首页 > news >正文

TH方程学习(1)

一、背景介绍

根据CW方程的学习,CW方程的限制条件为圆轨道,不考虑摄动,二者距离相对较小。TH方程则可以将物体间的相对运动推广到椭圆轨道的二体运动模型,本部分将结合STK的仿真功能,联合考察TH方程的有用性,参考<New State Transition Matrix for Relative Motion on an Aribitary Ellipitcal Orbit>这篇文章的案例,共同复现该论文的数据

二、STK案例

为了证明式子的有用性,首先使用STK仿真该相对运动的真实轨迹,作为检验模型正确性的关键。关于STK与matlab的调用,给出的代码如下,读者可自行验证

% 使用STK验证VVLH坐标系
clc;clear
uiApplication = actxGetRunningServer('STK12.application');
root = uiApplication.Personality2;
checkempty = root.Children.Count;
if checkempty ~= 0root.CurrentScenario.Unloadroot.CloseScenario;
end
root.NewScenario('VVLH');
StartTime = '26 Jan 2024 04:00:00.000';    % 场景开始时间
StopTime = '10 Feb 2024 04:00:00.000';     % 场景结束时间
root.ExecuteCommand(['SetAnalysisTimePeriod * "',StartTime,'" "',StopTime,'"']);
root.ExecuteCommand(' Animate * Reset');
SatName = 'Target';       %  SAR_   GX_   Sat_  GX_1_  SAR_1_
satellite = root.CurrentScenario.Children.New('eSatellite', SatName);
satellite.SetPropagatorType('ePropagatorAstrogator');   %  不设置的时候默认为二体模型  ePropagatorJ4Perturbation
satellite.Propagator;
Perigee=6378.137+500;
Ecc=0.1;
sma=Perigee/(1-Ecc);
Inc=30;
w=0;
RAAN=0;
TA=45;
root.ExecuteCommand(['Astrogator */Satellite/',SatName,' SetValue MainSequence.SegmentList Initial_State Propagate']);
InitialState=satellite.Propagator.MainSequence.Item(0);
%% 初始化卫星参数
root.ExecuteCommand(['Astrogator */Satellite/',SatName,' SetValue MainSequence.SegmentList.Initial_State.CoordinateType Modified Keplerian']);
root.ExecuteCommand(['Astrogator */Satellite/',SatName,' SetValue MainSequence.SegmentList.Initial_State.InitialState.Epoch ',StartTime,' UTCG']);
root.ExecuteCommand(['Astrogator */Satellite/',SatName,' SetValue MainSequence.SegmentList.Initial_State.InitialState.Keplerian.sma ',num2str(sma),' km']);
root.ExecuteCommand(['Astrogator */Satellite/',SatName,' SetValue MainSequence.SegmentList.Initial_State.InitialState.Keplerian.ecc ',num2str(Ecc)]);
root.ExecuteCommand(['Astrogator */Satellite/',SatName,' SetValue MainSequence.SegmentList.Initial_State.InitialState.Keplerian.inc ',num2str(Inc),' deg']);
root.ExecuteCommand(['Astrogator */Satellite/',SatName,' SetValue MainSequence.SegmentList.Initial_State.InitialState.Keplerian.w ',num2str(w),' deg']);
root.ExecuteCommand(['Astrogator */Satellite/',SatName,' SetValue MainSequence.SegmentList.Initial_State.InitialState.Keplerian.RAAN ',num2str(RAAN),' deg']);
root.ExecuteCommand(['Astrogator */Satellite/',SatName,' SetValue MainSequence.SegmentList.Initial_State.InitialState.Keplerian.TA ',num2str(TA),' deg']);
%% 二体传播
Propagate=satellite.Propagator.MainSequence.Item(1);
Propagate.PropagatorName='Earth Point Mass';
root.ExecuteCommand(['Astrogator */Satellite/',SatName,' RunMCS']);% 插入目标星
SatName2 = 'Chaser';       %  SAR_   GX_   Sat_  GX_1_  SAR_1_
satellite2 = root.CurrentScenario.Children.New('eSatellite', SatName2);
satellite2.SetPropagatorType('ePropagatorAstrogator');   %  不设置的时候默认为二体模型  ePropagatorJ4Perturbation
satellite2.Propagator;
InitialState2=satellite2.Propagator.MainSequence.Item(0);
InitialState2.CoordSystemName='Satellite/Target VVLH';
InitialState2.Element.X=0.1;
InitialState2.Element.Y=0.01;
InitialState2.Element.Z=0.01;
InitialState2.Element.Vx=0.0001;
InitialState2.Element.Vy=0.0001;
InitialState2.Element.Vz=0.0001;
Propagate2=satellite2.Propagator.MainSequence.Item(1);
Propagate2.PropagatorName='Earth Point Mass';
root.ExecuteCommand(['Astrogator */Satellite/',SatName2,' RunMCS']);% 报告二颗卫星的三维关系
satellite.VO.OrbitSystems.InertialByWindow.IsVisible=0;
satellite2.VO.OrbitSystems.InertialByWindow.IsVisible=0;
satellite2.VO.OrbitSystems.Add('Satellite/Target VVLH System')
satellite.VO.Vector.RefCrdns.Item(2).Visible=1;targetdata=root.ExecuteCommand(['Report_RM */Satellite/Target  Style "VVLH" TimePeriod "26 Jan 2024 04:00:00.000" "26 Jan 2024 16:00:00.000" TimeStep 60']);
Num=targetdata.Count;
for j=1:Num-2struct=regexp(targetdata.Item(j),',','split');Tar_x(j)=str2double(struct{2});Tar_y(j)=str2double(struct{3});Tar_z(j)=str2double(struct{4});
end
%
figure(1)
plot(Tar_x(1:220),Tar_z(1:220));
axis([-3.5 0.5 -0.6 0.3])
set(gca,'XDir','reverse');
set(gca,'YDir','reverse');
grid on

这里需要额外注意VVLH报告在STK不是自带的,需要自己去定义,操作步骤右击目标星的Report & Graph Manager —— Create new report style —— 命名为VVLH —— 内容如下图所示

最后呈现的是XZ平面的相对位置

http://www.lryc.cn/news/357588.html

相关文章:

  • 【九十七】【算法分析与设计】图论,迷宫,1207. 大臣的旅费,走出迷宫,石油采集,after与迷宫,逃离迷宫,3205. 最优配餐,路径之谜
  • 【Tools】SpringBoot工程中,对于时间属性从后端返回到前端的格式问题
  • 算法训练营day35
  • 代码随想录-Day23
  • 基于Visual Studio版本的AI编程助手
  • 04-Vue:ref获取页面节点--很简单
  • CBK-D2-安全与架构工程.md
  • Windows驱动开发系列文章一
  • java项目之人事系统源码(springboot+vue+mysql)
  • I/O '24|学习资源焕新,技术灵感升级
  • 前端应用开发实验:表单控件绑定
  • [双指针] --- 快乐数 盛最多水的容器
  • 操作系统 - 输入/输出(I/O)管理
  • 代码随想录算法训练营第22天(py)| 二叉树 | 669. 修剪二叉搜索树、108.将有序数组转换为二叉搜索树、538.把二叉搜索树转换为累加树
  • 使用C语言实现学生信息管理系统
  • 上下文视觉提示实现zero-shot分割检测及多visual-prompt改造
  • WebGL学习(一)渲染关系
  • 人生建议:向猫学习
  • 软件架构设计属性之三:结构性属性浅析
  • JAVA:多线程常见的面试题和答案
  • 短信平台-平台群发短信
  • C++:类和对象
  • JavaScript条件语句与逻辑判断:解锁代码逻辑的奥秘【含代码示例】
  • sparksql自定义函数
  • 新人开发新系统,旧人维护旧系统
  • 鸿蒙应用模型:【Stage模型开发】概述
  • java使用jdbcTemplatep批量插入数据
  • K8s service 进阶
  • CompletableFuture详细讲解
  • 【Linux】初识Linux和Linux环境配置