Files
connor 8bc184a18c Release 0.2.0
Scalar is now num-dual's trait, blanket-implemented, rather than a
hand-rolled one declaring the same methods over a fixed list of types.

Breaking: the `autodiff` feature is gone, since num-dual is no longer
optional; `Scalar::re`, `exp`, `ln`, `log10`, `sqrt`, `sin`, `cos`,
`powi`, `powf`, `abs` and `powt` are gone, replaced by DualNum,
DualStruct and Signed, with `powt` now `powd`; and a call built only
from float literals must name its scalar, as gtd7d::<f64>(..).

Not breaking, but the reason it is worth doing: a caller's own dual type
is now covered automatically, and the dependency tree drops from about
twenty crates to two.
2026-10-02 19:41:50 -04:00

62 lines
2.2 KiB
TOML

[package]
name = "nrlmsise00"
version = "0.2.0"
edition = "2021"
authors = ["Connor Johnstone"]
description = "NRLMSISE-00 atmosphere model, generic over its scalar type so density can be differentiated"
readme = "readme.md"
repository = "https://git.rcjohnstone.com/connor/nrlmsise00"
license = "MIT"
# The oldest toolchain the crate is verified on here. Nothing in it needs anything newer
# than the 2021 edition and `core::array::from_fn`; the floor is likely lower, but lower is
# not tested.
rust-version = "1.89"
keywords = ["atmosphere", "density", "nrlmsise00", "aerospace", "thermosphere"]
categories = ["science", "aerospace"]
# The NRLMSIS 2.x port is a separate package under a separate, non-commercial
# license. It is not part of this one.
exclude = ["nrlmsis2", "scripts", "hooks", "plan.md"]
# docs.rs should document the `fast` feature and the drivers, not only the default build.
[package.metadata.docs.rs]
all-features = true
[workspace]
members = ["nrlmsis2"]
[features]
default = ["drivers"]
# The compiled-in solar and geomagnetic record, and date lookups into it.
drivers = []
# Trades the reference's exact bits for speed: the angle-sum identity for the expansions'
# phase-shifted cosines, and repeated squaring for the magnetic activity function's
# constant powers. Off by default. The readme states the measured agreement.
fast = []
[dependencies]
num-dual = { version = "0.15", default-features = false }
num-traits = { version = "0.2", default-features = false }
[dev-dependencies]
approx = "0.5"
criterion = "0.7"
# With default features, for the benchmark: it measures the vector dual types, which are
# the ones behind num-dual's nalgebra feature.
num-dual = "0.15"
# arbitrary_precision keeps each number's own digits, so a fixture value is parsed by
# str::parse rather than by serde_json's own float parser, which reads some f64s back one
# ulp high. The fixtures are compared bit for bit, so that one ulp is the difference
# between a passing and a failing test.
serde_json = { version = "1.0", features = ["arbitrary_precision"] }
[[bench]]
name = "density"
harness = false
# Measures the driver lookup as well as the model.
required-features = ["drivers"]
[[example]]
name = "density"
# Reads the compiled-in driver record.
required-features = ["drivers"]