Question

Complete the follow in MATLAB Make x an array going from 0 to 100 by steps...

Complete the follow in MATLAB

Make x an array going from 0 to 100 by steps of 2 units. (Array indexing)

Make y an array going from 0 to 50 by steps of 1 unit. (Array indexing)

Make z an array that is equal to [x1y1, x2y2, ..., xnyn]. (Arithmetic operations)

Find the first 5 values of the z array. (Array indexing)

0 0
Add a comment Improve this question Transcribed image text
Answer #1
% Make x an array going from 0 to 100 by steps of 2 units. (Array indexing)
x = 0:2:100

% Make y an array going from 0 to 50 by steps of 1 unit. (Array indexing)
y = 0:1:50

% Make z an array that is equal to [x1y1, x2y2, ..., xnyn]. (Arithmetic operations)
z = x .* y

% Find the first 5 values of the z array. (Array indexing)
z(1:5)

Add a comment
Know the answer?
Add Answer to:
Complete the follow in MATLAB Make x an array going from 0 to 100 by steps...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT