MATLAB Answers

matrix in special arrangment for cycler gemetry

24 views (last 30 days)
hello every one
thank you very much for helping
i have big matrix for motor geometry i want to make special arrangement to respect complete circle of motor
for example i have this small matrix
A=[11 12 13 14 15]
i want to change it to
A=[11 12 13 14 15
12 11 12 13 14
13 12 11 12 13
14 13 12 11 12
15 14 13 12 11]
thank you very much again for helping
  2 Comments
mohammed hussein
mohammed hussein on 27 Feb 2021
Thank you very much , it works perfectly
is there any way to get it without for loop , i have very long matrix it takes very long time

Sign in to comment.

Accepted Answer

Bruno Luong
Bruno Luong on 27 Feb 2021
Edited: Bruno Luong on 27 Feb 2021
>> A=[11 12 13 14 15]
A =
11 12 13 14 15
>> toeplitz(A,A)
ans =
11 12 13 14 15
12 11 12 13 14
13 12 11 12 13
14 13 12 11 12
15 14 13 12 11

More Answers (0)

Community Treasure Hunt

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

Start Hunting!

Translated by