Book contents
- Frontmatter
- Contents
- Preface
- Part one Foundations
- 1 Introduction
- 2 Matrices and Complex Numbers
- 3 Whole Numbers
- 4 Graphs and Curves
- 5 Representation of Data
- 6 Probability and Random Numbers
- 7 Differential and Difference Equations
- Part two Investigations
- Part three Modelling
- Appendix 1 MATLAB Command Summary
- Appendix 2 Symbolic Calculations within MATLAB
- Appendix 3 List of All M-files Supplied
- Appendix 4 How to Get Solution M-files
- Appendix 5 Selected MATLAB Resources on the Internet
- References
- Index
1 - Introduction
Published online by Cambridge University Press: 08 February 2010
- Frontmatter
- Contents
- Preface
- Part one Foundations
- 1 Introduction
- 2 Matrices and Complex Numbers
- 3 Whole Numbers
- 4 Graphs and Curves
- 5 Representation of Data
- 6 Probability and Random Numbers
- 7 Differential and Difference Equations
- Part two Investigations
- Part three Modelling
- Appendix 1 MATLAB Command Summary
- Appendix 2 Symbolic Calculations within MATLAB
- Appendix 3 List of All M-files Supplied
- Appendix 4 How to Get Solution M-files
- Appendix 5 Selected MATLAB Resources on the Internet
- References
- Index
Summary
First steps with MATLAB
If you haven't already done so, you should start MATLAB by doubleclicking the relevant icon with your mouse or by asking a friend sitting next to you to show you how. Asking a friend is often the quickest way to obtain help and, in what follows, we will encourage you to take this route when all else fails. If ‘clicking’ and ‘icons’ mean nothing to you, you may need some extra help in getting started with Windows. It might also be that your system doesn't use Microsoft Windows and that simply typing matlab will do the trick. For example, if you are using a Unix system of some kind this may be the case. If all goes well you will see a MATLAB prompt
>>
inviting you to initiate a calculation. In what follows, any line beginning with >> indicates typed input to MATLAB. You are expected to type what follows but not the >> prompt itself. MATLAB supplies that automatically.
Arithmetic with MATLAB
MATLAB understands the basic arithmetic operations: add is +, subtract is −, multiply is * and divide is /. Powers are indicated with ^, thus typing
results in
If you typed the above line and nothing happened, perhaps you omitted to press the <Enter> key at the end of the line. The laws of precedence are built in but, if in doubt, you should put in the brackets. For example
The sort of elementary functions familiar on hand calculators are also available.
- Type
- Chapter
- Information
- Mathematical Explorations with MATLAB , pp. 3 - 17Publisher: Cambridge University PressPrint publication year: 1999