Gaussian Elimination Visualizer
Run the Gaussian Elimination MicroSim Fullscreen
Edit the MicroSim with the p5.js editor
About This MicroSim
Watch the Gaussian elimination algorithm solve a system of linear equations step by step. Each operation is explained, helping you understand not just what happens but why.
Algorithm Phases:
- Forward Elimination: Create zeros below each pivot to reach row echelon form
- Back Substitution: Solve for variables starting from the last row
How to Use
- Choose an Example: Select a system size from the dropdown
- Step Through: Click "Next Step" to advance one operation at a time
- Auto Solve: Click "Auto Solve" to watch the algorithm run automatically
- Adjust Speed: Use the slider to control auto-solve speed
- Reset: Start over with the current or a new example
Visual Guide
| Element | Meaning |
|---|---|
| Yellow circle | Current pivot position |
| Yellow row highlight | Row containing the pivot |
| Blue row highlight | Row being modified |
| Green box | Final solution |
The Algorithm
Forward Elimination:
- Find a non-zero pivot in the current column
- Swap rows if necessary to position the pivot
- Use row addition to create zeros below the pivot
- Move to the next column and repeat
Back Substitution:
- Start with the last row
- Solve for the variable in that row
- Substitute the known value into the row above
- Repeat until all variables are found
Lesson Plan
Learning Objectives
After using this MicroSim, students will be able to:
- Execute the Gaussian elimination algorithm correctly
- Identify pivot positions and understand their role
- Explain why each row operation is performed
- Apply back substitution to find the solution
Suggested Activities
- Predict the Next Step: Pause before each step and predict what operation will be performed
- Manual Verification: After auto-solve completes, verify the solution by substitution
- Compare Approaches: Note which pivots the algorithm chooses and discuss alternatives
- Error Analysis: What happens if we skip a step or make an error?