Given two numbers: M, N, how to create a matrix: res = MxMxMxMxM...xM, where ndims(res) == N.

 Akzeptierte Antwort

Azzi Abdelmalek
Azzi Abdelmalek am 19 Feb. 2014
Bearbeitet: Azzi Abdelmalek am 19 Feb. 2014

0 Stimmen

N=6;
m=4;
A=zeros(repmat(m,1,n));

Weitere Antworten (0)

Kategorien

Community Treasure Hunt

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

Start Hunting!

Translated by