Thanks for mentioning your cross post, but if you provide the link to your stackoverflow question, that would be nice.

Where does the variable vaheaeg come from?