You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Average is good but, for an object with 0.1 and 0.9 you'd expect it to be on the lower end while with Average you get 0.5, with GeometricMean you get sqrt(0.1 * 0.9)=0.3
It feels more realistic. If the values are equal the result is the same, so 0.8 and 0.8 is 0.8. If one of the objects is perfectly inelastic the result is 0 as you are multiplying by 0 inside the square root; with Average, colliding with something perfectly inelastic would still result in a bounce but it's perfectly inelastic and shouldn't.
I tried to fork and make the changes but had trouble with the Cargo.toml, it's been a while since I've done Rust, so I couldn't see if doing (coeff1 * coeff2).sqrt() would work as the coefficients are crate::math::Reals and I'm obviously not making a pull request with untested code.
The text was updated successfully, but these errors were encountered:
Average is good but, for an object with 0.1 and 0.9 you'd expect it to be on the lower end while with Average you get 0.5, with GeometricMean you get sqrt(0.1 * 0.9)=0.3
It feels more realistic. If the values are equal the result is the same, so 0.8 and 0.8 is 0.8. If one of the objects is perfectly inelastic the result is 0 as you are multiplying by 0 inside the square root; with Average, colliding with something perfectly inelastic would still result in a bounce but it's perfectly inelastic and shouldn't.
I tried to fork and make the changes but had trouble with the Cargo.toml, it's been a while since I've done Rust, so I couldn't see if doing
(coeff1 * coeff2).sqrt()
would work as the coefficients arecrate::math::Real
s and I'm obviously not making a pull request with untested code.The text was updated successfully, but these errors were encountered: