move the calculation to the entity