Examples
Examples
Try the starting example
- Participants (count)
- 12
- JSON Materials [ID,units per kit,available units,integer pack size]
- [["brush",2,10,5],["paper",5,30,20]]
- Material shortages (units)
- [["brush",14],["paper",30]]
- Purchase packs by material
- [["brush",3],["paper",2]]
- Leftover units after purchases
- [["brush",1],["paper",10]]
Try another scenario
- Participants (count)
- 16
- JSON Materials [ID,units per kit,available units,integer pack size]
- [["brush",2,10,5],["paper",5,30,20]]
- Material shortages (units)
- [["brush",22],["paper",50]]
- Purchase packs by material
- [["brush",5],["paper",3]]
- Leftover units after purchases
- [["brush",3],["paper",10]]
Calculation method
Calculation method
Material shortages (units)
J([[r[0],max(0,a*r[1]-r[2])] for r in b])
Purchase packs by material
J([[r[0],ceil(max(0,a*r[1]-r[2])/r[3])] for r in b])
Leftover units after purchases
J([[r[0],r[2]+ceil(max(0,a*r[1]-r[2])/r[3])*r[3]-a*r[1]] for r in b])
Symbols and units
- a
- Participants (count)
- b
- JSON Materials [ID,units per kit,available units,integer pack size]
Use the units shown. A list keeps the order in which you enter its values. The symbol ^ means “raised to the power of”.
Assumptions & limits
Assumptions & limits
- One explicit workshop kit per participant. Positive pack sizes, stock/requirements same units; materials specification supplied. Supported limits: All numeric inputs must be finite. Only the explicitly described mathematical scenario is supported.
Are these inputs private?
These calculations run in your browser. A shared link contains the values you choose to share. Only questions submitted to the separate AI finder are sent to OpenAI.