Hello,
Search on SCN or else go through SAP Help once. You will understand the concept behind generating settlement rules.
Please refer my reply from this discussion,
and SAP FAQ note 1929029 - FAQ: Settlement rules in production order
All the best.
Best Regards,
R.Brahmankar