changes
This commit is contained in:
parent
232f470ce1
commit
fa10dd64a4
4
TODO.md
4
TODO.md
@ -8,10 +8,12 @@
|
||||
- Non `y=` functions.
|
||||
3. Smart display of graph
|
||||
- Display of intersections between functions
|
||||
- Add docs about roots and extrema
|
||||
4. Fix integral line
|
||||
5. re-add euler's number (well it works if you use capital e like `E^x`)
|
||||
6. allow constants in min/max integral input (like pi or euler's number)
|
||||
7. sliding values for functions (like a user-interactable slider that adjusts a variable in the function, like desmos)
|
||||
8. Keybinds
|
||||
9. nth derivative support (again)
|
||||
10. add configs for toggling display of roots and extrema
|
||||
10. add configs for toggling display of roots and extrema
|
||||
11. reduce jittering of roots and extrema points
|
||||
@ -287,10 +287,10 @@ impl FunctionEntry {
|
||||
}
|
||||
|
||||
if last_ele.unwrap().y.signum() != ele.y.signum() {
|
||||
// Do 10 iterations of newton's method, should be more than accurate
|
||||
// Do 50 iterations of newton's method, should be more than accurate
|
||||
let x = {
|
||||
let mut x1: f64 = last_ele.unwrap().x;
|
||||
for _ in 0..10 {
|
||||
for _ in 0..50 {
|
||||
x1 = last_ele.unwrap().x
|
||||
- (self.function.get(x1) / self.function.derivative(x1))
|
||||
}
|
||||
@ -314,10 +314,10 @@ impl FunctionEntry {
|
||||
}
|
||||
|
||||
if last_ele.unwrap().y.signum() != ele.y.signum() {
|
||||
// Do 10 iterations of newton's method, should be more than accurate
|
||||
// Do 50 iterations of newton's method, should be more than accurate
|
||||
let x = {
|
||||
let mut x1: f64 = last_ele.unwrap().x;
|
||||
for _ in 0..10 {
|
||||
for _ in 0..50 {
|
||||
x1 = last_ele.unwrap().x
|
||||
- (self.function.derivative(x1) / self.function.get_derivative_2(x1))
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user