Typescript Call Function From Variable Calculator