added function related libraries and tests