Calculating the displacement of a fault
The process is carried out by solving an "inverse problem" and there are many ways to estimate the moment depending on the observable. For example if you have some measurements of ground deformation following the earthquake (using GPS/InSAR) then by combing a physics based model, with an optimizer, you can estimate the area/slip distribution that best explains the observations. Once you know the area/slip distribution then you can estimate the moment.

The physical models can be simple or complex (e.g., semi-analytical or fully numerical). Same goes for the optimizer (local or global). For computationally expensive numerical models global optimization is typically not feasible. For local optimization you need a 'reasonable' initial model.