Zeus
Overview
Browser-based logic gate simulator with 8 gate types, subcircuit abstraction, sequential circuit support, and 10 progressive challenges. Features tri-state signal propagation, timing diagrams, SVG export, and a command palette for rapid circuit building.
Inspired by NandGame and logic.ly, Zeus provides an open sandbox with 8 gate types, constant/clock sources, and subcircuit abstraction for building reusable modules. The engine supports both combinational circuits (topological propagation) and sequential circuits (fixed-point iteration for feedback loops like SR latches). Three-layer architecture: engine (pure functions), store (Zustand with undo/redo), and rendering (Canvas 2D with React UI chrome).
Features
Simulation Engine
Tri-state signal propagation with topological sort for acyclic circuits and fixed-point iteration for sequential feedback loops. Supports subcircuit abstraction with recursive evaluation.
Interactive Canvas
Drag-and-drop gates with right-angle wire routing, junction dots, and bridge arcs. Multi-select, duplicate, zoom/pan, fullscreen, and ghost placement preview.
10 Challenges
Progressive difficulty from basic NOT gate to SR latches and D latches. Combinational and sequential circuit puzzles with truth table validation and hints.
Command Palette
Fuzzy-search component picker with MRU tracking. Place gates, switches, constants, and clocks from keyboard. Context menu for quick actions.
Analysis Tools
Live truth table generation, timing diagram with waveform recording, step-by-step simulation mode, and combinational analysis (truth table to sum-of-products circuit).
SVG Export
Export circuits as clean SVG with right-angle wires, colored pins (yellow=high, blue=low, gray=floating), and auto-computed bounding box.
Gate Library
Universal gate. All others derive from this.
2 inputsInverter. Negates the input signal.
1 inputOutput high only when both inputs are high.
2 inputsOutput high when either input is high.
2 inputsOutput high when inputs differ.
2 inputsOR followed by NOT. Key to SR latches.
2 inputsEquality detector. High when inputs match.
2 inputsBuffer. Passes signal through unchanged.
1 inputChallenges
Architecture
Pure logic with topological + fixed-point propagation. No DOM imports.
2D Canvas with right-angle wire routing, junction dots, and bridge arcs.
Icon rail sidebar, inspector panel, command palette. Zustand selectors.