Recalculate Formula Fields Dynamically (without save)
From the Documentation: Recalculates all formula fields on an sObject, and sets updated field values. Rather than inserting or updating objects each time you want to test changes to your formula logic, call this method and inspect your new field… Read More »Recalculate Formula Fields Dynamically (without save)