novacrazy / dual_num

Dual Number library for Rust
https://docs.rs/dual_num/
17 stars 4 forks source link

Fix log2 function #13

Closed benruijl closed 5 years ago

benruijl commented 5 years ago

This doesn't look quite right :wink:

fn log2(self) -> Self {
    Dual::new(self.real().log10(), self.dual() / (self.real() * T::LN_2()))
}