My matrix
A=[12 3 65,2 3 6,68 15 40,66 98 12]
A is 3*4
x=[19 20 21]
x is 1*3
y=[118 119 120 121]
y is 1*4
zz=interp2(x,y,A,xlat,xlon,'cubic'); xlat=12*21 ,xlon=12*21
but it shows error
Error using griddedInterpolantThe grid vectors do not define a grid of points that match the given values.Error in interp2>makegriddedinterp (line 228) F = griddedInterpolant(varargin{:});Error in interp2 (line 128) F = makegriddedinterp({X, Y}, V, method,extrap);
How can fix it?
thanks
Best Answer