Fix compilation after rebase.
This commit is contained in:
parent
d17088398a
commit
35ec135d2c
|
@ -30,10 +30,10 @@
|
|||
|
||||
-----
|
||||
|
||||
## Gold sponsors
|
||||
## Platinum sponsors
|
||||
Rapier is supported by:
|
||||
<p>
|
||||
<a href="https://embark-studios.com">
|
||||
<img src="https://www.embark.dev/img/logo_black.png" width="301px">
|
||||
<img src="https://www.embark.dev/img/logo_black.png" width="401px">
|
||||
</a>
|
||||
</p>
|
||||
|
|
|
@ -20,9 +20,11 @@ use typenum::{self, Cmp, Greater};
|
|||
use simba::scalar::{ClosedAdd, ClosedMul};
|
||||
|
||||
use crate::base::allocator::Allocator;
|
||||
use crate::base::dimension::{Const, Dim, DimName, Dynamic, ToTypenum, U1, U2, U3, U4, U5, U6};
|
||||
use crate::base::dimension::{Dim, DimName, Dynamic, ToTypenum};
|
||||
use crate::base::storage::Storage;
|
||||
use crate::base::{DefaultAllocator, Matrix, MatrixMN, MatrixN, Scalar, Unit, Vector, VectorN};
|
||||
use crate::base::{
|
||||
Const, DefaultAllocator, Matrix, MatrixMN, MatrixN, Scalar, Unit, Vector, VectorN,
|
||||
};
|
||||
|
||||
/// When "no_unsound_assume_init" is enabled, expands to `unimplemented!()` instead of `new_uninitialized_generic().assume_init()`.
|
||||
/// Intended as a placeholder, each callsite should be refactored to use uninitialized memory soundly
|
||||
|
@ -210,9 +212,9 @@ where
|
|||
/// m.m31 == 7.0 && m.m32 == 8.0 && m.m33 == 9.0);
|
||||
/// ```
|
||||
#[inline]
|
||||
pub fn from_rows<SB>(rows: &[Matrix<N, U1, C, SB>]) -> Self
|
||||
pub fn from_rows<SB>(rows: &[Matrix<N, Const<1>, C, SB>]) -> Self
|
||||
where
|
||||
SB: Storage<N, U1, C>,
|
||||
SB: Storage<N, Const<1>, C>,
|
||||
{
|
||||
assert!(!rows.is_empty(), "At least one row must be given.");
|
||||
let nrows = R::try_to_usize().unwrap_or_else(|| rows.len());
|
||||
|
@ -878,10 +880,10 @@ where
|
|||
*
|
||||
*/
|
||||
macro_rules! componentwise_constructors_impl(
|
||||
($($R: ty, $C: ty, $($args: ident:($irow: expr,$icol: expr)),*);* $(;)*) => {$(
|
||||
impl<N> MatrixMN<N, $R, $C>
|
||||
($($R: expr, $C: expr, $($args: ident:($irow: expr,$icol: expr)),*);* $(;)*) => {$(
|
||||
impl<N> MatrixMN<N, Const<$R>, Const<$C>>
|
||||
where N: Scalar,
|
||||
DefaultAllocator: Allocator<N, $R, $C> {
|
||||
DefaultAllocator: Allocator<N, Const<$R>, Const<$C>> {
|
||||
/// Initializes this matrix from its components.
|
||||
#[inline]
|
||||
pub fn new($($args: N),*) -> Self {
|
||||
|
@ -903,21 +905,21 @@ componentwise_constructors_impl!(
|
|||
/*
|
||||
* Square matrices 1 .. 6.
|
||||
*/
|
||||
U2, U2, m11:(0,0), m12:(0,1),
|
||||
2, 2, m11:(0,0), m12:(0,1),
|
||||
m21:(1,0), m22:(1,1);
|
||||
U3, U3, m11:(0,0), m12:(0,1), m13:(0,2),
|
||||
3, 3, m11:(0,0), m12:(0,1), m13:(0,2),
|
||||
m21:(1,0), m22:(1,1), m23:(1,2),
|
||||
m31:(2,0), m32:(2,1), m33:(2,2);
|
||||
U4, U4, m11:(0,0), m12:(0,1), m13:(0,2), m14:(0,3),
|
||||
4, 4, m11:(0,0), m12:(0,1), m13:(0,2), m14:(0,3),
|
||||
m21:(1,0), m22:(1,1), m23:(1,2), m24:(1,3),
|
||||
m31:(2,0), m32:(2,1), m33:(2,2), m34:(2,3),
|
||||
m41:(3,0), m42:(3,1), m43:(3,2), m44:(3,3);
|
||||
U5, U5, m11:(0,0), m12:(0,1), m13:(0,2), m14:(0,3), m15:(0,4),
|
||||
5, 5, m11:(0,0), m12:(0,1), m13:(0,2), m14:(0,3), m15:(0,4),
|
||||
m21:(1,0), m22:(1,1), m23:(1,2), m24:(1,3), m25:(1,4),
|
||||
m31:(2,0), m32:(2,1), m33:(2,2), m34:(2,3), m35:(2,4),
|
||||
m41:(3,0), m42:(3,1), m43:(3,2), m44:(3,3), m45:(3,4),
|
||||
m51:(4,0), m52:(4,1), m53:(4,2), m54:(4,3), m55:(4,4);
|
||||
U6, U6, m11:(0,0), m12:(0,1), m13:(0,2), m14:(0,3), m15:(0,4), m16:(0,5),
|
||||
6, 6, m11:(0,0), m12:(0,1), m13:(0,2), m14:(0,3), m15:(0,4), m16:(0,5),
|
||||
m21:(1,0), m22:(1,1), m23:(1,2), m24:(1,3), m25:(1,4), m26:(1,5),
|
||||
m31:(2,0), m32:(2,1), m33:(2,2), m34:(2,3), m35:(2,4), m36:(2,5),
|
||||
m41:(3,0), m42:(3,1), m43:(3,2), m44:(3,3), m45:(3,4), m46:(3,5),
|
||||
|
@ -927,47 +929,47 @@ componentwise_constructors_impl!(
|
|||
/*
|
||||
* Rectangular matrices with 2 rows.
|
||||
*/
|
||||
U2, U3, m11:(0,0), m12:(0,1), m13:(0,2),
|
||||
2, 3, m11:(0,0), m12:(0,1), m13:(0,2),
|
||||
m21:(1,0), m22:(1,1), m23:(1,2);
|
||||
U2, U4, m11:(0,0), m12:(0,1), m13:(0,2), m14:(0,3),
|
||||
2, 4, m11:(0,0), m12:(0,1), m13:(0,2), m14:(0,3),
|
||||
m21:(1,0), m22:(1,1), m23:(1,2), m24:(1,3);
|
||||
U2, U5, m11:(0,0), m12:(0,1), m13:(0,2), m14:(0,3), m15:(0,4),
|
||||
2, 5, m11:(0,0), m12:(0,1), m13:(0,2), m14:(0,3), m15:(0,4),
|
||||
m21:(1,0), m22:(1,1), m23:(1,2), m24:(1,3), m25:(1,4);
|
||||
U2, U6, m11:(0,0), m12:(0,1), m13:(0,2), m14:(0,3), m15:(0,4), m16:(0,5),
|
||||
2, 6, m11:(0,0), m12:(0,1), m13:(0,2), m14:(0,3), m15:(0,4), m16:(0,5),
|
||||
m21:(1,0), m22:(1,1), m23:(1,2), m24:(1,3), m25:(1,4), m26:(1,5);
|
||||
|
||||
/*
|
||||
* Rectangular matrices with 3 rows.
|
||||
*/
|
||||
U3, U2, m11:(0,0), m12:(0,1),
|
||||
3, 2, m11:(0,0), m12:(0,1),
|
||||
m21:(1,0), m22:(1,1),
|
||||
m31:(2,0), m32:(2,1);
|
||||
U3, U4, m11:(0,0), m12:(0,1), m13:(0,2), m14:(0,3),
|
||||
3, 4, m11:(0,0), m12:(0,1), m13:(0,2), m14:(0,3),
|
||||
m21:(1,0), m22:(1,1), m23:(1,2), m24:(1,3),
|
||||
m31:(2,0), m32:(2,1), m33:(2,2), m34:(2,3);
|
||||
U3, U5, m11:(0,0), m12:(0,1), m13:(0,2), m14:(0,3), m15:(0,4),
|
||||
3, 5, m11:(0,0), m12:(0,1), m13:(0,2), m14:(0,3), m15:(0,4),
|
||||
m21:(1,0), m22:(1,1), m23:(1,2), m24:(1,3), m25:(1,4),
|
||||
m31:(2,0), m32:(2,1), m33:(2,2), m34:(2,3), m35:(2,4);
|
||||
U3, U6, m11:(0,0), m12:(0,1), m13:(0,2), m14:(0,3), m15:(0,4), m16:(0,5),
|
||||
3, 6, m11:(0,0), m12:(0,1), m13:(0,2), m14:(0,3), m15:(0,4), m16:(0,5),
|
||||
m21:(1,0), m22:(1,1), m23:(1,2), m24:(1,3), m25:(1,4), m26:(1,5),
|
||||
m31:(2,0), m32:(2,1), m33:(2,2), m34:(2,3), m35:(2,4), m36:(2,5);
|
||||
|
||||
/*
|
||||
* Rectangular matrices with 4 rows.
|
||||
*/
|
||||
U4, U2, m11:(0,0), m12:(0,1),
|
||||
4, 2, m11:(0,0), m12:(0,1),
|
||||
m21:(1,0), m22:(1,1),
|
||||
m31:(2,0), m32:(2,1),
|
||||
m41:(3,0), m42:(3,1);
|
||||
U4, U3, m11:(0,0), m12:(0,1), m13:(0,2),
|
||||
4, 3, m11:(0,0), m12:(0,1), m13:(0,2),
|
||||
m21:(1,0), m22:(1,1), m23:(1,2),
|
||||
m31:(2,0), m32:(2,1), m33:(2,2),
|
||||
m41:(3,0), m42:(3,1), m43:(3,2);
|
||||
U4, U5, m11:(0,0), m12:(0,1), m13:(0,2), m14:(0,3), m15:(0,4),
|
||||
4, 5, m11:(0,0), m12:(0,1), m13:(0,2), m14:(0,3), m15:(0,4),
|
||||
m21:(1,0), m22:(1,1), m23:(1,2), m24:(1,3), m25:(1,4),
|
||||
m31:(2,0), m32:(2,1), m33:(2,2), m34:(2,3), m35:(2,4),
|
||||
m41:(3,0), m42:(3,1), m43:(3,2), m44:(3,3), m45:(3,4);
|
||||
U4, U6, m11:(0,0), m12:(0,1), m13:(0,2), m14:(0,3), m15:(0,4), m16:(0,5),
|
||||
4, 6, m11:(0,0), m12:(0,1), m13:(0,2), m14:(0,3), m15:(0,4), m16:(0,5),
|
||||
m21:(1,0), m22:(1,1), m23:(1,2), m24:(1,3), m25:(1,4), m26:(1,5),
|
||||
m31:(2,0), m32:(2,1), m33:(2,2), m34:(2,3), m35:(2,4), m36:(2,5),
|
||||
m41:(3,0), m42:(3,1), m43:(3,2), m44:(3,3), m45:(3,4), m46:(3,5);
|
||||
|
@ -975,22 +977,22 @@ componentwise_constructors_impl!(
|
|||
/*
|
||||
* Rectangular matrices with 5 rows.
|
||||
*/
|
||||
U5, U2, m11:(0,0), m12:(0,1),
|
||||
5, 2, m11:(0,0), m12:(0,1),
|
||||
m21:(1,0), m22:(1,1),
|
||||
m31:(2,0), m32:(2,1),
|
||||
m41:(3,0), m42:(3,1),
|
||||
m51:(4,0), m52:(4,1);
|
||||
U5, U3, m11:(0,0), m12:(0,1), m13:(0,2),
|
||||
5, 3, m11:(0,0), m12:(0,1), m13:(0,2),
|
||||
m21:(1,0), m22:(1,1), m23:(1,2),
|
||||
m31:(2,0), m32:(2,1), m33:(2,2),
|
||||
m41:(3,0), m42:(3,1), m43:(3,2),
|
||||
m51:(4,0), m52:(4,1), m53:(4,2);
|
||||
U5, U4, m11:(0,0), m12:(0,1), m13:(0,2), m14:(0,3),
|
||||
5, 4, m11:(0,0), m12:(0,1), m13:(0,2), m14:(0,3),
|
||||
m21:(1,0), m22:(1,1), m23:(1,2), m24:(1,3),
|
||||
m31:(2,0), m32:(2,1), m33:(2,2), m34:(2,3),
|
||||
m41:(3,0), m42:(3,1), m43:(3,2), m44:(3,3),
|
||||
m51:(4,0), m52:(4,1), m53:(4,2), m54:(4,3);
|
||||
U5, U6, m11:(0,0), m12:(0,1), m13:(0,2), m14:(0,3), m15:(0,4), m16:(0,5),
|
||||
5, 6, m11:(0,0), m12:(0,1), m13:(0,2), m14:(0,3), m15:(0,4), m16:(0,5),
|
||||
m21:(1,0), m22:(1,1), m23:(1,2), m24:(1,3), m25:(1,4), m26:(1,5),
|
||||
m31:(2,0), m32:(2,1), m33:(2,2), m34:(2,3), m35:(2,4), m36:(2,5),
|
||||
m41:(3,0), m42:(3,1), m43:(3,2), m44:(3,3), m45:(3,4), m46:(3,5),
|
||||
|
@ -999,25 +1001,25 @@ componentwise_constructors_impl!(
|
|||
/*
|
||||
* Rectangular matrices with 6 rows.
|
||||
*/
|
||||
U6, U2, m11:(0,0), m12:(0,1),
|
||||
6, 2, m11:(0,0), m12:(0,1),
|
||||
m21:(1,0), m22:(1,1),
|
||||
m31:(2,0), m32:(2,1),
|
||||
m41:(3,0), m42:(3,1),
|
||||
m51:(4,0), m52:(4,1),
|
||||
m61:(5,0), m62:(5,1);
|
||||
U6, U3, m11:(0,0), m12:(0,1), m13:(0,2),
|
||||
6, 3, m11:(0,0), m12:(0,1), m13:(0,2),
|
||||
m21:(1,0), m22:(1,1), m23:(1,2),
|
||||
m31:(2,0), m32:(2,1), m33:(2,2),
|
||||
m41:(3,0), m42:(3,1), m43:(3,2),
|
||||
m51:(4,0), m52:(4,1), m53:(4,2),
|
||||
m61:(5,0), m62:(5,1), m63:(5,2);
|
||||
U6, U4, m11:(0,0), m12:(0,1), m13:(0,2), m14:(0,3),
|
||||
6, 4, m11:(0,0), m12:(0,1), m13:(0,2), m14:(0,3),
|
||||
m21:(1,0), m22:(1,1), m23:(1,2), m24:(1,3),
|
||||
m31:(2,0), m32:(2,1), m33:(2,2), m34:(2,3),
|
||||
m41:(3,0), m42:(3,1), m43:(3,2), m44:(3,3),
|
||||
m51:(4,0), m52:(4,1), m53:(4,2), m54:(4,3),
|
||||
m61:(5,0), m62:(5,1), m63:(5,2), m64:(5,3);
|
||||
U6, U5, m11:(0,0), m12:(0,1), m13:(0,2), m14:(0,3), m15:(0,4),
|
||||
6, 5, m11:(0,0), m12:(0,1), m13:(0,2), m14:(0,3), m15:(0,4),
|
||||
m21:(1,0), m22:(1,1), m23:(1,2), m24:(1,3), m25:(1,4),
|
||||
m31:(2,0), m32:(2,1), m33:(2,2), m34:(2,3), m35:(2,4),
|
||||
m41:(3,0), m42:(3,1), m43:(3,2), m44:(3,3), m45:(3,4),
|
||||
|
@ -1027,21 +1029,21 @@ componentwise_constructors_impl!(
|
|||
/*
|
||||
* Row vectors 1 .. 6.
|
||||
*/
|
||||
U1, U1, x:(0,0);
|
||||
U1, U2, x:(0,0), y:(0,1);
|
||||
U1, U3, x:(0,0), y:(0,1), z:(0,2);
|
||||
U1, U4, x:(0,0), y:(0,1), z:(0,2), w:(0,3);
|
||||
U1, U5, x:(0,0), y:(0,1), z:(0,2), w:(0,3), a:(0,4);
|
||||
U1, U6, x:(0,0), y:(0,1), z:(0,2), w:(0,3), a:(0,4), b:(0,5);
|
||||
1, 1, x:(0,0);
|
||||
1, 2, x:(0,0), y:(0,1);
|
||||
1, 3, x:(0,0), y:(0,1), z:(0,2);
|
||||
1, 4, x:(0,0), y:(0,1), z:(0,2), w:(0,3);
|
||||
1, 5, x:(0,0), y:(0,1), z:(0,2), w:(0,3), a:(0,4);
|
||||
1, 6, x:(0,0), y:(0,1), z:(0,2), w:(0,3), a:(0,4), b:(0,5);
|
||||
|
||||
/*
|
||||
* Column vectors 1 .. 6.
|
||||
*/
|
||||
U2, U1, x:(0,0), y:(1,0);
|
||||
U3, U1, x:(0,0), y:(1,0), z:(2,0);
|
||||
U4, U1, x:(0,0), y:(1,0), z:(2,0), w:(3,0);
|
||||
U5, U1, x:(0,0), y:(1,0), z:(2,0), w:(3,0), a:(4,0);
|
||||
U6, U1, x:(0,0), y:(1,0), z:(2,0), w:(3,0), a:(4,0), b:(5,0);
|
||||
2, 1, x:(0,0), y:(1,0);
|
||||
3, 1, x:(0,0), y:(1,0), z:(2,0);
|
||||
4, 1, x:(0,0), y:(1,0), z:(2,0), w:(3,0);
|
||||
5, 1, x:(0,0), y:(1,0), z:(2,0), w:(3,0), a:(4,0);
|
||||
6, 1, x:(0,0), y:(1,0), z:(2,0), w:(3,0), a:(4,0), b:(5,0);
|
||||
);
|
||||
|
||||
/*
|
||||
|
|
|
@ -37,7 +37,7 @@ impl<N: Scalar, const R: usize, const C: usize> Allocator<N, Const<R>, Const<C>>
|
|||
type Buffer = ArrayStorage<N, R, C>;
|
||||
|
||||
#[inline]
|
||||
unsafe fn allocate_uninitialized(_: R, _: C) -> mem::MaybeUninit<Self::Buffer> {
|
||||
unsafe fn allocate_uninitialized(_: Const<R>, _: Const<C>) -> mem::MaybeUninit<Self::Buffer> {
|
||||
mem::MaybeUninit::<Self::Buffer>::uninit()
|
||||
}
|
||||
|
||||
|
@ -146,12 +146,13 @@ where
|
|||
rto: Const<RTO>,
|
||||
cto: Const<CTO>,
|
||||
buf: <Self as Allocator<N, RFrom, CFrom>>::Buffer,
|
||||
) -> ArrayStorage<N, RTo, CTo> {
|
||||
) -> ArrayStorage<N, RTO, CTO> {
|
||||
#[cfg(feature = "no_unsound_assume_init")]
|
||||
let mut res: ArrayStorage<N, RTo, CTo> = unimplemented!();
|
||||
let mut res: ArrayStorage<N, RTO, CTO> = unimplemented!();
|
||||
#[cfg(not(feature = "no_unsound_assume_init"))]
|
||||
let mut res =
|
||||
<Self as Allocator<N, RTo, CTo>>::allocate_uninitialized(rto, cto).assume_init();
|
||||
<Self as Allocator<N, Const<RTO>, Const<CTO>>>::allocate_uninitialized(rto, cto)
|
||||
.assume_init();
|
||||
|
||||
let (rfrom, cfrom) = buf.shape();
|
||||
|
||||
|
|
|
@ -17,7 +17,7 @@ use simba::simd::SimdPartialOrd;
|
|||
use crate::base::allocator::Allocator;
|
||||
use crate::base::dimension::{DimName, DimNameAdd, DimNameSum, U1};
|
||||
use crate::base::iter::{MatrixIter, MatrixIterMut};
|
||||
use crate::base::{DefaultAllocator, Scalar, VectorN};
|
||||
use crate::base::{Const, DefaultAllocator, Scalar, VectorN};
|
||||
|
||||
/// A point in an euclidean space.
|
||||
///
|
||||
|
@ -202,7 +202,7 @@ where
|
|||
let mut res = unsafe {
|
||||
crate::unimplemented_or_uninitialized_generic!(
|
||||
<DimNameSum<D, U1> as DimName>::name(),
|
||||
U1
|
||||
Const::<1>
|
||||
)
|
||||
};
|
||||
res.fixed_slice_mut::<D, U1>(0, 0).copy_from(&self.coords);
|
||||
|
|
|
@ -12,8 +12,8 @@ use crate::base::allocator::Allocator;
|
|||
use crate::base::dimension::{DimName, DimNameAdd, DimNameSum, U1};
|
||||
use crate::base::{DefaultAllocator, Scalar, VectorN};
|
||||
use crate::{
|
||||
Point1, Point2, Point3, Point4, Point5, Point6, Vector1, Vector2, Vector3, Vector4, Vector5,
|
||||
Vector6,
|
||||
Const, Point1, Point2, Point3, Point4, Point5, Point6, Vector1, Vector2, Vector3, Vector4,
|
||||
Vector5, Vector6,
|
||||
};
|
||||
use simba::scalar::{ClosedDiv, SupersetOf};
|
||||
|
||||
|
@ -29,7 +29,7 @@ where
|
|||
pub unsafe fn new_uninitialized() -> Self {
|
||||
Self::from(crate::unimplemented_or_uninitialized_generic!(
|
||||
D::name(),
|
||||
U1
|
||||
Const::<1>
|
||||
))
|
||||
}
|
||||
|
||||
|
|
|
@ -3,9 +3,9 @@ use num::Zero;
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::allocator::{Allocator, Reallocator};
|
||||
use crate::base::{DefaultAllocator, Matrix, MatrixMN, MatrixN, Unit, VectorN};
|
||||
use crate::base::{Const, DefaultAllocator, Matrix, MatrixMN, MatrixN, Unit, VectorN};
|
||||
use crate::constraint::{SameNumberOfRows, ShapeConstraint};
|
||||
use crate::dimension::{Dim, DimMin, DimMinimum, U1};
|
||||
use crate::dimension::{Dim, DimMin, DimMinimum};
|
||||
use crate::storage::{Storage, StorageMut};
|
||||
use crate::ComplexField;
|
||||
|
||||
|
@ -67,7 +67,7 @@ where
|
|||
let mut p = PermutationSequence::identity_generic(min_nrows_ncols);
|
||||
|
||||
let mut diag =
|
||||
unsafe { crate::unimplemented_or_uninitialized_generic!(min_nrows_ncols, U1) };
|
||||
unsafe { crate::unimplemented_or_uninitialized_generic!(min_nrows_ncols, Const::<1>) };
|
||||
|
||||
if min_nrows_ncols.value() == 0 {
|
||||
return ColPivQR {
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::allocator::Allocator;
|
||||
use crate::base::{DefaultAllocator, MatrixMN, MatrixN, VectorN};
|
||||
use crate::base::{DefaultAllocator, MatrixN, VectorN};
|
||||
use crate::dimension::{Const, DimDiff, DimSub, U1};
|
||||
use crate::storage::Storage;
|
||||
use simba::scalar::ComplexField;
|
||||
|
@ -61,9 +61,12 @@ where
|
|||
"Unable to compute the symmetric tridiagonal decomposition of an empty matrix."
|
||||
);
|
||||
|
||||
let mut off_diagonal =
|
||||
unsafe { crate::unimplemented_or_uninitialized_generic!(dim.sub(Const::<1>), Const::<1>) };
|
||||
let mut p = unsafe { crate::unimplemented_or_uninitialized_generic!(dim.sub(Const::<1>), Const::<1>) };
|
||||
let mut off_diagonal = unsafe {
|
||||
crate::unimplemented_or_uninitialized_generic!(dim.sub(Const::<1>), Const::<1>)
|
||||
};
|
||||
let mut p = unsafe {
|
||||
crate::unimplemented_or_uninitialized_generic!(dim.sub(Const::<1>), Const::<1>)
|
||||
};
|
||||
|
||||
for i in 0..dim.value() - 1 {
|
||||
let mut m = m.rows_range_mut(i + 1..);
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::allocator::Allocator;
|
||||
use crate::base::{DefaultAllocator, MatrixN, VectorN, U1};
|
||||
use crate::base::{Const, DefaultAllocator, MatrixN, VectorN};
|
||||
use crate::dimension::Dim;
|
||||
use crate::storage::Storage;
|
||||
use simba::scalar::RealField;
|
||||
|
@ -52,7 +52,7 @@ where
|
|||
let n = p.ncols();
|
||||
let n_dim = p.data.shape().1;
|
||||
|
||||
let mut d = VectorN::zeros_generic(n_dim, U1);
|
||||
let mut d = VectorN::zeros_generic(n_dim, Const::<1>);
|
||||
let mut u = MatrixN::zeros_generic(n_dim, n_dim);
|
||||
|
||||
d[n - 1] = p[(n - 1, n - 1)];
|
||||
|
|
Loading…
Reference in New Issue