plug in calculations