For real numbers $a$ and $b$, define
$$f(a,b) = \sqrt{a^2+b^2+26a+86b+2018}.$$
Find the smallest possible value of the expression $$f(a, b) + f (a,-b) + f(-a, b) + f (-a, -b).$$
1. **Rewrite the function \( f(a, b) \):**
   \[
   f(a, b) = \sqrt{a^2 + b^2 + 26a + 86b + 2018}
   \]
   We can complete the square for the terms involving \(a\) and \(b\):
   \[
   a^2 + 26a = (a + 13)^2 - 169
   \]
   \[
   b^2 + 86b = (b + 43)^2 - 1849
   \]
   Substituting these into the function:
   \[
   f(a, b) = \sqrt{(a + 13)^2 - 169 + (b + 43)^2 - 1849 + 2018}
   \]
   Simplifying inside the square root:
   \[
   f(a, b) = \sqrt{(a + 13)^2 + (b + 43)^2}
   \]

2. **Rewrite the other functions similarly:**
   \[
   f(a, -b) = \sqrt{(a + 13)^2 + (b - 43)^2}
   \]
   \[
   f(-a, b) = \sqrt{(a - 13)^2 + (b + 43)^2}
   \]
   \[
   f(-a, -b) = \sqrt{(a - 13)^2 + (b - 43)^2}
   \]

3. **Interpret the problem geometrically:**
   Consider the points \(A(13, 43)\), \(B(13, -43)\), \(C(-13, -43)\), and \(D(-13, 43)\) on the Cartesian plane. The function values represent the Euclidean distances from a point \(P(a, b)\) to these points:
   \[
   f(a, b) = PA, \quad f(a, -b) = PB, \quad f(-a, b) = PC, \quad f(-a, -b) = PD
   \]

4. **Minimize the sum of distances:**
   The sum of distances from a point \(P(a, b)\) to the vertices of a rectangle (or square) is minimized when \(P\) is at the center of the rectangle. The center of the rectangle formed by \(A\), \(B\), \(C\), and \(D\) is \((0, 0)\).

5. **Calculate the minimum value:**
   When \(P = (0, 0)\):
   \[
   f(0, 0) = \sqrt{(0 + 13)^2 + (0 + 43)^2} = \sqrt{13^2 + 43^2} = \sqrt{169 + 1849} = \sqrt{2018}
   \]
   Therefore:
   \[
   f(0, 0) + f(0, 0) + f(0, 0) + f(0, 0) = 4 \cdot \sqrt{2018}
   \]

6. **Conclusion:**
   The smallest possible value of the expression \( f(a, b) + f(a, -b) + f(-a, b) + f(-a, -b) \) is:
   \[
   4 \sqrt{2018}
   \]

The final answer is \(\boxed{4 \sqrt{2018}}\).