modified typCalculator.py