Прототип страницы расчета ПУУД
This commit is contained in:
+77
@@ -163,6 +163,83 @@ class AngularMotionCalculatorSmokeTest {
|
||||
}
|
||||
|
||||
|
||||
@Test
|
||||
fun chekSDI(){
|
||||
val ballistics = Ballistics()
|
||||
val t = LocalDateTime.of(2023, 4, 12, 17, 41, 18, 0)
|
||||
val ic = InitialConditions(
|
||||
OrbitalPoint(
|
||||
fromDateTime(t),
|
||||
1,
|
||||
Vector3D(
|
||||
-3101926.630,
|
||||
6018678.8,
|
||||
0.0,
|
||||
),
|
||||
Vector3D(
|
||||
1287.651,
|
||||
663.634,
|
||||
7612.951,
|
||||
),
|
||||
),
|
||||
0.005,
|
||||
160.0
|
||||
)
|
||||
val result = ballistics.calculateOrbPoints(
|
||||
ic,
|
||||
ic.point.t,
|
||||
ic.point.t + 86400 * 10
|
||||
)
|
||||
assertEquals(result, BallisticsError.OK)
|
||||
if (result != BallisticsError.OK)
|
||||
return
|
||||
val stepper = ballistics.getStepper()
|
||||
assert(stepper != null)
|
||||
if (stepper == null)
|
||||
return
|
||||
val calculator = SmoothSDIPUUD(stepper, EarthType.PZ90d02)
|
||||
val id = SurveyId(
|
||||
oep = listOf(false, false, false, true),
|
||||
t = fromDateTime(LocalDateTime.of(2023, 4, 16, 3, 48, 22, 0)),
|
||||
b = 49.25824 * PI / 180,
|
||||
l = 153.65914 * PI / 180,
|
||||
h = 0.0,
|
||||
duration = 69.0,
|
||||
sdi = listOf(30.0),
|
||||
azimuth = 25.567 * PI / 180,
|
||||
uprAngle = 6.0 * PI / 180,
|
||||
pointInCenter = false
|
||||
)
|
||||
val rc = calculator.calculate(id)
|
||||
|
||||
println(rc.mode)
|
||||
println(rc.points.size)
|
||||
println(rc.startTime)
|
||||
|
||||
for (v in rc.points) {
|
||||
println(
|
||||
String.format(
|
||||
Locale.US,
|
||||
"%s %.3f %.3f %.3f , %s %s , %.7f %.7f %.7f , %.7f %.7f %.7f , %.3f",
|
||||
toDateTime(v.t).format(outputTimeFormatter),
|
||||
v.orientation.tang * 180 / PI,
|
||||
v.orientation.kren * 180 / PI,
|
||||
v.orientation.risk * 180 / PI,
|
||||
v.groundPoint?.let { String.format(Locale.US, "%.3f", it.lat * 180 / PI) },
|
||||
v.groundPoint?.let { String.format(Locale.US, "%.3f", it.long * 180 / PI) },
|
||||
v.omega.x,
|
||||
v.omega.y,
|
||||
v.omega.z,
|
||||
v.wd.x,
|
||||
v.wd.y,
|
||||
v.wd.z,
|
||||
v.sdi
|
||||
)
|
||||
)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@Test
|
||||
fun chekAzimuth(){
|
||||
val ballistics = Ballistics()
|
||||
|
||||
Reference in New Issue
Block a user