added a simple example on how to use term functions