Plot Streamlines in MATLAB for t=[1,5,10]s at (x0,y0)=(0,0)

  • MATLAB
  • Thread starter Az83
  • Start date
  • Tags
    Matlab
In summary, plotting streamlines in MATLAB allows for the visualization of vector field flow over a specific time interval at a given starting point. To specify the time interval, the "t=[1,5,10]s" syntax can be used. The starting point can be chosen by specifying coordinates in the format of "(x0,y0)=(0,0)". Multiple streamlines can be plotted in one plot by using the "hold on" command, and the appearance of the streamlines can be customized using functions such as "quiver" and "streamline".
  • #1
Az83
7
0
I'm not sure how to do this... I have the following velocity field:

t = [1,5,10] % in seconds
u=5*t*y
v=2*t^2*x^2

How do I plot in MATLAB the streamlines going through (x0,y0) = (0,0) at t = 1,5, and 10 s?
 
Physics news on Phys.org
  • #2
sorry, I can't understand your question...
 
  • #3
to start, create range vectors for x y and t, and evaluate your u and v into two more vectors

look into the quiver command in help as well
 

1. What is the purpose of plotting streamlines in MATLAB?

The purpose of plotting streamlines in MATLAB is to visualize the flow of a vector field over a specific time interval at a given starting point. This can help in understanding the behavior and patterns of the vector field.

2. How do I specify the time interval for plotting streamlines in MATLAB?

To specify the time interval, you can use the "t=[1,5,10]s" syntax, where the numbers represent the specific time values at which you want to plot the streamlines.

3. How do I choose the starting point for plotting streamlines in MATLAB?

The starting point for plotting streamlines can be chosen by specifying the coordinates in the format of "(x0,y0)=(0,0)". This will plot the streamlines starting from the point (0,0) on the x-y plane.

4. Can I plot multiple streamlines in one plot using MATLAB?

Yes, you can plot multiple streamlines in one plot by using the "hold on" command after plotting the first streamline. This will allow you to add more streamlines to the same plot.

5. How can I customize the appearance of the plotted streamlines in MATLAB?

You can customize the appearance of the plotted streamlines by using various functions in MATLAB, such as "quiver" and "streamline". These functions allow you to change the color, line style, and arrow size of the streamlines to make them more visually appealing.

Similar threads

  • MATLAB, Maple, Mathematica, LaTeX
Replies
5
Views
999
  • MATLAB, Maple, Mathematica, LaTeX
Replies
18
Views
3K
  • MATLAB, Maple, Mathematica, LaTeX
Replies
5
Views
2K
  • MATLAB, Maple, Mathematica, LaTeX
Replies
1
Views
1K
  • MATLAB, Maple, Mathematica, LaTeX
Replies
1
Views
1K
  • MATLAB, Maple, Mathematica, LaTeX
Replies
2
Views
2K
  • MATLAB, Maple, Mathematica, LaTeX
Replies
2
Views
829
  • Introductory Physics Homework Help
Replies
12
Views
82
  • MATLAB, Maple, Mathematica, LaTeX
Replies
4
Views
572
  • MATLAB, Maple, Mathematica, LaTeX
Replies
6
Views
2K
Back
Top