trying to implement RegisterCalculationState