Hi
Correct way to do the process is as below.
Get damaged or unplanted material return as it is with 542 movements. If you have send material with 57 f4 challan do reconciliation & completion with document no of 542 movements.
Scrap material with 551 movements.
Raise credit memo in MIRO (manual) as per your calculation on respective subcontracting vendor.
Regards
Gadgil D.R.