AkalankaDilshan / Collatz_conjecture-

This is Collatz Conjecture module based on P5.js

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Collatz Conjecture

collatz

A fully functional EXAMPLE project written in Go showing how to create a collatz conjecture module using P5.js

The Collatz Conjecture, also known as the 3n + 1 conjecture or the Ulam conjecture, is a mathematical hypothesis that states that for any positive integer n, if n is even, divide it by 2, and if n is odd, multiply it by 3 and add 1. The conjecture suggests that this sequence will eventually reach the value 1, regardless of the starting value of n.

For example, if we start with n = 6, we get the following sequence:

6 → 3 → 10 → 5 → 16 → 8 → 4 → 2 → 1

The conjecture has been tested for all positive integers up to 2^68, and no counterexamples have been found, leading mathematicians to believe that it is true. However, the conjecture has not been proven mathematically and remains an unsolved problem in number theory.

Resources

Website: http://thecodingtrain.com/

youtube: https://youtu.be/EYLWxwo1Ed8

p5.js Web Editor Sketch: https://editor.p5js.org/codingtrain/s...

How to install this example

The easiest way to see how this works is to watch the series, but here's the short version.

  1. clone this project
  2. Set up a p5.js Web Editor
  3. enjoy it.

How to tweak this project for your own uses

Since this is an example project, I'd encourage you to clone and rename this project to use for your own puposes. It's a good starter boilerplate

Find a bug?

If you found an issue or would like to submit an improvement to this project, please submit an issue using the issues tab above. If you would like to submit a PR with a fix, reference the issue you created!

Known issues (Work in progress)

This project is till ongoing. The automation of the helm chart repo has not been completed yet. This is coming soon!

Like this project?

If you are feeling generous, follow me on github.

About

This is Collatz Conjecture module based on P5.js

License:MIT License


Languages

Language:Processing 50.0%Language:JavaScript 50.0%