Solving matrix equation in Matlab,

Hi Matlab,
I'm currently doing research on macroeconomic variables; hence attempting to solve an matrix equation in Matlab ( see attached photo, marked with yellow (following VECM Analysis in JMulTi July 5, 2005, page 26). Does anyone know to calculate the value for sigma (marked with yellow)?
I haven't attached a code, since, at the moment, don't know how to calculate it in Matlab, hence any help greatly appreciated!
Best regards,

 Risposta accettata

Chuguang Pan
Chuguang Pan il 7 Mar 2024

0 voti

Using vectorization operator vec, which transfer a matrix to a column vector through stacking matrix's columns vertically. There is a useful equation in this context.
, where represents kronecker product.
The matrix equation can be converted to the following vector equation,
This vector equation can be solved with MATLAB, and you can reshape the to matrix .

5 Commenti

Simon Christensen
Simon Christensen il 7 Mar 2024
Modificato: Simon Christensen il 7 Mar 2024
Hi again
Thanks for you very reply!
Would you please explain how the above equation can be solved with Matlab?
According to the vector equation:
you can get the typical system of linear equations which is analogeous to :
Then you can solve it with MATLAB mldivide, \. The following code is an example:
Ap=rand(3);
A=rand(3);
estSigma=rand(3);
vecSigma=(kron(Ap.',A)-eye(size(Ap,1)*size(A,1)))\(-estSigma(:));
Sigma=reshape(vecSigma,size(estSigma,1),size(estSigma,2))
Thanks very much @Chuguang Pan :-). One small additional questions: In the attached image, it says '...is the usual estimator of the covariance matrix of..' (below the part attached with yellow)
Are you familiar with how 'estSigma' is supposed to be estimated?
I am not familiar with how the estimator of the covariance matrix is obtained. The variable estSigma is just named referred to the image @Simon Christensen.
Okay, thanks anyway :-)

Accedi per commentare.

Più risposte (0)

Categorie

Scopri di più su Mathematics and Optimization in Centro assistenza e File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by