I NEED TO DIVED TWO ARRAYS OF DIFFERENT SIZES

8 次查看(过去 30 天)
i have two arrays F and R
problem is that F has a size of (1 x 10) and R has a size of (1 x 9)
i need to shift the division process by the differnce of the size
ex.
F= 0.0026 0.0026 0.0026 0.0026 0.0027 0.0027 0.0027 0.0028 0.0028 0.0028
R = 0.0024 0.0019 0.0015 0.0012 0.0010 0.0007 0.0005 0.0003 0.0002
i need to divide the 2nd element of F with the 1st element in R
and the 3rd element of F with the 2nd element in R
Result would be
Answer = 1.083 1.368 1.733 2.25 2.7 3.857 5.6 9.3 14

采纳的回答

madhan ravi
madhan ravi 2019-4-29

更多回答(1 个)

KSSV
KSSV 2019-4-29
R = [NaN R] ;
iwant = F./R ;

类别

Help CenterFile Exchange 中查找有关 Loops and Conditional Statements 的更多信息

标签

Community Treasure Hunt

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

Start Hunting!

Translated by