Matlab For Engineers
Matlab For Engineers
Matlab For Engineers
Adrian Biran
Moshe Breiner
Preface v
1 MATLAB in a nutshell 1
1.1 Desktop calculations 1
1.1.1 Getting started 1
1.1.2 Arithmetic operations 2
1.1.3 Last-line editing 3
1.1.4 A few built-in functions 3
1.1.5 Naming constants and variables 6
1.1.6 Format 8
1.1.7 Diary 10
1.2 One-dimensional arrays and graphics 10
1.2.1 Arrays - elementary operations 10
1.2.2 More operations on arrays 12
1.2.3 Row vectors and column vectors 14
1.2.4 The scalar product 15
1.2.5 Simple plots 16
1.3 Matrices 17
1.3.1 Defining a matrix 17
1.3.2 Elementary operations with matrices 19
1.3.3 Printing a table 21
1.4 Complex numbers 22
1.4.1 Complex numbers - elementary operations 22
1.4.2 Two notes on the use of i and j 23
1.4.3 Plotting a complex number 24
1.4.4 Trigonometric and exponential representations 25
1.4.5 Functions of complex variables 27
1.4.6 Arrays of complex numbers 27
1.5 Systems of linear equations 28
1.5.1 Determinants 28
1.5.2 Cramer's rule 29
1.5.3 Matrix inversion 31
ix
X CONTENTS
15 Control 531
15.1 Introduction 531
15.2 Root locus design 532
15.3 Design in the frequency domain 534
15.4 Optimal design 544
15.5 Exercises 547