added function for triangle area calculation