Skip to main content

This is package . A example package to find Roots of eqaution and solves an ordinary differential equation (ODE).

Project description

scm20367104703

scm20367104703is A example package to find Roots of eqaution and solves an ordinary differential equation (ODE).


Features

  • Fixed-Point Iteration: use a function fixed_point() to use Fixed_point method
  • Secant Method: use a function secant() to use Secant method
  • 2nd-order Runge-Kutta: Use function rk2()solves an ordinary differential equation (ODE) of the form $$ \frac{dy}{dx} = f(t, y) $$ using the 2nd-order Runge-Kutta method (Midpoint Method).
  • 5nd-order Runge-Kutta : Use rk5() Solves the same type of ODE using a more accurate 5th-order Runge-Kutta method.

Installation

You can install the package directly from PyPI:

pip install scm20367104703


Example1

    def g(x):
        return (x**2 + 3) / 5
    initial_guess = 0.5
    root, iterations = fixed_point(g, initial_guess)
    print(f"\nApproximate: {root}")

Example2

    def f(x):
        return x**3 - x - 2
    root, iterations = secant(f, 1, 2)
    print(f"\nApproximate : {root}")


Example3

    def f(t, y):
        return y - t**2 + 1
    t0 = 0.0
    y0 = 0.5
    h = 0.5
    n_steps = 8
    rk2(f, t0, y0, h, n_steps)

Example4

    def f(t, y):
        return y - t**2 + 1
    t0 = 0.0
    y0 = 0.5
    h = 0.5
    n_steps = 8
    rk5(f, t0, y0, h, n_steps)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

scm20367104703-0.1.1.tar.gz (3.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

scm20367104703-0.1.1-py3-none-any.whl (4.2 kB view details)

Uploaded Python 3

File details

Details for the file scm20367104703-0.1.1.tar.gz.

File metadata

  • Download URL: scm20367104703-0.1.1.tar.gz
  • Upload date:
  • Size: 3.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.7

File hashes

Hashes for scm20367104703-0.1.1.tar.gz
Algorithm Hash digest
SHA256 49be3f70294b335240bcb127612063221a58ac5b0d3202d6d5f67a0b27f9a8d7
MD5 b4591de017e7e5875a50fe7bfa27a1f5
BLAKE2b-256 07cbc79b349e32470500023acb7f073351f3daa66f2f6a7718e47679b911ffa7

See more details on using hashes here.

File details

Details for the file scm20367104703-0.1.1-py3-none-any.whl.

File metadata

  • Download URL: scm20367104703-0.1.1-py3-none-any.whl
  • Upload date:
  • Size: 4.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.7

File hashes

Hashes for scm20367104703-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 071d5a74b409c9ce51793c3a55829b6f32359de3521168dd7930f226268cc695
MD5 aa01d60f7d9dccc58e8ec3fc0c56a74f
BLAKE2b-256 2ad3f32a1453e0bc7044c544b04aa266afd3e53e428d4659edfca02eda3ada9f

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page