Skip to content

Commit 923aca9

Browse files
Merge pull request #362 from nyx-space/deps/anise-0.4.3
Upgrade to anise 0.4.3
2 parents 63eab1e + ffeadd8 commit 923aca9

File tree

15 files changed

+160
-564
lines changed

15 files changed

+160
-564
lines changed

examples/01_orbit_prop/main.rs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,7 @@ fn main() -> Result<(), Box<dyn Error>> {
112112
crc32: Some(0xF446F027), // Specifying the CRC32 avoids redownloading it if it's cached.
113113
};
114114
// And let's download it if we don't have it yet.
115-
jgm3_meta.process()?;
115+
jgm3_meta.process(true)?;
116116

117117
// Build the spherical harmonics.
118118
// The harmonics must be computed in the body fixed frame.
@@ -237,6 +237,8 @@ fn main() -> Result<(), Box<dyn Error>> {
237237
let aer = almanac.azimuth_elevation_range_sez(
238238
state.orbit,
239239
boulder_station.to_orbit(this_epoch, &almanac)?,
240+
None,
241+
None,
240242
)?;
241243
azimuth_deg.push(aer.azimuth_deg);
242244
elevation_deg.push(aer.elevation_deg);

examples/02_jwst_covar_monte_carlo/main.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,13 +35,13 @@ fn main() -> Result<(), Box<dyn Error>> {
3535
uri: "https://naif.jpl.nasa.gov/pub/naif/JWST/kernels/spk/jwst_rec.bsp".to_string(),
3636
crc32: None,
3737
};
38-
latest_jwst_ephem.process()?;
38+
latest_jwst_ephem.process(true)?;
3939

4040
// Load this ephem in the general Almanac we're using for this analysis.
4141
let almanac = Arc::new(
4242
MetaAlmanac::latest()
4343
.map_err(Box::new)?
44-
.load_from_metafile(latest_jwst_ephem)?,
44+
.load_from_metafile(latest_jwst_ephem, true)?,
4545
);
4646

4747
// By loading this ephemeris file in the ANISE GUI or ANISE CLI, we can find the NAIF ID of the JWST

examples/03_geo_analysis/drift.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ fn main() -> Result<(), Box<dyn Error>> {
8282
crc32: Some(0xF446F027), // Specifying the CRC32 avoids redownloading it if it's cached.
8383
};
8484
// And let's download it if we don't have it yet.
85-
jgm3_meta.process()?;
85+
jgm3_meta.process(true)?;
8686

8787
// Build the spherical harmonics.
8888
// The harmonics must be computed in the body fixed frame.

examples/03_geo_analysis/raise.rs

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -12,10 +12,7 @@ use anise::{
1212
};
1313
use hifitime::{Epoch, TimeUnits, Unit};
1414
use nyx::{
15-
cosmic::{
16-
eclipse::{EclipseLocator, EclipseState},
17-
GuidanceMode, MetaAlmanac, Orbit, SrpConfig,
18-
},
15+
cosmic::{eclipse::EclipseLocator, GuidanceMode, MetaAlmanac, Orbit, SrpConfig},
1916
dynamics::{
2017
guidance::{GuidanceLaw, Ruggiero, Thruster},
2118
Harmonics, OrbitalDynamics, SolarPressure, SpacecraftDynamics,
@@ -75,8 +72,7 @@ fn main() -> Result<(), Box<dyn Error>> {
7572
];
7673

7774
// Ensure that we only thrust if we have more than 20% illumination.
78-
let ruggiero_ctrl =
79-
Ruggiero::from_max_eclipse(objectives, sc, EclipseState::Penumbra(0.2)).unwrap();
75+
let ruggiero_ctrl = Ruggiero::from_max_eclipse(objectives, sc, 0.2).unwrap();
8076
println!("{ruggiero_ctrl}");
8177

8278
// Define the high fidelity dynamics
@@ -94,7 +90,7 @@ fn main() -> Result<(), Box<dyn Error>> {
9490
crc32: Some(0xF446F027), // Specifying the CRC32 avoids redownloading it if it's cached.
9591
};
9692
// And let's download it if we don't have it yet.
97-
jgm3_meta.process()?;
93+
jgm3_meta.process(true)?;
9894

9995
// Build the spherical harmonics.
10096
// The harmonics must be computed in the body fixed frame.

examples/03_geo_analysis/stationkeeping.rs

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -12,10 +12,7 @@ use anise::{
1212
};
1313
use hifitime::{Epoch, TimeUnits, Unit};
1414
use nyx::{
15-
cosmic::{
16-
eclipse::{EclipseLocator, EclipseState},
17-
GuidanceMode, MetaAlmanac, Orbit, SrpConfig,
18-
},
15+
cosmic::{eclipse::EclipseLocator, GuidanceMode, MetaAlmanac, Orbit, SrpConfig},
1916
dynamics::{
2017
guidance::{Ruggiero, Thruster},
2118
Harmonics, OrbitalDynamics, SolarPressure, SpacecraftDynamics,
@@ -63,7 +60,7 @@ fn main() -> Result<(), Box<dyn Error>> {
6360
Objective::within_tolerance(StateParameter::Inclination, 0.05, 1e-2),
6461
];
6562

66-
let ruggiero_ctrl = Ruggiero::from_max_eclipse(objectives, sc, EclipseState::Penumbra(0.2))?;
63+
let ruggiero_ctrl = Ruggiero::from_max_eclipse(objectives, sc, 0.2)?;
6764
println!("{ruggiero_ctrl}");
6865

6966
let mut orbital_dyn = OrbitalDynamics::point_masses(vec![MOON, SUN]);
@@ -72,7 +69,7 @@ fn main() -> Result<(), Box<dyn Error>> {
7269
uri: "http://public-data.nyxspace.com/nyx/models/JGM3.cof.gz".to_string(),
7370
crc32: Some(0xF446F027), // Specifying the CRC32 avoids redownloading it if it's cached.
7471
};
75-
jgm3_meta.process()?;
72+
jgm3_meta.process(true)?;
7673

7774
let harmonics = Harmonics::from_stor(
7875
almanac.frame_from_uid(IAU_EARTH_FRAME)?,

examples/04_lro_od/main.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ fn main() -> Result<(), Box<dyn Error>> {
5050
// Load this ephem in the general Almanac we're using for this analysis.
5151
let mut almanac = MetaAlmanac::new(meta.to_string_lossy().to_string())
5252
.map_err(Box::new)?
53-
.process()
53+
.process(true)
5454
.map_err(Box::new)?;
5555

5656
let mut moon_pc = almanac.planetary_data.get_by_id(MOON)?;
@@ -120,7 +120,7 @@ fn main() -> Result<(), Box<dyn Error>> {
120120
crc32: Some(0x6bcacda8), // Specifying the CRC32 avoids redownloading it if it's cached.
121121
};
122122
// And let's download it if we don't have it yet.
123-
jggrx_meta.process()?;
123+
jggrx_meta.process(true)?;
124124

125125
// Build the spherical harmonics.
126126
// The harmonics must be computed in the body fixed frame.

0 commit comments

Comments
 (0)