 # Recursiveness allowed with Material Ledger

Hi Friends.

### Recursiveness is a natural phenomenon. Exists in nature, exist wherever.  If you study science, i guess you know about Fibonacci sequence. If you study Photography, i guess you know the Rule of Thirds or Golden Rule. If you see a a sunflower, you are watching recursion. And of course, if you work with SAP Costing, there are some recursive process.

A typical example is a Production Order, if the Header Material is also a Component. OK, now lets think about ML Close. There is a step named ‘Multilevel Price Determination’. In this step, the lower level price difference go to the upper levels. Sounds easy! but, if a material is lower and upper level of itself, what happen?

1. You buy 1000kg at \$100/kg and arrive to your storage location.

2. This night, a storm dump the storage location. 300KG looks damaged, but QM girls are not sure.

3. Next day, QM tell PP boys create a order to select good product. PP do 300kg good issue, and found only 100KG are good. This is my MM Kardex (tcode MB51) 4. At period end closing, CO boys found this order… Always at Period end 😛 !!  This is the screen of CKM3N: Lets analyze the scenario:

A. Procurement actual cost is 100.000. No Price Difference here.

B. If I buy 1000kg, consume 300kg in the rework order and only 100KG are good product, my end stock = 1000 -300 + 100 = 800. C. If I assume the Labor is Free (today i dont want to put things difficult), the Ending stock is valuated ad 100.000 (no aditional costs) and the Unit Cost is

100.000 / 800 = 125 That was easy!!

D. now, think abut the consumption. You consume 300 KG, and guess you expect  \$30.000  This is the value in the preliminary valuation. now we ask what are this \$7500 of price difference ? this value dont make sense. Here come 2 questions:

D.1  Why the actual cost of the consumption is 37.500 and not 30.000?

D.2  In what way the System calculate this value?

E.  The response to D.1 is easy if you understand the concepts of ML. You valuate the Ending Stock at the Monthly Average. The PP Order is not revaluated (so sad), the PRD accounts are cleared directly in FI. Im not going to explain the detail of the FI posts (if any of you want the explanation, i can doit).

F. This is the screenshot of the CKM3N at the time of the Single Level step. Check the Produced 100 unit of the rework Order are valuated at 10.000 + 20.000 = 30.000 Here is the cost detail of the order: Actual Cost of the Order = 30,000

Good Receipt = 10.000 (valuated at Standard)

Settlement = 30.000 – 10.000 = 20.000 >> This si the Price Difference in the Single Level Step

G. The Multilevel Step add 7.500 This is Revaluation from Lower Levels… in other words, here is Recursiveness!! H. Now, the the response of D.2  How the system calculate this value ? Could you calculate this Value?  Its not difficult. there are lots of ways to solve the equation. If you study computer science in the university, i guess you face this kind of problems. Im going to solve the equation in XLS with a iterative algorithm Im going to calculate the Actual Value Column, but calculate the Receipt from lower levels is the same stuff… and yes, in Excel 🙂 .

I Did 12 iterations, with 2 decimals detail to arrive the exact values of my CKM3N. My algorith is the following:

+ Procurement is constant.. because there is no price difference.. you just buy the vendor

+ Production Cost i = Consumption Cost i-1

+ Cumulated Stock i =  Procurement i  + Production costs i

+ Unit Cost i = (Cumulated Stock i)  / 1100

+ Consumption i = 300 * Unit Cost i

+ End Inventory i = 800 * Unit Cost i

This is my excel Production[i=6] = Consumption[i=5] = 37.448,68

Unit Cost [i=6] = (37.448,68 + 100.000) /  1100 = 124.99

Here, you can compare side by side my XLS and CKM3N. No tricks, just maths.

Iteration 12 show the exact values of CKM3N in multilevel Step.

Iteration 1 show the exact values of CKM3N in Single Level Step (Check Leter F).

Thats is!

If you read this lines Im very proud of you!

PS1. I just show the way the system is designed and the calcs.

PS2. Some of customers are not fully agree with this behavior. Im not going to give my opinion.

Glossary:

ML: Material Ledger

Recursion, see Recursion.

### Assigned Tags

You must be Logged on to comment or reply to a post. Hi Arturo,

thanks for the explanation, you are the only person that could explain this case.

I'm working in a project on a winery company in Chile, and i have this scenario of recursiveness.

That's why I want to ask you a few questions:

1) Is there any way to avoid these price differences from lower levels produced by this recursive production orders?

2) We have a lot of production orders with recursiveness, and this produces a long time run in the multilevel price difference at Cost closing (CKMLCP), is there any way to avoid this?

3) There are some materials that this lower level price differences causes a negative price determination. so we can't distribuite  differences for this materials.

I Know you're a Gurú in this, so i want to ask for your help if you have some ideas to solve in anyway these problems 