In general the relationship between safety stock and service level is non-convex. As it contains often a Normal distribution or simulation. If one considers now optimization the supply chain by finding the optimal safety stock over the multiple warehouse system (central/regional distribution chains) one can apply a metaheuristic. Are solvers like Gurobi also possible? But how is the Normal distribution in the classical safety stock service level handled in such cases?

For example we have the classical formula:

Safetystock level $= Z_a \times sigma_d \times \sqrt L$, where

  • $Z_a$ is the inverse cumulative distribution function,

  • $\sigma_d$ is the standard deviation of demand

  • $L$ is the lead time.

Now suppose I want to optimize over a to find the cost minimum (together with other constraints). This is what multi echelon inventory optimization is about. Now this is a non-convex constraint because of the distribution function. But are there models which can optimize something similar to this with Gurobi?

  • $\begingroup$ Welcome to OR.SE. Would you elaborate more on what you are looking for? $\text{SS}$ can be calculated based on the desired service level in each of the stages/echelons of SCM. What you mean by having a (meta) heuristic? Gurobi is an exact solver to solve some mathematical models in an optimal manner. That means you have to formulate your problem based on, e.g. MIP, and give that into the solver to achieve an optimal solution. $\endgroup$
    – A.Omidi
    Aug 4, 2023 at 22:36
  • $\begingroup$ @A.Omidi i added more info $\endgroup$
    – test
    Aug 5, 2023 at 9:44

1 Answer 1


If you would like to take into account the inventory model directly in an optimization model, your problem is more likely classified in the following areas:

  • Multi-Depot Location Routing Problem taking inventory control decisions into consideration

  • Location-inventory problem with risk consideration

For the first and second you can take a look at the following:

Also, I have seen some models that take inventory as a part of the objective function to minimize the related cost. E.g. something like this:

$$ \text{Min} \biggl\{ (\text{deploy cost}) + \cdots + (\text{inventory cost}*z_{\alpha/2}*\sqrt{}\sum\sigma^2*\text{some decision variables}) \biggl\} $$

Please be aware that, solving such a model in an actual situation is challenging work, and also with an appropriate solver that handles the non-convex problems may take a while to solve optimality.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.