Marginal and Cumulative Cost

Harry Ashton
Preview of Marginal and Cumulative CostPreview of Marginal and Cumulative Cost

About this model

This diagram models a system for tracking and calculating the costs associated with upgrading in a game or system, incorporating the concepts of "Upgrade Level", "Cumulative Cost", and "Marginal Cost". At its core, this diagram takes into account the resources spent on upgrades and how these costs accumulate and increase as the upgrade level advances. The system starts with a source node labeled "Gold Spent to Upgrade", indicating the resource input required for upgrading. Resources from this source are directed towards increasing the "Upgrade Level" directly and also calculating the "Cumulative Cost" of upgrades.

As the upgrade level increases, a state connection increases the flow to the "Cumulative Cost" pool by a fixed amount, simulating the accumulation of costs over time. Another crucial component is the "Marginal Cost", which represents the additional cost for each new upgrade. This is adjusted via a state connection that adds a fixed increment based on the cumulative cost, indicating that as more upgrades are purchased, the marginal cost for future upgrades increases. The diagram also includes a drain node, which likely serves to reset or remove resources under certain conditions, although its specific function in this context isn't explicitly detailed by the provided XML. In summary, this diagram elegantly captures the dynamics of upgrade costs in game design, emphasizing the increasing difficulty and resource requirement for successive upgrades.

“Marginal and Cumulative Cost” is a public Machinations diagram by Harry Ashton, shared in the Machinations Community.

You can open the original diagram in the Machinations app, press Play to watch how resources move through it, and change its values to see how the system responds. Machinations is a visual tool for designing, simulating and balancing game economies and other systems, where resources flow through sources, pools, drains, converters and gates.