how to divide matrices that print matrix

2 vues (au cours des 30 derniers jours)
Geon Jung
Geon Jung le 12 Sep 2019
Commenté : per isakson le 12 Sep 2019
clc;clear;
v2=[0,45,85,100];
t=[0,1.5,3,5];
a =v2/t ;
disp(a);
I thought "a" would print out in matrix form which it did not.
I need the answer in [a,b,c,d] form.

Réponse acceptée

Image Analyst
Image Analyst le 12 Sep 2019
Try
a = v2 ./ t % Use dot-slash ./ instead of /
No disp(a) needed if you leave off the semicolon.

Plus de réponses (0)

Catégories

En savoir plus sur Dynamic System Models 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