summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Functions/README.md24
-rw-r--r--README.md20
2 files changed, 35 insertions, 9 deletions
diff --git a/Functions/README.md b/Functions/README.md
index a198244..07a3349 100644
--- a/Functions/README.md
+++ b/Functions/README.md
@@ -105,3 +105,27 @@ The current state of this function is **deprecated**. The algorithm fails comput
---
## [specialMatrix.m](specialMatrix.m)
+
+# specialMatrix.m
+Function returns a special matrix A with the following criteria:
+- The value of each element in the first row is the number of the column.
+- The value of each element in the first column is the number of the row.
+- The rest of the elements each has a value equal to the sum of the element above it and element to the left.
+- The function returns a sensible error if the user does not input exactly two arguments.
+
+ Synopsis: `[root, fx, ea, iter] = falsePosition(func, xl, xu, es, maxit, varargin)`.
+
+## Input
+`func` - the function being evaluated.
+`xl` - lower bound guess.
+`xu` - upper bound guess.
+`es` - desired relative error (default 0.0001%)
+`maxit` - maximum number of iterations (default 200)
+`varargin` - any additional parameters used by the function
+
+
+## Output
+`A` - special matrix with the appropriate rules
+
+## Notes:
+This function has not much of a practical application, rather a very good exercise for beginners to get started with the basics of matrix manipulation and user-defined functions.
diff --git a/README.md b/README.md
index fbe8ed5..2850e79 100644
--- a/README.md
+++ b/README.md
@@ -1,15 +1,17 @@
# mech105-algorithms
-Algorithms I created in MECH-105 (2021-Summer-Term). Consists of MATLAB scripts and functions
+Algorithms I created in MECH-105 (2021-Summer-Term). Consisting of MATLAB scripts and functions
-##Function:
-* specialMatrix.m
-* falsePosition.m
-* luFactor.m
-* Heun.m
-* simpson.m
-* days.m
+## Functions:
+* specialMatrix.m - function to make special matrix with a specific set of criteria
+* falsePosition.m - numberical root finding function
+* luFactor.m - LU Decomposition
+* Heun.m - Heuns method for solving ODE's
+* simpson.m - numerical integration technique
+* days.m - computes days elapsed in a year
-##Scripts:
+## Scripts:
* hw2.m
* hw3.m
* hw11.m
+
+Note: Detailed information on functions and scripts in their folders.