diff --git a/src/function_entry.rs b/src/function_entry.rs index 6a32672..e44921c 100644 --- a/src/function_entry.rs +++ b/src/function_entry.rs @@ -43,7 +43,7 @@ pub struct FunctionEntry { /// If displaying derivatives are enabled (note, they are still calculated for other purposes) pub derivative: bool, - pub nth_derviative: bool, + pub nth_derivative: bool, pub back_data: Vec, pub integral_data: Option<(Vec, f64)>, @@ -64,7 +64,7 @@ impl Hash for FunctionEntry { fn hash(&self, state: &mut H) { self.raw_func_str.hash(state); self.integral.hash(state); - self.nth_derviative.hash(state); + self.nth_derivative.hash(state); self.curr_nth.hash(state); self.settings_opened.hash(state); } @@ -128,7 +128,7 @@ impl Default for FunctionEntry { raw_func_str: String::new(), integral: false, derivative: false, - nth_derviative: false, + nth_derivative: false, back_data: Vec::new(), integral_data: None, derivative_data: Vec::new(), @@ -157,7 +157,7 @@ impl FunctionEntry { .collapsible(false) .show(ctx, |ui| { ui.add(Checkbox::new( - &mut self.nth_derviative, + &mut self.nth_derivative, "Display Nth Derivative", )); @@ -324,7 +324,7 @@ impl FunctionEntry { debug_assert_eq!(self.derivative_data.len(), settings.plot_width + 1); } - if self.nth_derviative && self.nth_derivative_data.is_none() { + if self.nth_derivative && self.nth_derivative_data.is_none() { let data = self.generate_plot_data(self.curr_nth, &resolution_iter); debug_assert_eq!(data.len(), settings.plot_width + 1); self.nth_derivative_data = Some(data); @@ -434,10 +434,10 @@ impl FunctionEntry { ); } - if self.nth_derviative - && let Some(ref nth_derviative) = self.nth_derivative_data + if self.nth_derivative + && let Some(ref nth_derivative) = self.nth_derivative_data { - plot_ui.line(nth_derviative.clone().to_line().color(Color32::DARK_RED)); + plot_ui.line(nth_derivative.clone().to_line().color(Color32::DARK_RED)); } // Plot integral data