Commit 9d25e9e 1 parent 772dafa commit 9d25e9e Copy full SHA for 9d25e9e
File tree 1 file changed +5
-0
lines changed
1 file changed +5
-0
lines changed Original file line number Diff line number Diff line change @@ -200,9 +200,11 @@ impl<T: FloatLike> SquareMatrix<T> {
200
200
}
201
201
202
202
let mut q_transposed_inverse = SquareMatrix :: new_zeros ( self . dim ) ;
203
+ let mut q_transposed = SquareMatrix :: new_zeros ( self . dim ) ;
203
204
for row in 0 ..self . dim {
204
205
for col in 0 ..self . dim {
205
206
q_transposed_inverse[ ( row, col) ] = inverse_q[ ( col, row) ] ;
207
+ q_transposed[ ( row, col) ] = q[ ( col, row) ] ;
206
208
}
207
209
}
208
210
@@ -235,6 +237,7 @@ impl<T: FloatLike> SquareMatrix<T> {
235
237
determinant,
236
238
inverse,
237
239
q_transposed_inverse,
240
+ q_transposed,
238
241
} )
239
242
}
240
243
@@ -284,13 +287,15 @@ impl SquareMatrix<f128> {
284
287
pub struct DecompositionResult < T > {
285
288
pub determinant : T ,
286
289
pub inverse : SquareMatrix < T > ,
290
+ pub q_transposed : SquareMatrix < T > ,
287
291
pub q_transposed_inverse : SquareMatrix < T > ,
288
292
}
289
293
290
294
impl DecompositionResult < f128 > {
291
295
pub fn downcast ( & self ) -> DecompositionResult < f64 > {
292
296
DecompositionResult {
293
297
determinant : self . determinant . into ( ) ,
298
+ q_transposed : self . q_transposed . downcast ( ) ,
294
299
inverse : self . inverse . downcast ( ) ,
295
300
q_transposed_inverse : self . q_transposed_inverse . downcast ( ) ,
296
301
}
You can’t perform that action at this time.
0 commit comments