Skip to content

Commit

Permalink
RLSE: Ver 0.37.2
Browse files Browse the repository at this point in the history
- Do not include legend box if there is no legend (#58)
- Add rtol for Broyden method
- High-level macros for root finding
  • Loading branch information
Axect committed Apr 16, 2024
1 parent 703327f commit 2bf4c63
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 3 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.1"
version = "0.37.2"
authors = ["axect <[email protected]>"]
edition = "2018"
description = "Rust comprehensive scientific computation library contains linear algebra, numerical analysis, statistics and machine learning tools with farmiliar syntax"
Expand Down
10 changes: 10 additions & 0 deletions RELEASES.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,13 @@
# Release 0.37.2 (2024-04-16)

- Do not include legend box if there is no legend ([#58](https://github.com/Axect/Peroxide/pull/58)) (Thanks to [@GComitini](https://github.com/GComitini))
- Add `rtol` field to `BroydenMethod`
- Implement high-level macros for root finding
- `bisection!(f, (a,b), max_iter, tol)`
- `newton!(f, x0, max_iter, tol)` (require `#[ad_function]` attribute)
- `secant!(f, (a,b), max_iter, tol)`
- `false_position!(f, (a,b), max_iter, tol)`

# Release 0.37.1 (2024-04-15)

- Implement `BrodenMethod`: Broyden's method (`I>=1, O>=1, T=([f64; I], [f64; I])`)
Expand Down
2 changes: 1 addition & 1 deletion examples/broyden_test.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ use peroxide::numerical::root::{Pt, Intv};

fn main() -> Result<(), Box<dyn std::error::Error>> {
let problem = Quadratic;
let broyden = BroydenMethod { max_iter: 100, tol: 1e-6 };
let broyden = BroydenMethod { max_iter: 100, tol: 1e-6, rtol: 1e-6 };
let root = broyden.find(&problem)?;
let result = problem.function(root)?;

Expand Down
2 changes: 1 addition & 1 deletion src/numerical/root.rs
Original file line number Diff line number Diff line change
Expand Up @@ -781,7 +781,7 @@ impl RootFinder<1, 1, (f64, f64)> for FalsePositionMethod {
///
/// fn main() -> Result<(), Box<dyn std::error::Error>> {
/// let problem = CircleTangentLine;
/// let broyden = BroydenMethod { max_iter: 100, tol: 1e-6 };
/// let broyden = BroydenMethod { max_iter: 100, tol: 1e-6, rtol: 1e-6 };
///
/// let root = broyden.find(&problem)?;
/// let result = problem.function(root)?;
Expand Down

0 comments on commit 2bf4c63

Please sign in to comment.