From Newton to Newton Fractal part-1

Jayanth

Categories:

FACT

This is my Fourth Blog

MY HANDLES

INSTA
FB
LINKDIN
GITHUB
GMAIL

Application of Raphson

1 To solve complex equation
2 Text Rendering
3,etc ...

QUOTE

"Sometimes you gotta run before you can walk." - Tony Stark

It has been nearly 20 days since our last blog post due to some technical issues, but fear not! We are back, and this time, we're diving deep into the world of Newton-Raphson. If you're an engineering student, you're probably familiar with those nerve-wracking exams where you're handed an equation and tasked with finding its solutions using the Newton-Raphson method. However, in the hustle and bustle of exam stress, we often overlook the true beauty that lies within the Newton-Raphson method. In this blog, we're on a journey to rediscover the elegance of Newton-Raphson. We'll not only grasp the mechanics but also uncover the hidden allure of this numerical technique. So, get ready to feel the passion and excitement that Newton-Raphson brings, as we explore one of the most captivating topics in the world of mathematics and engineering. Let's embark on this enlightening journey together!


prequesities :

#Linear algebra   |   #Python   |   #Numpy

Introduction

Posted on September , 2023 in JayanthBlog

When it comes to text rendering and sketching, achieving clear and smooth curves is paramount. To attain this level of precision, the use of polynomials is essential. Let's consider a scenario: imagine you open MS Paint and attempt to draw a curve. The initial result may not resemble a perfect curve, but beneath the surface, there's intricate mathematics at play. Polynomials, in particular, play a crucial role in this process. They provide a mathematical framework for defining and rendering curves with precision and clarity. These mathematical expressions allow us to generate curves that appear smooth to the human eye, creating text and drawings that are aesthetically pleasing and easy to read or interpret. In essence, polynomials serve as the mathematical backbone, helping us translate our creative intentions into visual representations that are far more precise and refined than what we can achieve with simple hand-drawn lines.

Other:-

POV :- Math and CS

Newton Method

The Newton Method is a powerful numerical technique primarily employed for approximating the roots of real-valued functions. I won't delve into the details of the Newton Method's process since you are already familiar with its main steps:

  1. Start with an initial point.
  2. Calculate the derivative at the initial point.
  3. Perform a linear extrapolation.
  4. Repeat steps 2 and 3 until the difference is less than 0.2.

These fundamental steps constitute the core of the Newton Method's procedure, allowing us to iteratively hone in on the roots of a function with increasing accuracy."

Sample code :)

  1. from math import *
  2. import time
  3. def der(x): #derivative
  4. c = 2*x #optional you can also sympy
  5. return c
  6. def func(x): #evalute
  7. d = x**2 - 4
  8. return d
  9. x =0.5
  10. c = time.time()
  11. for i in range(20):
  12. iter_start_time = time.time()
  13. print("as",x)
  14. x = x-(func(x)/der(x))
  15. iter_end_time = time.time()
  16. iter_time = iter_end_time - iter_start_time #updatefunction
  17. print(f"Iteration {i+1} took {iter_time:.6f} seconds\n ")
  18. d = time.time()

The code provided above serves as a simple demonstration, meant for explanatory purposes. In future posts, we will delve into more intricate aspects of this fascinating topic, exploring its most captivating facets. Stay tuned for the upcoming segments of this blog series, where we will uncover the truly intriguing and captivating aspects of the subject. Your journey into the beauty of this topic has only just begun!

See you soon follow my social media handles for blog updates   |   signing off BOI BOI