Evaluating Data at Arbitrary Points
If you want to get data at a specific location not necessarily defined by node points, use the command mphinterp to interpolate the results. The interpolation method uses the shape function of the elements.
1
To extract the total heat source at [5e-2;-2e-2;1e-3] enter:
Qtot = mphinterp(model,'ht.Qtot','coord',[5e-2;-2e-2;1e-3])
This returns:
Qtot =
  6.9417e+003
2
[Temp, unit]= mphinterp(model,'T','coord',[5e-2;-2e-2;1e-3],'unit','degF')
This returns:
Temp =
  120.6804
 
unit =
  'degF'
3
x0=0:5e-2/4:5e-2;
y0=0:-2.5e-2/4:-2.5e-2;
z0=[0 5e-3];
[x,y,z]=meshgrid(x0,y0,z0);
xx=[x(:),y(:),z(:)]';
Qtot = mphinterp(model,'ht.Qtot','coord',xx);
4
Reshape the variable Qtot for a better visualization:
Qtot = reshape(Qtot,length(x0),length(y0),length(z0))
This results in:
Qtot(:,:,1) =
1.0e+05 *
    0.0000    0.0278    0.0739    0.0697    0.0694
    0.0007    0.3955    0.0736    0.0694    0.0694
    0.0000    3.1413    0.0672    0.0692    0.0694
    0.0007    0.2908    0.0736    0.0694    0.0694
    0.0000    0.0278    0.0738    0.0697    0.0694
 
Qtot(:,:,2) =
1.0e+03 *
    0.0000    2.8296    7.3588    6.9707    6.9434
    0.0678    5.2452    7.0008    6.9426    6.9422
    0.0000    8.7617    5.5528    6.9160    6.9407
    0.0639    5.2439    7.0061    6.9413    6.9414
    0.0000    2.8245    7.3524    6.9672    6.9421