# Hold Values of DensityPlot to use for an other DensityPlot

I have two surface functions, f[x,y] and g[x,y]. Assuming that the DensityPlot of f and g takes a while, is there a way to hold the values of DensityPlot, to efficiently DensityPlot f[x,y]-g[x,y] ?

I'm aware that the mesh used by DensityPlot for the two functions f and g is not necessary the same, depending on variations of these functions. However, maybe it is possible to inform DensityPlot to start with the pre-computed values of DensityPlot[f] and DensityPlot[g] when asking for DensityPlot[f-g]. Any suggestions ?

• ListDensityPlot can show values calculated on an explicit grid. – mikado Jul 4 '16 at 22:44
• I would rather avoid setting an explicit grid, or at least use the one that DensityPlot did propose – Pierre Jul 4 '16 at 22:49
• FunctionInterpolation might give a more efficiently computed approximation to each function. – mikado Jul 4 '16 at 22:52
• Could you be more explicit ? – Pierre Jul 4 '16 at 23:32