Skip to content

Commit

Permalink
Ver 0.37.4
Browse files Browse the repository at this point in the history
- Public ODE Integrator fields
  • Loading branch information
Axect committed May 17, 2024
2 parents d6665b7 + 6d47249 commit e4a811a
Show file tree
Hide file tree
Showing 3 changed files with 36 additions and 25 deletions.
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "peroxide"
version = "0.37.3"
version = "0.37.4"
authors = ["axect <axect@outlook.kr>"]
edition = "2018"
description = "Rust comprehensive scientific computation library contains linear algebra, numerical analysis, statistics and machine learning tools with farmiliar syntax"
Expand Down
4 changes: 4 additions & 0 deletions RELEASES.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# Release 0.37.4 (2024-05-17)

- Public ODE Integrator fields

# Release 0.37.3 (2024-05-01)

- Add Nan/infinite guard to `gauss_kronrod_quadrature` (early exit) ([#59](https://github.com/Axect/Peroxide/pull/59)) (Thanks to [@GComitini](https://github.com/GComitini))
Expand Down
55 changes: 31 additions & 24 deletions src/numerical/ode.rs
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,14 @@
//! use peroxide::fuga::*;
//!
//! fn main() -> Result<(), Box<dyn Error>> {
//! let rkf = RKF45::new(1e-4, 0.9, 1e-6, 1e-1, 100);
//! // Same as : let rkf = RKF45::new(1e-4, 0.9, 1e-6, 1e-1, 100);
//! let rkf = RKF45 {
//! tol: 1e-6,
//! safety_factor: 0.9,
//! min_step_size: 1e-6,
//! max_step_size: 1e-1,
//! max_step_iter: 100,
//! };
//! let basic_ode_solver = BasicODESolver::new(rkf);
//! let (t_vec, y_vec) = basic_ode_solver.solve(
//! &Test,
Expand Down Expand Up @@ -438,11 +445,11 @@ impl ButcherTableau for RK5 {
#[derive(Debug, Clone, Copy)]
#[cfg_attr(feature = "serde", derive(serde::Serialize, serde::Deserialize))]
pub struct BS23 {
tol: f64,
safety_factor: f64,
min_step_size: f64,
max_step_size: f64,
max_step_iter: usize,
pub tol: f64,
pub safety_factor: f64,
pub min_step_size: f64,
pub max_step_size: f64,
pub max_step_iter: usize,
}

impl Default for BS23 {
Expand Down Expand Up @@ -492,11 +499,11 @@ impl ButcherTableau for BS23 {
#[derive(Debug, Clone, Copy)]
#[cfg_attr(feature = "serde", derive(serde::Serialize, serde::Deserialize))]
pub struct RKF45 {
tol: f64,
safety_factor: f64,
min_step_size: f64,
max_step_size: f64,
max_step_iter: usize,
pub tol: f64,
pub safety_factor: f64,
pub min_step_size: f64,
pub max_step_size: f64,
pub max_step_iter: usize,
}

impl Default for RKF45 {
Expand Down Expand Up @@ -558,11 +565,11 @@ impl ButcherTableau for RKF45 {
#[derive(Debug, Clone, Copy)]
#[cfg_attr(feature = "serde", derive(serde::Serialize, serde::Deserialize))]
pub struct DP45 {
tol: f64,
safety_factor: f64,
min_step_size: f64,
max_step_size: f64,
max_step_iter: usize,
pub tol: f64,
pub safety_factor: f64,
pub min_step_size: f64,
pub max_step_size: f64,
pub max_step_iter: usize,
}

impl Default for DP45 {
Expand Down Expand Up @@ -629,11 +636,11 @@ impl ButcherTableau for DP45 {
#[derive(Debug, Clone, Copy)]
#[cfg_attr(feature = "serde", derive(serde::Serialize, serde::Deserialize))]
pub struct TSIT45 {
tol: f64,
safety_factor: f64,
min_step_size: f64,
max_step_size: f64,
max_step_iter: usize,
pub tol: f64,
pub safety_factor: f64,
pub min_step_size: f64,
pub max_step_size: f64,
pub max_step_iter: usize,
}

impl Default for TSIT45 {
Expand Down Expand Up @@ -718,9 +725,9 @@ pub enum ImplicitSolver {
#[derive(Debug, Clone, Copy)]
#[cfg_attr(feature = "serde", derive(serde::Serialize, serde::Deserialize))]
pub struct GL4 {
solver: ImplicitSolver,
tol: f64,
max_step_iter: usize,
pub solver: ImplicitSolver,
pub tol: f64,
pub max_step_iter: usize,
}

impl Default for GL4 {
Expand Down

0 comments on commit e4a811a

Please sign in to comment.