I am plotting slices of a block with dimensions x,y,z and using a colour map to represent the temperature of the block, which is described by the 3D-matrix, V, which is the temperature at each data point. The temperature changes over time so I am trying to create an animation using a for loop over time and drawnow.
The problem I have is that I cannot seem to access and change V. I need to implement something to effect of:
[X, Y, Z] = meshgrid([0 x], [0 y], [0 z])
h = slice(X,Y,Z,V,xslice,yslice,zslice)
for n = 1:tmax
Vnew = (function that determines the temperature at the next time step)
set(h, V, Vnew)
I then get an error that says "There is no V property on the Surface class."
A workaround I have is to re-plot the whole graph at each step but this is quite slow - any help would be hugely appreciated!