Effacer les filtres
Effacer les filtres

how to add the sequences in the mat lab?

2 vues (au cours des 30 derniers jours)
krithika P
krithika P le 11 Juil 2012
for ex i have sequences A=[1 2 3 4]
B=[1 2 ]
i want to add the zeros in the B sequence by comparing the length..
  1 commentaire
krithika P
krithika P le 11 Juil 2012
how to add.. is there any inbuilt command

Connectez-vous pour commenter.

Réponse acceptée

Conrad
Conrad le 11 Juil 2012
Did you mean something like this?
A = [1 2 3 4];
B = [1 2];
B = [B zeros(1,length(A)-length(B))];
B will then be equal to [1 2 0 0].

Plus de réponses (0)

Catégories

En savoir plus sur MATLAB dans Help Center et File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by