𝔖 Scriptorium
✦   LIBER   ✦

📁

Programming with MATLAB for Scientists: A Beginner’s Introduction

✍ Scribed by Eugeniy E. Mikhailov


Publisher
CRC Press
Year
2018
Tongue
English
Leaves
265
Edition
1
Category
Library

⬇  Acquire This Volume

No coin nor oath required. For personal study only.

✦ Synopsis


This book offers an introduction to the basics of MATLAB programming to scientists and engineers. The author leads with engaging examples to build a working knowledge, specifically geared to those with science and engineering backgrounds. The reader is empowered to model and simulate real systems, as well as present and analyze everyday data sets. In order to achieve those goals, the contents bypass excessive "under the hood" details, and instead gets right down to the essential, practical foundations for successful programming and modeling. Readers will benefit from the following features:

  • Teaches programming to scientists and engineers using a problem-based approach, leading with illustrative and interesting examples.
  • Emphasizes a hands-on approach, with "must know" information and minimal technical details.
  • Utilizes examples from science and engineering to showcase the application of learned concepts on real problems.
  • Showcases modeling of real systems, gradually advancing from simpler to more challenging problems.
  • Highlights the practical uses of data processing and analysis in everyday life.

✦ Table of Contents


Half Title
Title Page
Copyright Page
Contents
Preface
Part I: Computing Essentials
1: Computers and Programming Languages:An Introduction
1.1 Early History of Computing
1.2 Modern Computers
1.2.1 Common features of a modern computer
1.3 What Is Programming?
1.4 Programming Languages Overview
1.5 Numbers Representation in Computers and Its Potential Problems
1.5.1 Discretization—the main weakness of computers
1.5.2 Binary representation
1.5.3 Floating-point number representation
1.5.4 Conclusion
1.6 Self-Study
2: MATLAB Basics
2.1 MATLAB's Graphical User Interface
2.2 MATLAB as a Powerful Calculator
2.2.1 MATLAB's variable types
2.2.2 Some built-in functions and operators
2.2.2.1 Assignment operator
2.2.3 Operator precedence
2.2.4 Comments
2.3 Efficient Editing
2.4 Using Documentation
2.5 Matrices
2.5.1 Creating and accessing matrix elements
2.5.2 Native matrix operations
2.5.2.1 Matrix element-wise arithmetic operators
2.5.3 Strings as matrices
2.6 Colon (:) Operator
2.6.1 Slicing matrices
2.7 Plotting
2.7.1 Saving plots to files
2.8 Self-Study
3: Boolean Algebra, Conditional Statements, Loops
3.1 Boolean Algebra
3.1.1 Boolean operators precedence in MATLAB
3.1.2 MATLAB Boolean logic examples
3.2 Comparison Operators
3.2.1 Comparison with vectors
3.2.2 Comparison with matrices
3.3 Conditional Statements
3.3.1 The if-else-end statement
3.3.2 Short form of the if'' statement 3.4 Common Mistake with the Equality Statement 3.5 Loops 3.5.1 Thewhile'' loop
3.5.2 Special commands break'' andcontinue''
3.5.3 The ``for'' loop
3.5.3.1 Series implementation example
3.6 Self-Study
4: Functions, Scripts, and Good Programming Practice
4.1 Motivational Examples
4.1.1 Bank interest rate problem
4.1.2 Time of flight problem
4.2 Scripts
4.2.1 Quadratic equation solver script
4.3 Functions
4.3.1 Quadratic equation solver function
4.4 Good Programming Practice
4.4.1 Simplify the code
4.4.2 Try to foresee unexpected behavior
4.4.3 Run test cases
4.4.4 Check and sanitize input arguments
4.4.5 Is the solution realistic?
4.4.6 Summary of good programming practice
4.5 Recursive and Anonymous Functions
4.5.1 Recursive functions
4.5.2 Anonymous functions
4.6 Self-Study
Part II: Solving Everyday Problems with MATLAB
5: Solving Systems of Linear AlgebraicEquations
5.1 The Mobile Problem
5.2 Built-In MATLAB Solvers
5.2.1 The inverse matrix method
5.2.2 Solution without inverse matrix calculation
5.2.3 Which method to use
5.3 Solution of the Mobile Problem with MATLAB
5.3.1 Solution check
5.4 Example: Wheatstone Bridge Problem
5.5 Self-Study
6: Fitting and Data Reduction
6.1 Necessity for Data Reduction and Fitting
6.2 Formal Definition for Fitting
6.2.1 Goodness of the fit
6.3 Fitting Example
6.4 Parameter Uncertainty Estimations
6.5 Evaluation of the Resulting Fit
6.6 How to Find the Optimal Fit
6.6.1 Example: Light diffraction on a single slit
6.6.2 Plotting the data
6.6.3 Choosing the fit model
6.6.4 Making an initial guess for the fit parameters
6.6.5 Plotting data and the model based on the initial guess
6.6.6 Fitting the data
6.6.7 Evaluating uncertainties for the fit parameters
6.7 Self-Study
7: Numerical Derivatives
7.1 Estimate of the Derivative via the Forward Difference
7.2 Algorithmic Error Estimate for Numerical Derivative
7.3 Estimate of the Derivative via the Central Difference
7.4 Self-Study
8: Root Finding Algorithms
8.1 Root Finding Problem
8.2 Trial and Error Method
8.3 Bisection Method
8.3.1 Bisection use example and test case
8.3.1.1 Test the bisection algorithm
8.3.1.2 One more example
8.3.2 Possible improvement of the bisection code
8.4 Algorithm Convergence
8.5 False Position (Regula Falsi) Method
8.6 Secant Method
8.7 Newton–Raphson Method
8.7.1 Using Newton–Raphson algorithm with the analytical derivative
8.7.2 Using Newton–Raphson algorithm with the numerical derivative
8.8 Ridders' Method
8.9 Root Finding Algorithms Gotchas
8.10 Root Finding Algorithms Summary
8.11 MATLAB's Root Finding Built-in Command
8.12 Self-Study
9: Numerical Integration Methods
9.1 Integration Problem Statement
9.2 The Rectangle Method
9.2.1 Rectangle method algorithmic error
9.3 Trapezoidal Method
9.3.1 Trapezoidal method algorithmic error
9.4 Simpson's Method
9.4.1 Simpson's method algorithmic error
9.5 Generalized Formula for Integration
9.6 Monte Carlo Integration
9.6.1 Toy example: finding the area of a pond
9.6.2 Naive Monte Carlo integration
9.6.3 Monte Carlo integration derived
9.6.4 The Monte Carlo method algorithmic error
9.7 Multidimensional Integration
9.7.1 Minimal example for integration in two dimensions
9.8 Multidimensional Integration with Monte Carlo
9.8.1 Monte Carlo method demonstration
9.9 Numerical Integration Gotchas
9.9.1 Using a very large number of points
9.9.2 Using too few points
9.10 MATLAB Functions for Integration
9.11 Self-Study
10: Data Interpolation
10.1 The Nearest Neighbor Interpolation
10.2 Linear Interpolation
10.3 Polynomial Interpolation
10.4 Criteria for a Good Interpolation Routine
10.5 Cubic Spline Interpolation
10.6 MATLAB Built-In Interpolation Methods
10.7 Extrapolation
10.8 Unconventional Use of Interpolation
10.8.1 Finding the location of the data crossing y=0
10.9 Self-Study
Part III: Going Deeper and Expanding the Scientist's Toolbox
11: Random Number Generators and Random Processes
11.1 Statistics and Probability Introduction
11.1.1 Discrete event probability
11.1.2 Probability density function
11.2 Uniform Random Distribution
11.3 Random Number Generators and Computers
11.3.1 Linear congruential generator
11.3.2 Random number generator period
11.4 How to Check a Random Generator
11.4.1 Simple RNG test with Monte Carlo integration
11.5 MATLAB's Built-In RNGs
11.6 Self-Study
12: Monte Carlo Simulations
12.1 Peg Board
12.2 Coin Flipping Game
12.3 One-Dimensional Infection Spread
12.4 Self-Study
13: The Optimization Problem
13.1 Introduction to Optimization
13.2 One-Dimensional Optimization
13.2.1 The golden section optimum search algorithm
13.2.1.1 Derivation of the R coefficient
13.2.2 MATLAB's built-in function for the one-dimension optimization
13.2.3 One-dimensional optimization examples
13.2.3.1 Maximum of the black body radiation
13.3 Multidimensional Optimization
13.3.1 Examples of multidimensional optimization
13.3.1.1 The inversed sinc function
13.3.1.2 Three-dimensional optimization
13.3.1.3 Joining two functions smoothly
13.3.1.4 Hanging weights problem
13.4 Combinatorial Optimization
13.4.1 Backpack problem
13.4.2 Traveling salesman problem
13.4.2.1 Permutation generating algorithm
13.4.2.2 Combinatorial solution of the traveling salesman problem
13.5 Simulated Annealing Algorithm
13.5.1 The backpack problem solution with the annealing algorithm
13.6 Genetic Algorithm
13.7 Self-Study
14: Ordinary Differential Equations
14.1 Introduction to Ordinary Differential Equation
14.2 Boundary Conditions
14.3 Numerical Method to Solve ODEs
14.3.1 Euler's method
14.3.2 The second-order Runge–Kutta method (RK2)
14.3.3 The fourth-order Runge-Kutta method (RK4)
14.3.4 Other numerical solvers
14.4 Stiff ODEs and Stability Issues of the Numerical Solution
14.5 MATLAB's Built-In ODE Solvers
14.6 ODE Examples
14.6.1 Free fall example
14.6.2 Motion with the air drag
14.7 Self-Study
15: Discrete Fourier Transform
15.1 Fourier Series
15.1.1 Example: Fourier series for |t|
15.1.2 Example: Fourier series for the step function
15.1.3 Complex Fourier series representation
15.1.4 Non-periodic functions
15.2 Discrete Fourier Transform (DFT)
15.3 MATLAB's DFT Implementation and Fast Fourier Transform (FFT)
15.4 Compact Mathematical Notation for Fourier Transforms
15.5 DFT Example
15.6 Self-Study
16: Digital Filters
16.1 Nyquist Frequency and the Minimal Sampling Rate
16.1.1 Undersampling and aliasing
16.2 DFT Filters
16.2.1 Low-pass filter
16.2.2 High-pass filter
16.2.3 Band-pass and band-stop filters
16.3 Filter's Artifacts
16.4 Windowing Artifacts
16.5 Self-Study
References
Index


