Not really - if I just run
ac = Acomputer{ForwardDiff.Dual{ForwardDiff.Tag{Turing.TuringTag, Float64}, Float64, 1}}(zeros(2), 3.0)
then it ac will be of the correct type, s.t. all the internal parameters are of the correct type, i.e. Dual numbers. As far as I understand this is prerequisite to make AD possible. The above error only occurs when I want to optimize the model.
But probably there is also another way to achieve what I want to do.
In principle: My model is computationally expansive and allocates a lot of memory. I want to circumvent that subsequent model calls always (re)allocate this memory.