streamline not passing through an object

Dear all,
I have a data-set including x,y,u,v columns corresponding to 6384 points in a flow field.
I would like to draw corresponding streamlines. Applying the streamline function in MATLAB, it produces streamlines which cross solid objects in the flow field.
Here is the graphical representation:
red rectangles are solid objects and streamlines should not pass through them. I know that this comes from the interpolation I need to perform in order to get a grid-base data-set (please see my code below). Do you know how can I fix this irrelevant regions?
x=data_vel(:,1); y=data_vel(:,2);
u=data_vel(:,3); v=data_vel(:,4);
d_x=linspace(2,8.5,100); d_y=linspace(0,0.7,100);
[xx,yy]=meshgrid(d_x,d_y);
F1=scatteredInterpolant(x,y,u); uu=F1(xx,yy);
F2=scatteredInterpolant(x,y,v); vv=F2(xx,yy);
figure(1) streamline(xx,yy,uu,vv,xx,yy);
Many thanks for your help in advance,
Reyhaneh

Answers (1)

In a situation such as that you are probably going to need to break your data up into chunks and streamline() each of them separately.

Categories

Find more on 2-D and 3-D Plots in Help Center and File Exchange

Products

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!