hallo,
i have a vector V = (a1, a2, ....., a5000) and i want to make a matix (2*2*5000) with the values [(a1 a1
a1 a1); ....... ;(a5000 a5000 a5000 a5000)]?
thanks

답변 (1개)

Walter Roberson
Walter Roberson 2020년 10월 14일

0 개 추천

repmat(reshape(V, 1, 1, []), 2, 2, 1)

카테고리

도움말 센터File Exchange에서 Operating on Diagonal Matrices에 대해 자세히 알아보기

질문:

2020년 10월 14일

답변:

2020년 10월 14일

Community Treasure Hunt

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

Start Hunting!

Translated by