From aae00025bd8bff04de90b22b2472aed8a232f476 Mon Sep 17 00:00:00 2001 From: Navan Chauhan Date: Tue, 26 Mar 2024 18:21:29 -0600 Subject: post testing latex extra --- ...3-21-Polynomial-Regression-in-TensorFlow-2.html | 10 +-- ...03-26-Derivation-of-the-Quadratic-Equation.html | 90 ++++++++++++++++++++++ docs/posts/index.html | 11 +++ 3 files changed, 104 insertions(+), 7 deletions(-) create mode 100644 docs/posts/2024-03-26-Derivation-of-the-Quadratic-Equation.html (limited to 'docs/posts') diff --git a/docs/posts/2024-03-21-Polynomial-Regression-in-TensorFlow-2.html b/docs/posts/2024-03-21-Polynomial-Regression-in-TensorFlow-2.html index 7a25daf..ab46ec7 100644 --- a/docs/posts/2024-03-21-Polynomial-Regression-in-TensorFlow-2.html +++ b/docs/posts/2024-03-21-Polynomial-Regression-in-TensorFlow-2.html @@ -107,9 +107,7 @@ -

$$ -y = ax^3 + bx^2 + cx + d -$$

+y=ax3+bx2+cx+d

Optimizer Selection & Training

@@ -134,9 +132,7 @@ $$

Our loss function is Mean Squared Error (MSE):

-

$$ -= \frac{1}{n} \sum_{i=1}^{n}{(Y_i - \hat{Y_i})^2} -$$

+=1ni=1n(Y_iY_i^)2

Where Yi^ is the predicted value and Yi is the actual value

@@ -276,7 +272,7 @@ $$

How would you modify this code to use another type of nonlinear regression? Say,

-

$$ y = ab^x $$

+y=abx

Hint: Your loss calculation would be similar to:

diff --git a/docs/posts/2024-03-26-Derivation-of-the-Quadratic-Equation.html b/docs/posts/2024-03-26-Derivation-of-the-Quadratic-Equation.html new file mode 100644 index 0000000..6f02f7c --- /dev/null +++ b/docs/posts/2024-03-26-Derivation-of-the-Quadratic-Equation.html @@ -0,0 +1,90 @@ + + + + + + + + + Quadratic Formula Derivation + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+ +

Quadratic Formula Derivation

+ +

The standard form of a quadratic equation is:

+ +ax2+bx+c=0 + +

Here, a,b,c, and a0

+ +

We begin by first dividing both sides by the coefficient a

+ +x2+bax+ca=0 + +

We can rearrange the equation:

+ +x2+bax=ca + +

We can then use the method of completing the square. (Maths is Fun has a really good explanation for this technique)

+ +x2+bax+(b2a)2=ca+(b2a)2 + +

On our LHS, we can clearly recognize that it is the expanded form of (x+d)2 i.e x2+2x·d+d2

+ +(x+b2a)2=ca+b24a2=4ac+b24a2 + +

Taking the square root of both sides

+ +x+b2a=4ac+b22ax=±4ac+b2b2a=b±b24ac2a + +

This gives you the world famous quadratic formula:

+ +x=b±b24ac2a + +
If you have scrolled this far, consider subscribing to my mailing list here. You can subscribe to either a specific type of post you are interested in, or subscribe to everything with the "Everything" list.
+ +
+ +
+
+ + + + + \ No newline at end of file diff --git a/docs/posts/index.html b/docs/posts/index.html index d886b19..40b6a92 100644 --- a/docs/posts/index.html +++ b/docs/posts/index.html @@ -52,6 +52,17 @@