Find the sum of the areas of the square and the four triangles.
The square has the side length of 3, equal to that of the octagon. Its area is 9.
Each of the four triangles is an isosceles right triangle with hypotenuse length of 3.
Let is combine these four triangles by moving them towards the center, so that their right angles “meet” in one point.
Together these four triangles (or their hypotenuses) form a square with a side length of 3. Its area is also 9.
Hence the combined area of the square and 4 triangles is 9+9=18