Error in implementation matrix dimension

1 view (last 30 days)
I am trying to implement the below code but it shows matrix dimension error. Why is that?
A = linspace(10,1000,100);
reciprocalA = 1/A;

Accepted Answer

Arif Hoq
Arif Hoq on 2 Mar 2022
Edited: Arif Hoq on 2 Mar 2022
Use element wise (./) division
A = linspace(10,1000,100);
reciprocalA = 1./A;
check this also for dot expression

More Answers (0)

Categories

Find more on Matrices and Arrays in Help Center and File Exchange

Community Treasure Hunt

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

Start Hunting!