Hi,
For your scenario you must to use free goods determination (tcode VBN1). Unfortunately the discount type for free goods don't support different scale type. So create record (use FG category = 2 'exclusive') with scales for your material and specify two additional materials for free goods in the scales (e.g. 1 and 40 minimum quantity) and use simple code in the routine for the calculation type for determining free goods quantity (e.g. free goods quantity (L_FRM-NRMENGE) always equal 1).
If you need to use the cumulative sales for the client for the period of time, you can also use the same routine for the calculation type for determining free goods quantity to calculate the cumulative sales and define the free goods material when you create each order.
Hope it's help.
KR,
Sergey