How do I generate a 4 dimensional matrix of dimension 5x5x5x5 with random complex numbers as elements?

1 回表示 (過去 30 日間)
If I am successful to do so, can I invert the above matrix? Let us say I have A(a,b;c,d) as a 4-d matrix. If I invert this matrix will i get B(c,d;a,b)?
  3 件のコメント
vishav Rattu
vishav Rattu 2016 年 10 月 20 日
By "invert" I mean I need to find a B such that BA=AB=I. I was searching for the answer alongside and stumbled upon this link: http://www.iaeng.org/publication/WCE2010/WCE2010_pp1838-1841.pdf
I think this clarifies the "inversion" is possible mathematically. I need to invert individual pages and output the inverted matrix.
Walter Roberson
Walter Roberson 2016 年 10 月 21 日
There are no MATLAB routines to do multidimensional matrix inversion. You would need to write them yourself. The result would be whatever the theoretic result would be, which is outside of the scope of the MATLAB Answers forum.

サインインしてコメントする。

採用された回答

Walter Roberson
Walter Roberson 2016 年 10 月 20 日
A = complex(rand(5,5,5,5), rand(5,5,5,5);
or
A = rand(5,5,5,5) + 1i * rand(5,5,5,5);
then
B = permute(A, [3 4 1 2]);
  2 件のコメント
Ömer Asicioglu
Ömer Asicioglu 2021 年 3 月 14 日
if i have to 100 dimension vector , how to create ?
Walter Roberson
Walter Roberson 2021 年 3 月 16 日
N = number_of_entries;
D = 100;
dim100 = rand([ones(1,D-1),N]);

サインインしてコメントする。

その他の回答 (1 件)

Andrei Bobrov
Andrei Bobrov 2016 年 10 月 20 日
Maybe so?
B = A(:,:,end:-1:1,:);
or
B = flip(A,3);

カテゴリ

Help Center および File ExchangeMatrices and Arrays についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by