Perform arithmetic operation in tpl file

See: Guide to asking for help in this forum