📜 SIMILAR VOLUMES


Programming with MATLAB for Scientists :
✍ Mikhailov, Eugeniy E 📂 Library 📅 2018 🏛 CRC Press 🌐 English

"This book offers an introduction to the basics of MATLAB programming to scientists and engineers. The author leads with engaging examples to build a working knowledge, specifically geared to those with science and engineering backgrounds. The reader is empowered to model and simulate real systems,

Programming with MATLAB for Scientists :
✍ Mikhailov, Eugeniy E 📂 Library 📅 2018 🏛 CRC Press 🌐 English

"This book offers an introduction to the basics of MATLAB programming to scientists and engineers. The author leads with engaging examples to build a working knowledge, specifically geared to those with science and engineering backgrounds. The reader is empowered to model and simulate real systems,

Getting Started with MATLAB: A Quick Int
✍ Rudra Pratap 📂 Library 📅 2009 🏛 Oxford University Press, USA 🌐 English

MATLAB, a software package for high-performance numerical computation and visualization, is one of the most widely used tools in the engineering field today. Its broad appeal lies in its interactive environment, which features hundreds of built-in functions for technical computation, graphics, and a

Programming for Computations - MATLAB/Oc
✍ Svein Linge, Hans Petter Langtangen (auth.) 📂 Library 📅 2016 🏛 Springer International Publishing 🌐 English

<p><p>This book presents computer programming as a key method for solving mathematical problems. There are two versions of the book, one for MATLAB and one for Python. The book was inspired by the Springer book TCSE 6: A Primer on Scientific Programming with Python (by Langtangen), but the style is