# Optimization on 3D DC inversion

**URL:** <https://simpeg.discourse.group/t/optimization-on-3d-dc-inversion/722>\
**Category:** DC and IP\
**Created:** [June 4, 2025, 9:28am UTC](https://simpeg.discourse.group/t/optimization-on-3d-dc-inversion/722 "2025-06-04T09:28:14Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![fabioca](https://avatars.discourse-cdn.com/v4/letter/f/c68b51/32.png) [@fabioca](https://simpeg.discourse.group/u/fabioca)\
**Post date:** [June 4, 2025, 9:28am UTC](https://simpeg.discourse.group/t/optimization-on-3d-dc-inversion/722/1 "2025-06-04T09:28:14Z")

</div>

Hello, I am using SimPEG to invert 16 dipole-dipole profiles for 3D structure. I basically work on the tutorial script: [3D Least-Squares Inversion of DC Resistivity Data — SimPEG 0.24.0 documentation](https://docs.simpeg.xyz/v0.24.0/content/user-guide/tutorials/05-dcr/plot_inv_3_dcr3d.html) My problem is that the inversion is too slow on my data (a lot of them). Is there a way to optimize it? (Of course I can play around the mesh, but data are many. is there a better solver or a way to ue a not python-native one)? thank you

---

<div class="post-metadata">

**Author:** ![santisoler](https://yyz2.discourse-cdn.com/free1/user_avatar/simpeg.discourse.group/santisoler/32/210_2.png) [@santisoler](https://simpeg.discourse.group/u/santisoler)\
**Post date:** [June 5, 2025, 6:18pm UTC](https://simpeg.discourse.group/t/optimization-on-3d-dc-inversion/722/2 "2025-06-05T18:18:57Z")

</div>

Hi @fabioca. First I would make sure that you are using a fast solver, such as Pardiso or MUMPS.

You can pass a solver class to the DC simulation (`dc.simulation.Simulation3DNodal`). And you can obtain the default solver based on your system and the ones you have installed through the `get_default_solver` function. For example:

```python
from simpeg.utils.solver_utils import get_default_solver

solver = get_default_solver()
print(solver)

dc_simulation = dc.simulation.Simulation3DNodal(
    mesh, survey=dc_survey, sigmaMap=conductivity_map, storeJ=True, solver=solver
)

```

If the solver you are using is `pymatsolver.SolverLU` or `pymatsolver.Solver`, your simulation will definitely have a poor performance. Using Pardiso or MUMPS should greatly improve that.

Hope that helps!
