MCPcopy Index your code
hub / github.com/Jondolf/Algorust

github.com/Jondolf/Algorust @main

Chat with this repo
repository ↗ · DeepWiki ↗ · + Follow
177 symbols 285 edges 48 files 17 documented · 10% updated 1y ago★ 128
What it actually does AI analysis from the code graph — generated when you open this
loading…
README

Algorust

This is a website with interactive visualizations of various algorithms. The entire project is made in Rust, with a Yew frontend.

Implemented algorithms

Below are all currently implemented algorithms.

Sorting

  • Bubble sort
  • Bucket sort
  • Heapsort
  • Insertion sort
  • Merge sort
  • Quicksort

Below is an image of a sorting algorithm's page with a bar graph of a randomly generated input. You can go through the steps that the algorithm takes to sort the input by using the slider.

A sorting algorithm's page with a bar graph of random numbers.

Pathfinding

  • Depth-first search / DFS (unweighted, doesn't guarantee shortest path)
  • Dijkstra (weighted, guarantees shortest path)
  • A* (weighted, uses heuristic, generally guarantees shortest path)
  • More coming soon

Below is a screenshot of running the dijkstra pathfinding algorithm in a drawn labyrinth. It shows the visited positions at each step, and when you get to the final step, you will see the finished path. A pathfinding algorithm's page with an algorithm looking for a path within a labyrinth.

Extension points exported contracts — how you extend this code

Distance (Interface)
A trait for structs that can calculate the distance from a to b. [1 implementers]
src/pathfinding/src/lib.rs
Edge (Interface)
(no doc) [2 implementers]
src/pathfinding/src/lib.rs
Line (Interface)
(no doc) [1 implementers]
src/pathfinding/src/lib.rs
Vertex (Interface)
(no doc) [1 implementers]
src/pathfinding/src/lib.rs

Core symbols most depended-on inside this repo

len
called by 27
src/pathfinding/src/lib.rs
get
called by 12
src/pathfinding/src/lib.rs
get_neighbors
called by 8
src/pathfinding/src/graph.rs
add_vertex_with_directed_edges
called by 5
src/pathfinding/src/graph.rs
input_title_to_id
called by 4
src/components/input_items/mod.rs
gen_u32_vec
called by 4
src/utils/mod.rs
knuth_shuffle
called by 4
src/utils/mod.rs
get_sorting_algorithms
called by 4
src/pages/sorting.rs

Shape

Function 71
Method 49
Class 44
Enum 9
Interface 4

Languages

Rust100%

Modules by API surface

src/pathfinding/src/lib.rs29 symbols
src/pages/pathfinding.rs15 symbols
src/pages/sorting.rs14 symbols
src/pathfinding/src/graph.rs12 symbols
src/pathfinding/src/pathfinding_algorithms/a_star/mod.rs9 symbols
src/pathfinding/src/pathfinding_algorithms/dijkstra/mod.rs6 symbols
src/pathfinding/src/maze_generation/recursive_division/mod.rs6 symbols
src/utils/audio.rs5 symbols
src/sorting/src/lib.rs5 symbols
src/pathfinding/src/pathfinding_algorithms/dfs/mod.rs4 symbols
src/main.rs4 symbols
src/hooks/use_color_scheme.rs4 symbols

For agents

$ claude mcp add Algorust \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact