How to create row vector or 3-D array

I want to create row vector that can be multiplied to a matrix.
First, let me explain the matrix.
A_0 is square matrix of order 4*N*(M+1).
A_0=[A_00 A_01 0 0;
A_10 A_11 A_12 0;
A_20 A_21 A_22 A_23;
A_30 A_31 A_32 A_33].
Every matrix in A_0 are square matrix of order N*(M+1).
So i want to create this kind of row vector:
p^(i) with i=0, i get p^(0) %^(i) is not rank, its just index, so p^(0) !=1
p^(i)=(p_(4i)^(i), p_(4i+1)^(i), p_(4i+2)^(i), p_(4i+3)^(i)), %p^(i) has 4*N*(M+1) elements
where
p_j^(i)=(p_(j,0,1)^(i),p_(j,0,2)^(i),...,p_(j,0,N)^(i),
p_(j,1,1)^(i),p_(j,1,2)^(i),...,p_(j,1,N)^(i),...,
p_(j,M,1)^(i),p_(j,M,2)^(i),...,p_(j,M,N)^(i)) i,j>=0 , 4i<=j<=4i+3.
I need to multiply p^(0) * A_00.
For example,
p^(0)*A_0=(p_(0)^(0), p_(1)^(0),p_(2)^(0),p_(3)^(0))*[A_00 A_01 0 0;
A_10 A_11 A_12 0;
A_20 A_21 A_22 A_23;
A_30 A_31 A_32 A_33].
Assume N=3 M=4,
p_(0)^(0) * A_00=
(p_(0,0,1)^(0),p_(0,0,2)^(0),p_(0,0,3)^(0),
p_(0,1,1)^(0),p_(0,1,2)^(0),p_(0,1,3)^(0),
p_(0,2,1)^(0),p_(0,2,2)^(0),p_(0,2,3)^(0),
p_(0,3,1)^(0),p_(0,3,2)^(0),p_(0,3,3)^(0)),
p_(0,4,1)^(0),p_(0,4,2)^(0),p_(0,4,3)^(0)) have N*(M+1)=15 elements and A_00 has N*(M+1) elements too so it can be multiplied.
For the code, i only know how to make row vector of 1 row and N column:
p=sym('p',[1 N]) .
So, i have to make p^(0)=(p_(0)^(0), p_(1)^(0),p_(2)^(0),p_(3)^(0)) that can be open up again to have N*(M+1) elements.
I only need p^(0) because from my equation, the formula to search p^(n)=p^(0)*R %where R is square matrix of order 4*N*(M+1).

5 commentaires

Jan
Jan le 14 Nov 2022
Modifié(e) : Jan le 14 Nov 2022
This is not a matrix:
Q_1=[A_00 A_01
A_10 A_11 A_12
A_20 A_21 A_22 A_23
...
In a matrix all rows and columns have the same number of elements respectively.
Beside this, the definition of Q1 is unclear:
A_30 A_31 A_32 A_33 A_34
A_40 A_41 A_42 A_43 A_44 A_45
A_40 A_41 A_42 A_43 A_44 A_45
and so on ],
Why is the last shown line repeated, while the others are not? Then "and so on" is not clear.
After the initial statement of the question is unclear, the rest of the question looses its meaning. Please edit the question and prefer to post Matlab code, which produces the inputs.
Do you want a symbolic or numeric vector?
DoinK
DoinK le 14 Nov 2022
Modifié(e) : DoinK le 14 Nov 2022
@Jan I want a symbolic vector. As i edit my question, I have another problem to create infinite matrix and infinite tridiagonal matrix, so i use word "and so on".
From your explanation, yes i want to make 3-D array to multiply it with matrix Q.
Jan
Jan le 14 Nov 2022
What do you call an "infinite matrix"? Do you mean a matrix ith an infinite number of elements? This would need an infinite amount of RAM.
DoinK
DoinK le 14 Nov 2022
Ah you are right Sir, let me edit the question again.

Connectez-vous pour commenter.

Réponses (0)

Catégories

Question posée :

le 14 Nov 2022

Modifié(e) :

le 16 Nov 2022

Community Treasure Hunt

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

Start Hunting!

Translated by