Run time of fenics adjoint

You can define an LUSolver, as shown here: Minimeze function in Navier-Sokes's problem - #2 by dokken
If A1 does not change per time step, you should only assemble it once, otherwise you can use assemble(a, tensor=A1)
Without a minimal code example illustrating what you are doing (that can reproduce your timings, I cannot offer you any more guideance

1 Like