npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

mandelbrot-js

v0.0.4

Published

mandelbrot-js =======

Downloads

108

Readme

mandelbrot-js

Author: Moin Khan

mandelbrot-js: Discover the beauty of the Mandelbrot set with ease.

Introduction

mandelbrot-js is a npm package that provides functionality to determine if a given number belongs to the Mandelbrot set and to generate the orbit of that number based on a starting value. The Mandelbrot set is a famous mathematical object that is a set of complex numbers that are generated through a recursive formula. It is famous for its intricate and detailed structure, which resembles a fractal pattern when visualized. This npm package provides a convenient way to explore the Mandelbrot set by allowing users to determine if a given number belongs to the set, and to visualize its orbit. To determine membership, the package uses a simple iterative algorithm to check how quickly the value of a number grows, and if it stays bounded it is considered to be a member of the Mandelbrot set. The orbit of a number is its path as it is transformed by the recursive formula over time, and this package allows users to easily visualize the orbit of any number they choose. Whether you are a math enthusiast, a student, or just interested in exploring the Mandelbrot set, this package provides a simple and intuitive way to do so.

Installation:

via npm package.

npm i mandelbrot-js

This will install mandelbrot-js and then it can be used as needed.

Usage:

    const Mandelbrot = require('mandelbrot-js');

    const mandelbrot = new Mandelbrot();

    mandelbrot.getOrbit([0, 1]);
    mandelbrot.isMandelbrot([0, 1]);

Available Options:

| Constructor options | Description | Defaults | | :------------------ | :-------------------------------------------------------------------------------------------------------------------------------------- | :------- | | MAX_ITERATIONS | A parameter that determines the number of iterations the iterative algorithm will perform when checking if a number is diverging or not | 100 |


Contributing

All contributions are welcome. Please create an issue first for any feature request or bug. Then fork the repository, create a branch and make any changes to fix the bug or add the feature and create a pull request. That's it! Thanks!


License

mandelbrot-js is released under the MIT License. Check out the full license here.