From 034ed617c9bb3340ffe485a567ac60634fc444ea Mon Sep 17 00:00:00 2001 From: Hanno Braun Date: Fri, 21 Mar 2025 22:43:47 +0100 Subject: [PATCH] Reduce reliance on `nalgebra` --- crates/fj-math/src/vector.rs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/crates/fj-math/src/vector.rs b/crates/fj-math/src/vector.rs index 9cd32535d..322df46ba 100644 --- a/crates/fj-math/src/vector.rs +++ b/crates/fj-math/src/vector.rs @@ -374,7 +374,9 @@ where type Output = Self; fn div(self, scalar: S) -> Self::Output { - self.to_na().div(scalar.into().into_f64()).into() + let scalar = scalar.into(); + let components = self.components.map(|component| component / scalar); + Self { components } } }