how to get the division number
2 visualizzazioni (ultimi 30 giorni)
Mostra commenti meno recenti
i want to get the first element to divide on 3
for example
3 is the first element
6 is the second element
9 is the third element
or any number not only 3
1 Commento
Risposte (1)
KSSV
il 16 Mag 2020
Read about linspace, mod. It is a basic mathematics that if mod(x,n) = 0, then x is divisible by n.
n = 7 ;
x = 1:15 ;
x(mod(x,n)==0)
0 Commenti
Vedere anche
Categorie
Scopri di più su Get Started with MATLAB in Help Center e File Exchange
Prodotti
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!