Marginal values and stream values
- Last UpdatedAug 11, 2025
- 12 minute read
Marginal values
After optimization, any constrained properties which have reached a boundary of their constraint will show marginal values. Marginal values, also known as shadow prices, show the economic benefit or penalty of violating a constraint.
To show marginal values after optimization, ensure they are enabled in Run Settings.
Example: In a supply chain model the CDU might have a capacity limit of 100,000 bbl/day. In many models the CDU will always run at full capacity, so the final solution will have a CDU usage of 100,000 bbl/day. During the optimization the optimizer can calculate the effect of violating this constraint and find the economic value when the CDU is running at 100,001 bbl/day. This difference between the final constrained value, and the potential value if violated, is the marginal value. If a hydrotreater has a maximum capacity of 30,000 bbl/day and runs at 25,000 bbl/day there is no marginal value for the capacity constraint, because the property is not at its limit.
The scale of the marginal value is important in indicating which constraints are significantly affecting the operating margins of the plant. For example, if two crudes Lokele and Maya were at their maximum purchase amounts in the final solution, and Lokele had a marginal value of 5 $/bbl and Maya had a marginal value of 0.52 $/bbl, this indicates that obtaining more Lokele will potentially lead to greater operating margins than by obtaining more Maya.
Take care when interpreting the unit of measure, when comparing marginal values between different types of constraint. For example, if comparing the marginal value of purchasing more Lokele versus the marginal value of operating the crude unit with a greater throughput, the absolute value of the marginal value must be used alongside the unit of measure of the marginal value to make the comparison fair.
The default unit of measurement (UoM) of a marginal value is:
-
For Plan, $/day per constraint UoM (for example, $/d/tonne).
-
For Network, $ per constraint UoM (for example, $/tonne).
-
Blending Specifications: $/day per constraint UoM.
-
Inventories: $/UoM.
-
Purchases, Sales, Supplies and Demands: price for UoM shown.
Negative marginal values
During the optimization, you may find that the optimal solution involves not purchasing a particular material. For example, the final solution may have a purchase of Dalia of 0 bbl/day. That is, it is not economically advisable to run this crude. However, during the optimization the optimizer will have calculated the effect of purchasing one unit of material. Thus for this constraint (the constraint here being that the purchase amount cannot be less than zero) it is also possible to see the effect of processing the material. In this situation the marginal value will have a negative number, meaning it is not economically advisable to violate that constraint. For Dalia, the negative marginal value would indicate that, if you were forced to process the crude, the operating margin of the refinery would be reduced by the amount shown per unit of crude. If Dalia had a purchase amount of 0 bbl/day and a marginal value of -0.67 $/bbl/d, then processing 1 bbl/day of Dalia would reduce the final objective function by $0.67.
Extent of marginal values
A CDU of 100,000 bbl/day capacity reaching this constraint may report a marginal value of $3 per bbl. This means that, if the capacity can be increased to 100,001 bbl, the objective function can be increased by $3. However, it does not hold true that increasing the capacity further from 100,001 bbl to 100,002 bbl will result in another increase of $3. A marginal value is only true at the constraint limit, and does not extrapolate linearly past the constraint.

As the constraint is increased, it is normal for the scale of the marginal value to decrease up until a point where the constraint is no longer limiting. At this point there is no marginal value: the objective function will not change as the constraint is widened further. While this fall off in marginal value is generally true, the behavior does not always occur and complex interactions of constraints can combine to affect the marginal values in other ways.
In the diagram below, the normal feasible area is indicated in yellow and bounded by constraint 3. If it were possible to violate constraint 3, the objective function value would increase. Thus constraint 3 has a positive marginal value. The green lines each indicate valid solutions (with constraint 3 being ignored) and so step changes increase the objective function by an amount equal to the marginal value.

However, once that constraint 3 is relaxed too far, constraint 2 becomes significant. If we relax constraint 3 to the red line, this is outside the yellow region of feasible space as constraint 2 is now validated. Thus the marginal value on constraint 3 does not extend as far as the red line.
Determining how far a constraint can be pushed is not trivial, as the problem can be significantly non-linear. Use of the Sensitivity analytic may help determine the extent of marginal values and the constraints which next become significant.
Marginal values and degenerate problems
Degeneracy can affect the calculation of marginal values. Degeneracy happens when one or more constraints are redundant. For example, in the following figure the flow2 constraint is redundant, since the flow is already limited by the constraint on flow1.

