Wouldn't you need to know the angles of the triangle for that?
Right triangle assumed, same as needed for the equation to work.