Fixed SAP, confirm that the algorithm actually worked.