Redundant constraints are ignored, which means that their marginal values will be missing, and marginal values on other constraints may be overestimated.
Zero-flow problems are particularly affected, since many constraints become irrelevant when there is no flow.
The missing marginal values are recovered by default via finite perturbation analysis.
Stream values
Stream values show the change in objective function for forcing in an extra unit of each particular stream. In other words, a stream value shows the price that should be paid for importing an extra amount of the stream. A stream value can often be thought of as the break-even price of the particular stream, that is, the maximum price that should be paid for a unit of the particular stream.
Differences between stream values and marginal values
Stream values and marginal values are both obtained directly from the optimized solution. Marginal values are returned from the relevant constraints, whilst stream values are obtained as the marginal values on material balance equations.
Marginal values are obtained only for active constraints, and show the incremental objective function change in relaxing each problem constraint.
Stream values represent the increase in objective function value if one were able to procure an additional unit of material from an outside source at no cost. Stream values only apply at the current solution value (as they are based on marginal values which may not extend significantly beyond the current solution value) and always take into account the constraints that exist within the model.
Negative stream values
In some instances, streams may have negative stream values. Where the sale is at its maximum, extra material procured from outside must displace the original material and the components must find an alternative disposition. On some occasions there are no other dispositions, so a reduction in component implies a reduction of throughput, possibly on the whole plant. As such value is lost from all of the other product pools.
For example imagine that kerosene was only routed to jet fuel, and the jet sale was at a maximum. Buying an extra unit of jet, and still using the maximum sale constraint, would mean that less kerosene would have to flow to the jet pool. If the kerosene can only go to the jet pool, a reduction in kerosene in the current solution would mean a reduction in kerosene flow, which would mean a reduction in crude unit throughput. As reducing the crude unit throughput would also reduce the amount of sale of other products, this would reduce the overall profitability of the plant. As such, the jet purchase would have a negative stream value.
Stream values in modes
Where a stream has multiple modes, these modes may have different stream values, as the stream in each mode will have different qualities and so contribute differently to the final products.
Imagine a CDU has two modes, a default mode and a winter mode. Kerosene from the crude unit goes directly to jet fuel and only to jet fuel. Within a planning cycle both modes are active but kerosene from the default mode is not capable of making jet - therefore the qualities of the kerosene in the winter mode have to compensate so the final blend is on-spec. However, the default mode is more profitable and so preferred.
In this configuration the kero in the default mode has a value less than the price of jet, whilst the kero in the winter mode has a value greater than the price of jet. The material in the default mode is worth less than jet because if you purchase this material you have to produce more winter jet (to offset the poorer qualities of the default jet) but this makes less money overall (because the winter jet mode is less profitable). The material in winter mode is worth more than jet because if you purchase this material you have to produce less winter jet (as you get the extra qualities of the winter jet from the purchase without needing the unit of production from the CDU) so overall this makes more money (because by having to produce less winter jet you can produce more default jet whose mode is more profitable).
Understanding stream value breakdowns
Imagine the following simple blend. You can purchase LSFO (200 $/tonne with 1% sulfur) and HSFO (100 $/tonne with 2% sulfur). These can be blended to form a product with a value of 250 $/tonne and a maximum sulfur value of 1.5%. You also have a constraint on the amount of LSFO you can purchase of 100 t/d.


In your default scenario, you purchase 100 t/d of LSFO, and can purchase another 100 t/d of HSFO until you reach the maximum sulfur limit of the product. That is, you have 200 t/d of product, giving you a net profit of 20,000 $/d.

To calculate the stream value for LSFO, you introduce an extra unit of this material. The stream value comes from both the flow of material and the properties of the material. For the flow component, you introduce an extra unit of material only and this material has no cost. Thus, you increase the amount of sale alone, and do not affect the material properties. As this material has zero properties, in practice it dilutes the total sulfur pool. In effect, you can buy an extra 3 t/d of HSFO (but you do not have to buy this). So the net effect of introducing this extra tonne of material is that your objective function value increases to 20,000 $/d. Thus, the extra value of this material flow is 700 $/t.

