First version of transformer calculation.