adding Thomas calendar code