0
$\begingroup$

I managed to solved a lid-driven cavity flow using LB code. It gave me the velocity field data points.

Now I have to obtain streamlines too, of course from the obtained velocity field.

Besides, I know the theory of Potential Flow as well as all of the associated relations.

How can I directly draw the streamlines of this flow without solving a Poisson equation. If numerical integration must to be used (as I guess), How should I do handle with partial derivatives?

$\endgroup$
  • $\begingroup$ There are algorithms that already compute the streamlines for you. Can't you use one of those? $\endgroup$ – nicoguaro Apr 9 '15 at 19:13
1
$\begingroup$

Probably the easiest thing to do is to use a visualization package or something with built-in vis capabilities. MATLAB, ParaView, and VisIt all support plotting streamlines natively, and the latter two are freely available.

If you want to plot them yourself, they are usually integrated using a psuedo-time integration method from seed points such that

$$ \frac{dx(s)}{ds} = u(x(s),t) $$

for $t$ fixed and some initial point $x(0)=x_0$. If the flow is steady, then you can drop the $t$.

| cite | improve this answer | |
$\endgroup$
  • $\begingroup$ Thanks. I am willing to do it on my own (coding). Can you give me at least some sources? $\endgroup$ – Shaqpad Apr 8 '15 at 16:57
  • $\begingroup$ I recommend that you don't unless you are working towards becoming an expert in scientific visualization. Integrating streamlines by hand is actually non-trivial, since your sample points will be between grid points and will also require some sort of interpolation to find the right velocities for each step. Experts at this have put in all the work for you already. $\endgroup$ – Bill Barth Apr 8 '15 at 17:00
  • $\begingroup$ Yes. Actually I read A. A. Mohamad's book on Lattice Boltzmann Method. There he do this with a few lines of code. One thing more, What about Tecplot? Does it have this feature? $\endgroup$ – Shaqpad Apr 8 '15 at 17:08
  • $\begingroup$ Yes, and every other visualization program that takes vector data. $\endgroup$ – Bill Barth Apr 8 '15 at 19:49
0
$\begingroup$

The CGAL library has a package for this purpose. See their documentation for details and references.

| cite | improve this answer | |
$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.