Documente Academic
Documente Profesional
Documente Cultură
ALGORITHMS &
INT. TO PROGRAMMING
Week 2
“Exploring MATLAB”
Ahmet Anıl Dindar
28.02.2007
The class facts
ENG004.01 2
Last week
ENG004.01 3
This week
ENG004.01 4
Algorithm and Programming
Some examples to
Algorithm
ENG004.01 5
Programming
How to program?
ENG004.01 6
You need some tools to make the
machine perform your algorithms
Basic
Pascal
C,C++
Java
Perl
...
ENG004.01 7
MATLAB
ENG004.01 8
MATLAB and Columns-Beams?
What is the relationship?
MATLAB in Civil
Engineering?
Do we need it?
Does any Civil Engineer
use MATLAB in work?
Have you ever seen any
Civil Engineer using
MATLAB?
ENG004.01 9
And now let’s see
How MATLAB looks?
Follow me now!
ENG004.01 10
Let’s do some Calculations
ENG004.01 11
Gauss Number
1+2+3+...+100=?
1 2 3 .... n
n n 1
2
>>
100*(100
+1)/2
ans =
5050
>>
ENG004.01 12
Assignment #1
Please do the following calculations in
MATLAB
>> 10*(10+1)/2
>> (10+50)*(10+20)/10
>>10*(10+1)+(10+1/2)*(58+1)
>>25/2+8-9
>>8+9*9-5
Are there any difference between
>> 8+9*(9-5)
these calculations?
>> (8+9)*9-5
ENG004.01 13
Send your diary files to class e-mail
ENG004.01 14
Next week...
Weeks Date Class Assignment
ENG004.01 15
See you next week!
ENG004.01 16
ENG004.01 17