Event budget ↗
Ticket income, event costs, and the amount left over. Change attendance or adapt the cost rules.
Try it: Add a booking fee or change the cost per guest.
Example
Calculators / Generated Why explanations
A calculator for your own question is only useful if you can check how it got its answer, and an explanation written by hand goes out of date every time the model changes.
Here you write the formulas, controls, and labels in Bosatsu, a typed functional programming language. We generate the page from that program, and the structure of its compiled calculation also supplies the Why view; running it fills in the current values. The same program analysis is behind the site’s other tools.
Small programs you can adapt
Start with a question, write the arithmetic, and choose the controls. These examples use the same generator as the market model. Each source drawer contains both files and a browser compiler.
Ticket income, event costs, and the amount left over. Change attendance or adapt the cost rules.
Try it: Add a booking fee or change the cost per guest.
How much water does one rainfall event collect, and how much overflows the tank?
Try it: Try a different roof size or tank capacity.
Run NOAA weather observations through an inspectable daily tank model. Change capacity and demand, inspect captured data, and share a saved report.
Try it: Increase daily demand, then inspect the day the tank runs dry.
Read the daily model, shared tank model, and report configuration.
Estimate runtime from a battery energy budget, a constant load, and a usable-capacity assumption.
Try it: Compare the same battery powering different devices.
Scale ingredient weights to a different number of servings. Replace the ingredients with your own.
Try it: Replace these ingredient weights with your recipe.
Convert file size and connection speed into transfer time, allowing for a chosen efficiency.
Try it: Compare a faster connection with a smaller file.
It models demand, supply, and a per-unit tax using three straight lines.
The graph configuration declares its intersections and shaded areas. Yichus analyzes those calculations to build the dependency links in Why. The author does not write a separate explanation for each point or region.
These are illustrative Bosatsu models, not forecasts or policy recommendations. Each page runs its actual compiled program. Graph marks and regions have Why controls; scalar results have Why buttons. What-If controls recompute the model.
Click a labelled graph mark, its legend chip, or a shaded region to inspect the compiled calculation behind that visual result. Open the deadweight loss example first to see intersection points and areas on one graph.
These models cover loan payments, compound investment growth, a flat tax rate, and an illustrative carbon footprint. Their output cards use scalar Why buttons. The loan calculator shows the scalar derivation and What-If workflow on a fixed-rate model.
These small programs exercise individual features: captured values, branches, function closures, and rerunning a calculation after an input changes. Use the browser editor to inspect and compile the Bosatsu simulation structure behind these mechanics.
The archive lists earlier UI runtime fixtures.
What this is about: Trace a result to its inputs