E-book details

Engineering Calculations and Their Programming: PTC®MathCAD Prime®3.0

Engineering Calculations and Their Programming: PTC®MathCAD Prime®3.0

Robert Gajewski

Ebook

W opracowaniu opisano program PTC MathCAD Prime 3.0, który jest jednym z pakietów komputerowego wspomagania warsztatu studenta i inżyniera, umożliwiającym obliczenia numeryczne i symboliczne oraz ich wizualizację. Książka zawiera coś więcej niż zwykłą instrukcję korzystania z programu. Treść instruktażowa została wzbogacona licznymi przykładami obliczeń oraz omówieniem sposobu ich programowania.

1 Getting Started 9

1.1 Differences between Prime and Express 11

1.1.1 Math 12

1.1.2 Input / Output 13

1.1.3 Functions 13

1.1.4 Plots 13

1.2 Workspace 13

1.2.1 Ribbon 15

1.2.2 Worksheets and Regions 19

1.2.3 Customizing Worksheet 20

1.3 Mathematical expressions 21

1.3.1 Grouping 21

1.3.2 Formatting results 22

1.4 Inserting text and image 22

1.4.1 Formatting text regions 23

1.4.2 Regions location 23

1.5 Areas 24

1.6 Help 25

1.7 Exercises 25

2 Symbolic calculations 27

2.1 Keywords and modifiers 29

2.2 Simplifying and rewriting expressions 30

2.2.1 Rewriting expressions 30

2.2.2 Simplifying expressions 30

2.2.3 Combining expressions 31

2.2.4 Collecting terms 31

2.3 Expanding and factoring expressions 31

2.3.1 Expanding expressions 31

6 Engineering calculations and their programming

2.3.2 Factoring expressions 32

2.4 Polynomials – coefficients and partial fractions 33

2.4.1 Finding coefficients of a polynomial 33

2.4.2 Expanding a quotient of polynomials into partial fractions 34

2.5 Substituting variables 35

2.6 Expanding to series 36

2.7 Solving equations and inequalities 36

2.8 Exercises 37

3 Numerical calculations 41

3.1 Identifiers and labels 41

3.2 Defining variables 43

3.3 Defining functions 44

3.4 Units 44

3.5 Range variables 46

3.6 Elements of calculus 47

3.7 Logical expressions 48

3.8 2D Plots 49

3.8.1 Parametric plots 52

3.8.2 Roots of functions 53

3.9 Exercises 54

4 Vectors, matrices and tables 57

4.1 Inserting and editing matrices and tables 58

4.2 Matrix operations 62

4.3 Solution of sets of linear equations 66

4.4 Chosen matrix functions 67

4.4.1 Sizes of vectors and matrices 67

4.4.2 Generation of vectors and matrices 67

4.4.3 Looking for elements in matrices and vectors 68

4.4.4 Operations on parts of matrices 69

4.4.5 Eigenvalues and eigenvectors 70

4.4.6 Sorting functions 71

4.5 Exercises 72

5 Plots and input / output 75

5.1 Polar plots 76

5.2 Contour plots 78

5.3 3D plots 81

5.4 Reading and writing files 83

5.4.1 WRITEFILE and READFILE 84

5.4.2 WRITEPRN, READPRN and APPEDNPRN 85

5.5 Integrating with Microsoft Excel 85

5.6 Exercises 88

6 Problem solving 89

6.1 Approximation 89

6.1.1 Linear approximation 90

6.1.2 Exponential approximation 91

6.2 Solution of sets of linear equations 92

6.3 Roots of functions 94

6.4 Solve Block 95

6.4.1 Function find 96

6.4.2 Function minerr 98

6.4.3 Function minimize 99

6.4.4 Function maximize 100

6.4.5 Function odesolve 103

6.5 Exercises 104

7 Basics of Programming 106

7.1 Programming operators 107

7.1.1 Defining a program 107

7.1.2 Defining functions 108

7.1.3 Conditional statements 109

7.1.4 Program loops 111

7.1.5 Another control statements 112

7.2 Basic programming problems 113

7.2.1 Sums of integers 114

7.2.2 Nested branching 116

7.2.3 Statements break, continue, return 119

7.3 Matrices, vectors and indexing 120

7.3.1 Min and max elements in vector 120

7.3.2 Even and odd elements in vector 123

7.3.3 Average and swap 124

7.3.4 Matrices 126

7.4 Exercises 129

8 Advanced programming 130

8.1 Series of numbers 130

8.1.1 Series with factorial terms 132

8.1.2 Geometric series 133

8.1.3 Series with products in denominator 134

8.1.4 Alternating series 136

8.2 Functions expanded to series 137

8.2.1 Expansion of sin function 138

8.3 Classical algorithms 139

8.3.1 Greatest common divisor 139

8.3.2 Lowest common multiple 141

8.3.3 Fibonacci numbers 142

8.3.4 Prime numbers 142

8.4 Basic numerical algorithms 144

8.4.1 Bisection method 144

8.4.2 False position method 146

8.4.3 Secant method 146

8.4.4 Square root – Babylonian method 147

8.5 Sorting algorithms 148

8 Engineering calculations and their programming

8.5.1 Naive (stupid bubble) sort 148

8.5.2 Bubble sort 149

8.5.3 Selection sort 150

8.6 Recurrence 151

8.6.1 Factorial, Fibonacci numbers and gcd 151

8.6.2 Partition function 152

8.7 Exercises 153

  • Title: Engineering Calculations and Their Programming: PTC®MathCAD Prime®3.0
  • Author: Robert Gajewski
  • ISBN: 978-83-8156-137-2, 9788381561372
  • Date of issue: 2020-10-15
  • Format: Ebook
  • Item ID: e_1s63
  • Publisher: Oficyna Wydawnicza Politechniki Warszawskiej