Problem with matrix manipulation

2 vues (au cours des 30 derniers jours)
Diaz Diesel
Diaz Diesel le 28 Oct 2015
Commenté : Image Analyst le 28 Oct 2015
i have matriks
A1 = [1 2 3 4 5 6 7 8] A2 = [9 10 11 12 13 14 15 16] . . . . An = [.........]
i want to display them
F = [A1,A2,..., An]
so the results obtained
F = [1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 ... An]
  1 commentaire
Image Analyst
Image Analyst le 28 Oct 2015
You know n, right? You must. If not, explain why n might vary.

Connectez-vous pour commenter.

Réponse acceptée

Roger
Roger le 28 Oct 2015
A = [A1 A2 ... An];% do not use ","
  2 commentaires
Diaz Diesel
Diaz Diesel le 28 Oct 2015
how can i load its into A = [A1 A2 ...An]?
Image Analyst
Image Analyst le 28 Oct 2015
That's nonsense. You certainly can use a comma to horizontally append row vectors, in fact the lint in the code editor will recommend that you use commas rather than spaces. The code Diaz gave for F will work, given that n is known so that you know the names of all the arrays.

Connectez-vous pour commenter.

Plus de réponses (0)

Catégories

En savoir plus sur Creating and Concatenating Matrices dans Help Center et File Exchange

Tags

Community Treasure Hunt

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

Start Hunting!

Translated by