GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - amoshnin/R-Recursion.Tree.Visualizer: ⚡️ Tool for visualizing generic recursive function written in JavaScript/Python. Functions are animated using tree structures. It aids identification of function time complexity & call stack depth

BranchesTags
Open more actions menu

Latest commit

 

History

26 Commits
26 Commits

Folders and files

NameName
Last commit message
Last commit date
.github/workflows
.github/workflows
 
 
assets
assets
 
 
packages
packages
 
 
.gitignore
.gitignore
 
 
LICENSE
LICENSE
 
 
README.md
README.md
 
 
yarn.lock
yarn.lock
 
 

Repository files navigation

Recursion Tree Visualizer

Tool for visualizing any generic recursive function written in JavaScript or Python.

Overview

Watch the demo video on my YouTube channel

Recursion is a concept that is best understood through visualization. This visualization tool written in TypeScript (with React and Node JS Express), will allow you to see visualization of different kinds of recursions. For simplicity, I chose to animate recursive functions using trees.

Properties of the recursion tree visualizations are:

  • Each node represents a single recursive function call.
  • The height of the recursion tree is the depth of our function call stack (n).
  • The rate of change of the tree’s width represents the time complexity of our function (m):
Image taken from QuanticDev blog post

Folders structure

  • packages/web: react user interface.
  • packages/server: server to execute user-defined code remotely.

Local development

Web

In the packages/web directory, run:

# to install all dependencies
$ npm install

# to run the app on localhost
$ npm run start

Server

In the packages/server directory, run:

# to install all dependencies
$ npm install

# to run the app on localhost
$ npm run serve

Acknowledgements

Thanks to Drawing Presentable Trees and Improving Walker's Algorithm to Run in Linear Time articles I implemented Reingold-Tilford's algorithm to position each node of the tree on a 2D plane in an aesthetically pleasing way.

Compatibility

For a better experience, I recommend using a chromium-based browser like Chrome or Edge.

About

⚡️ Tool for visualizing generic recursive function written in JavaScript/Python. Functions are animated using tree structures. It aids identification of function time complexity & call stack depth

Topics

algorithmsrecursionrecursion-treerecursion-visualizervisualization

Resources

Readme
MIT license
Activity

Stars

2 stars

Watchers

1 watching

Forks

0 forks
Report repository

Releases

Packages

Contributors

Languages

You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.