Supplier price breaks

Price breaks or volume discounts, represent situations where the margin unit price of goods is varying, depending on the quantity considered for the purchase. Usually, unit prices are decreasing when purchase quantities increase, in order to give the client an incentive to buy more. When suppliers offer price breaks, there is an economic incentive in having purchase quantities correspondingly adjusted to take advantage of those price breaks. Envision offers extensive support for supplier price breaks. In this section, we detail how to model price breaks from the purchasing optimization perspective.

Tabular price breaks

The most frequent way to represent price breaks for a list of products is to have a table with 3 columns:

In order to keep the table readable, when looking at a given product, the lines are typically sorted by quantities in increasing order. This ordering helps making sense of the magnitude of the discounts.

However, once this tabular representation is adopted, there are two distinct way to interpret the price breaks:

The main benefit of the merchant flavor is simplicity. In order to compute the final price, one only needs to look up the applicable unit price, and a single multiplication gives the final price. However, the merchant flavor also yields bizarre pricing effects. In the first example above, purchasing 99 spoons costs 99€, which happens to be more expensive than the 110 spoons priced at 88€. This flavor is frequently found among B2C merchants selling to a diverse crowd.

On the other hand, the main benefit of the fiscal flavor is consistency. There is no way to “game” the pricing, the total price is strictly increasing with the quantity. However, as a major drawback, without an Excel sheet or some kind of dedicated price calculator, it is not possible to reliably compute the final price for a given quantity. This flavor is frequently found among B2B merchants selling to professionals.

In both cases, the price break function - which represents the marginal unit price for any given quantity - can be represented as a zedfunc, a native specialized datatype in Envision that is precisely intended to support these situations.

pricebrk.m(…) and pricebrk.f(…)

The purpose of the pricebrk.m() (resp. pricebrk.f()) function is to transform a merchant (resp. fiscal) price break from its tabular form to its corresponding zedfunc. The Envision syntax is:

ZM = pricebrk.m(T.StartPrice, B.Quantity, B. Price)
ZF = pricebrk.f(T.StartPrice, B.Quantity, B. Price)

Where T is expected to be the table containing the list of products, while B is expected to be an extension of the table T that contains the price breaks - if any. The StartPrice is used as the per unit price until a price break is encountered.

In the case of the merchant flavor, the resulting zedfunc ZM may evaluate to negative values if a situation similar to the example above is encountered.

Ordering space vs. Stocking space

The price break zedfunc is computed from an ordering perspective, reflecting the the marginal purchase price for every purchased quantity. However, from an inventory optimization perspective, we are usually considering the economic reward associated with the acquisition of one more unit of stock, thus taking into account the stock already available. The inventory optimization happens in the stocking space.

Translating the price break zedfunc into the stocking space is straight forward with shift operator >> as illustrated:

ZX = ZM >> (StockOnHand + StockOnOrder)

Where StockOnHand and StockOnHand are expected to be two quantities that are used to reflect the total quantity that must be considered prior to purchasing more of the product.

Stock rewards and price breaks

In a previous section, we have seen how the stock reward function can be associated to economic variables that represent the gross margin, the stock out penalty and the carrying cost. In our previous discussion, those economic variables were plain numbers. However, when price breaks are involved, those economic variables are also varying along with the quantity being ordered. These variations are straightforward to model through zedfuncs, as obtained from pricebrk.m() or pricebrk.f():

expect Demand : ranvar // probabilistic forecast, precomputed
expect Leadtime : ranvar // probabilistic forecast, precomputed

// 'B' is the marginal buy price - in the ordering space
B = pricebrk.m(StartBuyPrice, Breaks.Quantity, Break.Price)

// shifting 'B' - now expressed in the storage space
B = B >> (StockOnHand + StockOnOrder)

// M, S and C are zedfuncs
M = SellPrice - B
S = -0.5 * (SellPrice - B)
C = -0.3 * B * mean(Leadtime) / 365

RM = stockrwd.m(D, 0.3) * M // margin (quantity dependent)
RS = stockrwd.s(D) * S      // stock-out penalty
RC = stockrwd.c(D, 0.3) * C // purchase

// 'R' is the marginal economic reward for every stock position
R = RM + RS + RC

At lines 11-13, the economic variables are turned into zedfuncs. When a number is added (or multiplied) to a zedfunc, the result of the operation is a zedfunc. Thus, M, S and C are zedfuncs as being the results of operations that involve B a zedfunc.

Yet, while we are operating on zedfunc, it’s notable that the economic calculation remain unchanged. Under the hood, point-wise operations are performed over zedfuncs rather than numbers, but this complexity is completely taken care of by the algebra of zedfuncs itself.

Finally, at line 15, the final stock reward is composed just as we did in the previous section.