Find the optimal order size to minimize total inventory costs.
Optimization Analysis
Optimal Order Size
0
Orders Per Year
0
Order Cycle (Days)
0
Total Annual Cost
$0
Understanding Inventory Optimization (EOQ)
In supply chain management, the Economic Order Quantity (EOQ) is the ideal order quantity a company should purchase to minimize its total inventory costs, such as holding costs, shortage costs, and order costs. This mathematical model is the foundation of efficient inventory optimization.
The Mathematics of the Model
The optimizer uses the Wilson Formula to find the point where the cost of carrying an extra unit of inventory perfectly balances the cost of placing a new order. The formula used is:
EOQ = √[(2 × D × S) / H]
D: Annual Demand (Total units sold/used per year)
S: Setup or Ordering Cost (Fixed cost per transaction)
H: Holding Cost (Storage, insurance, and capital costs per unit per year)
Why Optimize Your Inventory?
Without proper optimization, businesses often fall into two traps: overstocking or stockouts. Overstocking ties up valuable capital in warehouse space and risks product obsolescence. Conversely, ordering too frequently leads to excessive administrative and shipping expenses.
Practical Example
Imagine a retailer that sells 5,000 units of a specific electronic gadget annually. It costs $40 to process an order, and the cost to store one gadget for a year is $5. Using the optimizer:
Annual Demand: 5,000
Order Cost: $40
Holding Cost: $5
Result: The optimal order size is 283 units. The retailer should place roughly 18 orders per year (every 20 days) to achieve the lowest possible overhead.
function calculateOptimization() {
var demand = parseFloat(document.getElementById('annualDemand').value);
var setup = parseFloat(document.getElementById('orderCost').value);
var holding = parseFloat(document.getElementById('holdingCost').value);
var days = parseFloat(document.getElementById('workingDays').value);
if (isNaN(demand) || isNaN(setup) || isNaN(holding) || isNaN(days) || holding <= 0 || demand <= 0) {
alert("Please enter valid positive numbers for demand, cost, and working days.");
return;
}
// EOQ Formula: sqrt((2 * Demand * SetupCost) / HoldingCost)
var eoq = Math.sqrt((2 * demand * setup) / holding);
// Derived Metrics
var annualOrders = demand / eoq;
var cycleTime = days / annualOrders;
// Cost Analysis
var annualOrderingCost = annualOrders * setup;
var annualHoldingCost = (eoq / 2) * holding;
var totalCost = annualOrderingCost + annualHoldingCost;
// Update UI
document.getElementById('resEOQ').innerHTML = Math.round(eoq).toLocaleString() + " units";
document.getElementById('resOrders').innerHTML = annualOrders.toFixed(2);
document.getElementById('resCycle').innerHTML = Math.round(cycleTime) + " days";
document.getElementById('resTotalCost').innerHTML = "$" + totalCost.toLocaleString(undefined, {minimumFractionDigits: 2, maximumFractionDigits: 2});
document.getElementById('optimizationResults').style.display = 'block';
}