It is related because they are at the same place.But the focus is under the earth's crust.
earthquake
The focus and epicenter are both "earthquake points". The focus is the point of origin of an earthquake or underground nuclear explosion while the epicenter the very center or focal point.
the epicenter is where the earthquake happened on top like a city or town, while the focus is where the earthquake happened underground.
with triangulation