0% found this document useful (0 votes)
26 views

Exercise1 Matlab For Your Easy Understand

This document provides a set of 10 exercises for beginners to learn Matlab. The exercises cover basic concepts like defining variables, performing arithmetic operations, evaluating expressions, and finding the inverse of a matrix. Solving problems is emphasized as an effective way to learn at the beginning stage of learning a new programming language. The goal is to keep the learning interesting and allow students to see results instantly through these exercises.
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
26 views

Exercise1 Matlab For Your Easy Understand

This document provides a set of 10 exercises for beginners to learn Matlab. The exercises cover basic concepts like defining variables, performing arithmetic operations, evaluating expressions, and finding the inverse of a matrix. Solving problems is emphasized as an effective way to learn at the beginning stage of learning a new programming language. The goal is to keep the learning interesting and allow students to see results instantly through these exercises.
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 1

Matlab Exercise for Beginners: Part-1

There are two main methods of learning any new programming language. One is, to understand the in-
depth idea and process behind every single concept. The other is to learn through solving problems. This
exercise is the part of second method. I always ask people to solve problems at the very beginning stage.
This will keep the learning interesting as you will see the results instantly. Hope you guys will enjoy these
exercise. HAPPY LEARNING.

1. There are three main windows when you open matlab viz. command window, command history
and current folder. So the question is, where you will type your code to perform an addition of
two variables?
2. What happens when you drag and drop a variable from command history to command window?
3. Define a variable a and set its value 1.
4. What is the size of the matrix you created above in question number 3? HINT: Use command
size (variable).
5. Define another matrix b with value 3.
6. Create a new matrix C by adding matrix a and matrix b.
7. Evaluate the following expressions:
1. 2^8.
2. 22/7-
3. -e^

8. Evaluate the following expressions, omitting semicolons at the ends of your lines. You
should have the format short (the default) in eect for all but the last two items.
(a) 1/0
(b) 0/0
(c) 1 10^-8
(d) 1 10^-20
(e) 1 10^-8 with format long in eect
(f) 1 10^-20 with format long in eect

9. Define a matrix m with 3 rows and 3 columns


[1 2 3
456
7 8 9]

10. Find the inverse of above defined matrix.


Send your queries at [email protected]

You might also like