Background
In finding a way to segregate the problem, cost optimizers are typically programmed to process material supply network by material supply network. This is called “decomposition,” which means to “decompose” the problem as described below:
Decomposition in computer science, also known as factoring, refers to the process by which a complex problem or system is broken down into parts that are easier to conceive, understand, program, and maintain. – Wikipedia
SAP has the following comment on decomposition in its help:
Decomposition is a flexible tool for balancing the tradeoff between optimization quality and required runtime. When runtime is unrestricted, the SNP optimizer usually provides a better (optimal) solution without decomposition; however, when a fixed runtime has been specified, using decomposition could assist the optimizer to find a better or, in fact, feasible solution. - SAP Help
Decomposition can take place along a number of dimensions. For instance in SAP SNP, decomposition can take place upon the following dimensions:
- Time
- Product
- Resource
This can be found on the Solutions Methods tab of the SNP Optimizer Profile.

Time, product and resource are all stated differently from one another.
Time Decomposition
Time asks for a window size. SAP recommends using time decomposition and says that it improves solution quality (which is not surprising as problem division tends to improve solution quality). Time is a relatively easy to dimension on which to decompose due to the lack of problems with interdependence. The number of windows breaks down the planning horizon into buckets.
Product Decomposition
The product decomposition is entered as a percentage. This divides the problem into product groups.
Resource Decomposition
This is the only decomposition method in SNP requires more master data in order to implement. The master data of resource priority profiles is then assigned when this is engaged. Of the different decomposition methods, resource decomposition is the least frequently used and the most difficult to understand.
Resource decomposition speeds up the solution process by analyzing the material flow and basic optimizer decisions about production, procurement, and transportation to determine a resource sequence. The optimizer can then create sub-problems for the individual resources, which are solved in sequence. The optimizer makes decisions in every sub-problem that cause the resource to be loaded.- SAP Help
However, one important issue here is how SAP has designed SNP with respect to resources versus how the resources, and more specifically the categories of resources that are used. SAP’s resource setup allows a wide variety of resources to be used, as can be seen from the screen shot below:

However, while many resource categories are possible, the vast majority of SNP implementations only actually constrain on production constraints. Optimization only focuses on or uses constraints which are set to finite. (If not finite, the resource can be used for information purposes, to allow planners to see what weeks are over capacity.)
Because of this fact, the complexity involved in as SAP says “analyzing the material flow and basic optimizer decisions about production, procurement, and transportation to determine a resource sequence,” is a lot more simple than it sounds. This is because if the only resource to be analyzed are production resources, then it really just comes down to combining products that share the same resource together as a sub-problem. Without this, a sequential run of each product (each product that shares the resources as a separate sub-problem, as in the case with product decomposition) would result in one product receiving the resource allocated to its production before another simply based upon the “luck” of the sequence of the product sub-problem being run through the optimizer.
Using Both Product and Resource Decompostion
There are a few interesting things about this comment from SAP with respect to using both product and resource decomposition at the same time.
It is particularly advisable to use resource decomposition if the production processes always load the resources in a similar sequence. Resource decomposition does not reduce memory requirements. If you want to use product and resource decomposition together, the system carries out the resource decomposition first. The product decomposition then tries to improve upon the results of the resource decomposition. – SAP Help
The portion in orange is of course very interesting. It is also surprising, at least to me. If I had been designing the decomposition method with developers at SAP, I would have requested that when both resource and product decomposition are selected, would mean that the system would look at both at the same time. This would in effect increase the size of the sub-problem, as products with shared resources would be included as part of the same sub-problem. This conceptually would be described below:

