Hello everyone,
for a project I need to interpolate different surfaces from CFD data. The surfaces are assumed to be rectangular and free to be placed. Since the CFD data comes as scattered data points I need to interpolate the data from the 3d CFD information to get the best precision.
My problem now is that I need to somehow reduce the distance of data points to be used for interpolation.
The reason therefore is that I want interpolated points surrounded by nan- data points to be nan even though there might be other points in further distance that allow to interpolate at this point.
As example I want to show you one case which should give you somewhat of a clue I am talking about.
In the first and second plot you can see a hopper connected to two tanks and the outlet.
I want to get the boundary conditions of the 6 red surfaces. That means that for example the XY plan at the outlet should have a lot of NaN data points with just some data points interpolated within the circle defined by the outlet diameter.
But for now with
surfaces{i}(j+3,:) = griddata(data{1}, data{2}, data{3}, data{handles.indexSelected(j)} ,surfaces{i}(1,:),surfaces{i}(2,:),surfaces{i}(3,:),'linear');
I get the inner part of the outlet (red circle) plus the interpolated points resulting from the diagonal between outlet tube and the tanks:
Is there a possibility to adapt the griddata function to suite my needs?
I appreciate your help!
Best Regards, Stephan Heidrich