forum.alglib.net
http://forum.alglib.net/

Ask about data structures
http://forum.alglib.net/viewtopic.php?f=2&t=3951
Page 1 of 1

Author:  Alex69 [ Thu Mar 14, 2019 8:02 pm ]
Post subject:  Ask about data structures

Sorry fo my English

I need

I need to get a product of the form L 'M L, where M is the matrix, L L' is the decomposition of Cholesky of another symmetric matrix W.

It is recommended to use spdmatrixcholesky to obtain Cholesky decomposition. The input is real_2d_array W.
As I understood, it is necessary to specify isUpper = false.

spdmatrixcholesky(W,nVars,false);

In this case, the input matrix W will be converted (in place) to W', the lower part of which will contain a triangular matrix of decomposition of Cholesky L from W, the upper part of W does not change.

According to the documentation, I assume that I can immediately use such a "mixed matrix" (bottom - result, top - the rest of the original data) in operations with matrices. For example, to multiply M left by L', I have to make a call

rmatrixlefttrsm(nVars,nVars,W',0,0,false,true,1,M,0,0);

expecting the matrix W' (contains at the bottom of L from W) to be transposed, the resulting l' will be multiplied by M and the result will be stored in M.

In this case, the upper part of the matrix W' (after transposition - the lower) does not participate in the process and its contents do not affect the result. I don't have to clean it, etc.

Do I understand the documentation correctly?

Page 1 of 1 All times are UTC
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
http://www.phpbb.com/