This type of decomposition solves the issue of resources that are shared across products. It does have the disadvantage of creating a larger sub-problem, however, shared entities that have inter-relationships should be in the same sub-problem. However, SNP does now work that way. Instead, it processes the decomposition sequentially. This cannot possible be as good a solution as the design described above. However, this would seem to be an issue with CPLEX rather than SAP, as CPLEX is the solver doing the work behind the scenes, but this is SAP’s setup, and I have to say, the fact that one optimization does not respect a previous optimization, makes this design looks quite strange to me. In fact, I am unsure if I would use it. This would lead one to perform the decomposition by manually breakup the problem into different runs, which is of course less desire-able and requires extra maintenance effort. Furthermore, the more resources there are, the less feasible this solution would be. Interestingly, I have never read any post or book which criticized SAP’s resource decomposition method before.
Decomposition Benefits
The following quote is instructive with respect to the benefits of decomposition:
Since the existence of many restrictions or – to a higher extent – discrete variables can lead to high computational efforts, SAP APO offers various possibilities to reduce the storage and runtime requirements by dividing the problem into parts. Particularly in the case the supply chain model results in a MILP (mixed integer linear program) problem solver runtimes can get very high; integer models are a consequence of discrete decisions such as modeling lot size intervals. As the implementor does not have direct access to SAP’s mathematical model formulations these methods of handling the solution times are the approximate way of influencing the behavior of the SAP APO optimizer (apart from changing master data that define the coefficients in the model equations). Especially when dealing with large MILP problems the runtime of the algorithm might be cut by decomposing the problem into smaller subproblems. - Real Optimization with SAP APO
Optimization with Integers and Integer Relaxation
While it may appear to be a minor issue, in fact setting a number of the variables to integers in fact greatly lengthens out the run-time, and APO does not have an option for relaxing integer constraint as most other optimizers that I have worked with do.

Here is an example of integer relaxation within the Frontline Solver for Excel. It is set as a default to 5% of integer optimality. This allows the solver to still find a very good solution, but to spend much less time calculating it. Because Frontline Solver is much more frequently used for calculating strategic objective functions with far fewer outputs, relaxing the integer requirement is a much more simple matter than doing so in a supply planning enterprise optimizer which calculates a tremendous number of value as output, all that would have to be adjusted post-optimizer in order to be actionable in the real world.
The concept to integer relaxation is one to solve the problem more quickly for testing, and secondly all of the output (such as purchase orders) could be relaxed within the optimizer, bringing much faster solution times, but with internal rounding. Therefore, 45.3 units would become 50 units in order to meet both the lot size quantity and the integer requirement. (sending .3 of a unit makes great sense from a mathematical perspective, but does not make much sense in the real world. APO could accomplish this with a post optimization rounding routine, but evidently the developers preferred not to go down this track, which means much more hardware is required to run SNP than would have been required if this approach was taken. I am currently writing an article on integer relaxation and I will insert the link to that article here when it is complete.
Josef Kallrath, Thomas I. Maindl go on to describe how the problem decompositions changes depending upon the decomposition selected.
Resource decomposition is based on the analysis of the material flow and the basic decisions about production. After the analysis, sub-problems are developed for the individual resources according to which the resource assignment is generated. With product and resource decomposition priority profiles can be established to determine the sequence in which the optimizer aggregates and plans product groups and resources. - Real Optimization with SAP APO
Time decomposition on the other hand divides the optimization problem by the time horizon.
Finally, there is an option for vertical and horizontal aggregation of planning data where the optimization is dealing with aggregated data.. Vertical aggregation is concerned with product demand and horizontal aggregation deals with subgroups of the supply chain network - Real Optimization with SAP APO
More on Problem Division
While decomposition sounds comprehensive. In fact, this is only one method, and the most automated method of dividing the optimization problem. Another way is to manually divide the problem into different optimization runs. For instance, some companies may use product decomposition, but then divide the problem by product attribute, so that product with similar attributes are run together. This can overlay with how many production facilities there are that produce each type of product. In general the topic of both decomposition and run division is one of the most all encompassing and complex of all the optimization decisions.
Conclusion
Different optimizers have different ways of decomposing the problem. The selection is actively made during the design stage based upon either time, resource or product. Of the three product is the most common, which breaks each sub-problem into a sub-network per product within the overall supply network.
References
“Real Optimization with SAP APO,” Josef Kallrath, Thomas I. Maindl, Springer Press, 2006
http://help.sap.com/saphelp_ewm70/helpdata/en/01/bc044017355c0ce10000000a1550b0/content.htm
SAP Help