How to minimize time complexity when executing FEM on a highly refined mesh?

Use a different solver, for instance mumps, or an iterative solver. See UMFPACK V5.7.8 (Nov 9, 2018): ERROR: out of memory with a non variational 3d problem - #2 by dokken
Fast computation of a large system of PDEs - #2 by dokken