Some algorithm visualizations, mostly related to number theory.
As heroku dyno suffers from symptoms of being dead, and Render doesn't work either, here is the new link - https://jonothordarry.pythonanywhere.com/
- They have an absurd amount of pop-ups I never ever read.
- They don't allow to visualize a mechanism on a huge testcase.
- They don't give to shown mechanisms any identity distinguishing them from other mechanisms (or ideas).
- There is usually nothing interesting about those visualizations once you know, how a mechanism works.
- They don't couple visualizations with theory containing proofs and ideas related to a mechanism / an algorithm.
- They don't have nice buttons distinguishing articles and/or visualizations.
- Seeing how the method works before analyzing it theoretically may yield better results (i.e. seeing how the mechanism works before thinking about it).
- Visualization should show primarily why a mechanism works, rather than how it works.
- It is appropriate to show past actions of an algorithm (even if they're irrelevant) in order to give bird's-eye view to an algorithm along with fun.
- It is sometimes desirable to debug own library with the use of visualizations along with partial results.
- Visualizations should provide fun, whether by allowing to pass a huge testcase and see its results, or by the virtue of its aesthetics, or by allowing to use ProgressBar and see how the reality changes in subsequent steps of a mechanism.
- Click "Begin" in order to start a visualization (or don't, I won't tell you what to do with your life). Begin initializes the algorithm with supplied (or default) input and options.
- "Next Move" / "Previous Move" allows to move the visualization one step back/forward.
- "Finish" allows to move visualization to its last state.
- "Visualization Progress" bar allows to move the visualization from one state to another.
- Some algorithms have additional options: they usually allow either to disable some feature (for example, disable displaying grids in gcd visualization - which is handy for showing table on large data) or enable some feature (for example, showing rho's in pollard-rho algorithm - either for found divisor, or all divisors in form (p^k))
If You want to see, how the application looks like, and you have python with flask, then:
- pip install -r requirements.txt
- python base.py
- go in the browser to localhost:5000/