To calculate the property value for the LSFO, you introduce an extra unit of sulfur alone. Now the flow does not change but, in effect, the sulfur content of the LSFO has increased. The extra unit of sulfur is equivalent to the sulfur content of 1 tonne of material, so you have 101 tonnes worth of sulfur, but this is only present in 100 tonnes of material. Thus, the LSFO has effectively increased to 1.01 % S. As the LSFO has more sulfur, you cannot purchase as much HSFO, so your overall sales decrease. The profit decreases to 19,700 $/d. Thus, the effect of the sulfur alone is a change of -300 $/tonne.

A stream value can have a direction, either upstream or downstream. When the direction is downstream, then the value of the stream itself is derived downstream of the point the material is injected. For example, injecting an extra unit of LSFO means that extra fuel oil product can be sold downstream of the point of injection. Therefore, the value of the stream is obtained downstream of the point of injection.
In some circumstances, injecting extra material into the system means that other material can be re-routed. Imagine that a kerosene hydrotreater was working at maximum capacity. Injecting extra kerosene material prior to the hydrotreater would mean that the crude derived kerosene would have to be re-routed. If there was a swing cut, this could be instead routed to the naphtha hydrotreater (as long as this is not at maximum capacity) . Thus, the value of the swing would be obtained upstream of the point of injection. Note, overall, the material would have a negative stream value (as backing of crude kerosene implies a reduction in overall throughput). However, the swing cut yield component would be positive.
Stream value details
Immediacy
Streams have values everywhere in the flowsheet. However, the elements of the stream that contribute to that value are only determined immediately where they have an effect.
Suppose the red material in the image below has a stream value of $10, and the entire material goes downstream. This material has a flow contribution of $8 and a property contribution of $2.

Suppose also that all the green material goes via the top splitter route to the mixer. The green material has a stream value of $10, however, this material only has a flow contribution. The green material does not have property contributions, because its effect on properties are not seen immediately before the splitter. The effect of the properties only occur when these properties interact with the other streams at the mixer.
Tanks
The streams either side of a tank will often have a different stream value breakdown (although the total value will be the same if no inventory is involved). The output of the tank may interact with other streams and properties, and thus have a breakdown in terms of flow and property. The input to the tank will always only have a flow contribution, as the stream will never have an immediate effect in terms of its properties.
Blenders
For blender inputs, stream values are only seen in terms of flow. This is due to the complex internals of the blender, which can be imagined as a series of mixers and splitters, where the input stream is split into multiple outputs and then mixed with other steams originating from other 'splitters' (that is, blender inputs). The stream value is shown prior to this mixing, and splitting the effect of the stream is not immediate. It therefore only has a flow contribution. As the internal routing of the blender cannot be seen on the flowsheet prior to the internal mixers, it is not possible to show this internal stream value breakdown in terms of properties.
For example, the flow stream values in the diagram below will be available on the inputs to the blenders; the contributions from properties are present on the internal streams only and cannot be viewed within the application.

Directionality
You can direct your streams upstream, downstream, or a mixture of both.
-
Downstream. In this situation, the flow and property contributions of the stream all occur due to the downstream processing of the material. For example, the free unit of material directed to a process unit not at capacity would be processed by this unit, and create extra product downstream.
-
Upstream. In this situation (which usually occurs when the asset to which the stream is flowing is at maximum capacity), the material can often be refunded or directly routed to a different destination. Other aspects of the plant can then change to counteract this re-direction. The properties of such a stream may have a positive or negative contribution, depending on the quality of the stream. Such contributions are all seen upstream of the unit, as they allow operations there to counteract the re-direction.
-
Downstream and upstream. In this situation, the addition of the material allows other elements of the plant located in the other direction to the flow to change due to the effect of the stream's properties.
Missing values
Streams with zero flow have no stream value, as their values cannot be reliably determined. Stream values are not reported on streams where the pipe is depooled within the process unit to multiple process models.