您的位置首页百科快答

请教Matlab的griddata的用法?

请教Matlab的griddata的用法?

的有关信息介绍如下:

请教Matlab的griddata的用法?

知道一系列点的坐标如下(1.486,3.059,0.1);(2.121,4.041,0.1);(2.570,3.959,0.1);(3.439,4.396,0.1);(4.505,3.012,0.1);(3.402,1.604,0.1);(2.570,2.065,0.1);(2.150,1.970,0.1);(1.794,3.059,0.2);(2.121,3.615,0.2);(2.570,3.473,0.2);(3.421,4.160,0.2);(4.271,3.036,0.2);(3.411,1.876,0.2);(2.561,2.562,0.2);(2.179,2.420,0.2);(

x = rand(1,12); y = rand(1,12); z = rand(1,12); % now use some random z axis data xi = linspace(min(x),max(x),30); % x interpolation points yi = linspace(min(y),max(y),30); % x interpolation points [Xi,Yi] = meshgrid(xi,yi); % create grid of x and y Zi = griddata(x,y,z,Xi,Yi); % grid the data at Xi,