Formulas in finding perimeter hexagon