Consider the following demand of products for the next four months.
data={1,20,3,40};
I could produce the whole demand in the first months, leading to the following "production vector": {63,0,0,0}.
As you can imagine, producing everything in the first month leads to high costs of inventory. Another possibility would be {21,0,43,0}.
Now I would like to get all possible combinations of the subsets of data, leading to:
results=
{{{1},{20,3,40}},
{{1,20},{3,40}},
{{1,20,3},{40}},
{{1},{20,3},{40}},
{{1},{20},{3},{40}},
{1,20,3,4}
}
It is important that Table[Map[Flatten,results][[i]]==data,{i,Length@results}] is True for all i. This means that each sublist of results has the same order of figures as in data.

dynPworks. From what I readAccumulate@pcreates a list of partition points, specifically the end points of the sublists.{0}~Join~Most@#shifts the list of points to the right, adding1to which creates the start points. Then it is just a matter of supplying those values toPart. – rcollyer May 08 '12 at 02:55dynPfunction does. Do remember what it is? Perhaps we can use that instead and just leave a link to the Toolbag post for prior version users. – Mr.Wizard May 08 '12 at 05:34Internal`PartitionRagged, which for version 8 is indeed equivalent to yourdynP. Actually I've never had cause to use it personally, but Andy Ross mentioned it here. – Oleksandr R. May 08 '12 at 18:15Internal`PartitionRaggedwe needDeveloper`ParitionMapRagged. It would be very useful. – rcollyer May 15 '12 at 16:25