Skip to content

Commit

Permalink
v4.3.3
Browse files Browse the repository at this point in the history
  • Loading branch information
fraterenz committed Apr 4, 2024
1 parent 83b4add commit 18f5685
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 5 deletions.
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,12 @@
# Changelog
The semantic versioning is kind of random.

## 4.3.3
- create a new type for the probabilities
### BugFix
- saving timepoints when the simulations run for only 1 year
- remove the factor 2 for the fit variants introduced by `v4.2.0` (not clear why we shouldn't divide by 2)

## 4.3.2
### BugFix
- Do not multiply by tau when converting the rate per year into rate per division
Expand Down
2 changes: 1 addition & 1 deletion Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "hsc"
version = "4.3.2"
version = "4.3.3"
edition = "2021"

[dependencies]
Expand Down
4 changes: 1 addition & 3 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -87,21 +87,19 @@ impl Probs {
mu_division,
mu,
};
let mut u = mu / (cells as f32);
let u = mu / (cells as f32);
let probs = if (asymmetric - 0.).abs() > f32::EPSILON {
Probs::Asymmetric {
u,
probs_per_year,
asymmetric,
}
} else {
u *= 0.5;
Probs::Symmetric { u, probs_per_year }
};
if verbosity > 0 {
println!("probs {:#?}", probs);
}
dbg!(u);
assert!((0f32..1.).contains(&u), "Invalid u: u>=0 and u<1");
assert!(
(0f32..=1.).contains(&asymmetric),
Expand Down

0 comments on commit 18f5685

Please sign in to comment.