Project

Create a row and column vector in Matlab

For ROW:-

General command- Initial Value: Increment: Final Value

Example- X=0:10:100

OUTPUT- X=0 10 20 30 40 50 60 70 80 90 100

Using Linspace command

u=linspace(0,20,5)

OUTPUT u=0 5 10 15 20

For COLUMN:-

General Command [Initial Value:Increment:Final Value]\'

Example- X=[0:10:100]\'

OUTPUT-

X=

0

10

20

30

40

50

60

70

80

90

100

Using Linspace command

u=linspace(0,20,5)\';

OUTPUT

u=

0

5

10

15

20

Your portfolio, next

Ship work like this
in your own course.

Talk to a career counsellor

Free 20-minute call. We'll map the right course to where you want to work.

By submitting you agree to our Terms and Privacy Policy.

Talk to a career counsellor

Free 20-minute call. We'll map the right course to where you want to work.

By submitting you agree to our Terms and Privacy Policy.