# Safety stock for lumpy demand

I have a product for which the monthly demand pattern for the last year looks like the following. The product is ordered only 22 days out of 366 days in batch sizes of 272 kgs. Since there are so many months with 0 demand, the demand distribution is heavily skewed. The mean and standard deviation come out to be 634 and 1167 (rounded off), respectively. I have been using this formula (which is the most widely used, I believe) for calculating the safety stock- $$SS = z_\alpha\sigma_{LTD}$$ where- $$\sigma^2_{LTD} = \mu_L\sigma_D^2$$ Taking a lead time of 2.8 months and z = 2.33 (99% Service Level), I get SS = 4550 kgs. Now it doesn't make sense to hold 4550 kgs of inventory when the demand is so lumpy. I know that the above formula is best suited for demands that are approximately normally distributed and understandably results in really high SS values. This is a problem I have been facing with multiple products for which there are several months with very little demand or 0 demand. What is the best way to optimize the inventory for items with lumpy/erratic demand and calculate the safety stock and reorder points for the future?

Just like any other demand distribution (e.g., this one), you want to set the base-stock level ($$S$$) equal to $$F^{-1}(\alpha)$$, where $$F(\cdot)$$ is the cdf of the lead-time demand distribution and $$\alpha$$ is the desired service level; and then the safety stock is given by $$SS = S - \mu_{LTD}$$.

(In the case of normal demand, as in your question, $$F^{-1}(\alpha) = \mu_{LTD} + z_\alpha\sigma_{LTD}$$, so $$SS = z_\alpha\sigma_{LTD}$$, as you said.)

So, my recommendation is to fit a distribution $$\hat{F}$$ to your demand data and then set $$S = \hat{F}^{-1}(\alpha)$$ and $$SS = S - \mu_{LTD}$$. In your case, the demand distribution will have a point mass at 0.

You can set $$\mu_{LTD} = L \mu_D$$ and $$\sigma_{LTD}^2 = L\sigma^2_D$$ (where $$\mu_D$$ and $$\sigma_D$$ are the mean and SD of the demand per period and $$L$$ is the lead time). But you could also try to estimate these directly from the data, e.g., estimate the mean and SD of the demand over an $$L$$-period stretch.

By the way, there is some literature on this topic. A Google search for "inventory optimization lumpy demand" or something similar will turn up some hits that are probably more rigorous and general than my approach.

• So the probability mass function is as follows: {'0'= 0.67, '815.85' = 0.167, '2447.5' = 0.083, '3535.35' = 0.083}. I can construct a discrete cumulative distribution function using this pmf. I am not sure how to proceed from here. Since the data is so sparse, would it be feasible to fit a continuous distribution without overestimating the mean and variance? – Nishant Kumar Gupta May 27 '20 at 8:49
• @NishantKumarGupta, would you please, see this link. According to your data, neither of the distribution functions can fit the demand data exactly and estimating of the mean and SD is too hard. I think the method that LarrySnyder610 mentioned should be a good point. – A.Omidi May 27 '20 at 11:49
• @A.Omidi I can construct a discrete pdf from this data to get $F(x) = 0.916$ for $2447\leq x<3535$ and $F(x) = 1$ for $x \geq3535$. Suppose I choose a 95% service level, The inverse using this cdf would say that $2447\leq x<3535$. If I take x to be equal to the mean of the two values i.e. $x=2991$, this would act as my base-stock level S. I can then subtract the mean demand (634) to get SS = 2357. Is this the approach that LarrySnyder610 is suggesting? I agree that fitting a continuous distribution would be way off considering the sparsity of the data – Nishant Kumar Gupta May 27 '20 at 14:12
• @Nishant, thanks. I try smoothing the data by dividing them based on available months till to delivery month. For example, we need to deliver $815$ items in the third month and dividing this demand based on the batch size during these months. This method helps produce little batch instead of the whole delivery and may be reliable to chase customer demand. About the second question, the goodness of fit analysis was created using Excel and Minitab software. :) – A.Omidi May 28 '20 at 9:36
• @NishantKumarGupta I would say that the 0s should be part of the data set, not separated out. You don't need the mean and SD explicitly, you only need the cdf, and the 0s are part of that cdf. As for "planned" vs. "unplanned" 0s that's a trickier issue. I think you are in uncharted waters to some extent. – LarrySnyder610 May 29 '20 at 14:49