diff -r 93daa824c04a -r 114ecdf63ce5 src/nalgebra_support.rs --- a/src/nalgebra_support.rs Wed Sep 03 17:59:24 2025 -0500 +++ b/src/nalgebra_support.rs Wed Sep 03 19:37:15 2025 -0500 @@ -222,64 +222,56 @@ } } -impl Mapping> for Matrix +impl Mapping> for Matrix where SM: Storage, - SV: Storage, N: Dim, M: Dim, K: Dim, E: Scalar + Zero + One + Copy + ClosedMulAssign + ClosedAddAssign, DefaultAllocator: Allocator + Allocator + Allocator, - ShapeConstraint: StridesOk + StridesOk + StridesOk, + ShapeConstraint: StridesOk + StridesOk + StridesOk, { type Codomain = OMatrix; #[inline] - fn apply>>(&self, x: I) -> Self::Codomain { + fn apply>>(&self, x: I) -> Self::Codomain { x.either(|owned| self.mul(owned), |refr| self.mul(refr)) } } -impl<'a, SM, SV, N, M, K, E> Linear> for Matrix +impl<'a, SM, N, M, K, E> Linear> for Matrix where SM: Storage, - SV: Storage, N: Dim, M: Dim, K: Dim, E: Scalar + Zero + One + Copy + ClosedMulAssign + ClosedAddAssign, DefaultAllocator: Allocator + Allocator + Allocator, - ShapeConstraint: StridesOk + StridesOk + StridesOk, + ShapeConstraint: StridesOk + StridesOk + StridesOk, { } -impl GEMV, Matrix> - for Matrix +impl GEMV, Matrix> for Matrix where SM: Storage, - SV1: Storage, SV2: StorageMut, N: Dim, M: Dim, K: Dim, E: Scalar + Zero + One + Float, DefaultAllocator: Allocator + Allocator + Allocator, - ShapeConstraint: StridesOk + StridesOk + StridesOk, + ShapeConstraint: StridesOk + StridesOk + StridesOk, { #[inline] - fn gemv>>( - &self, - y: &mut Matrix, - α: E, - x: I, - β: E, + fn gemv>>( + &self, y: &mut Matrix, α: E, x: I, β: E ) { x.eval(|x̃| Matrix::gemm(y, α, self, x̃, β)) } #[inline] - fn apply_mut<'a, I: Instance>>(&self, y: &mut Matrix, x: I) { + fn apply_mut<'a, I: Instance>>(&self, y: &mut Matrix, x: I) { x.eval(|x̃| self.mul_to(x̃, y)) } } @@ -381,21 +373,16 @@ } } -impl<'own, SV1, SV2, SM, N, M, K, E> Adjointable, Matrix> - for Matrix +impl<'own, SM, N, M, K, E> Adjointable, OMatrix> for Matrix where SM: Storage, - SV1: Storage + Clone, - SV2: Storage + Clone, N: Dim, M: Dim, K: Dim, E: Scalar + Zero + One + Copy + SimdComplexField, DefaultAllocator: Allocator + Allocator + Allocator + Allocator, - ShapeConstraint: StridesOk - + StridesOk - + StridesOk - + StridesOk, + ShapeConstraint: + StridesOk + StridesOk + StridesOk + StridesOk, { type AdjointCodomain = OMatrix; type Adjoint<'a>