# EvenlySpacedStreamlines2D not working properly

**URL:** https://discourse.paraview.org/t/evenlyspacedstreamlines2d-not-working-properly/9776
**Category:** ParaView Support
**Created:** [June 9, 2022, 4:43pm UTC](https://discourse.paraview.org/t/evenlyspacedstreamlines2d-not-working-properly/9776 "2022-06-09T16:43:30Z")
**Posts on this page:** 17
**Page:** 1

<div class="post-metadata">

### Author: ![Trinxo123](https://discourse.paraview.org/letter_avatar_proxy/v4/letter/t/eb8c5e/32.png) [@Trinxo123](https://discourse.paraview.org/u/Trinxo123)
#### Post date: [June 9, 2022, 4:43pm UTC](https://discourse.paraview.org/t/evenlyspacedstreamlines2d-not-working-properly/9776/1 "2022-06-09T16:43:30Z")

</div>

Hi,

I’m completely new in Paraview so let me first apologize if the problem I’m presenting is trivial.  
I would like to represent a velocity field with streamlines in a plane, just as this picture I found in a similar work than mine: (My results come from Simscale)

 ![image](https://discourse.paraview.org/uploads/default/original/2X/2/2b1867b25eb26590b4d4c5e2ea6d4476335f7a06.jpeg)

After a bit of investigation I found that I had to use the filter EvenlySpacedStreamlines2D, first I placed a plane perpendicular with Z-axis with the tool Slice and then I used the filter Evenly… to recreate the top picture. No matter what option I change in the filter settings, the lines are poor and start/end not properly.

 ![image](https://discourse.paraview.org/uploads/default/original/2X/5/5a4d17f03280004e2a6177628f0b2190f065c3aa.png)

In a similar post ([Evenly Spaced Streamlines 2D filter - streamlines ending too soon](https://discourse.paraview.org/t/evenly-spaced-streamlines-2d-filter-streamlines-ending-too-soon/8687)) I saw that this could be due to the plane not being perfectly perpendicular with the Z-axis, however, in my case I’m not rotating a non XY plane, I’m directly creating a XY plane. I still tryed to ensure the XY plane with the calculator, but I don’t know how to do it.

Any help is appreciated.

Thanks,

Marc

---

<div class="post-metadata">

### Author: ![Christos\_Tsolakis](https://discourse.paraview.org/user_avatar/discourse.paraview.org/christos_tsolakis/32/4450_2.png) [@Christos\_Tsolakis](https://discourse.paraview.org/u/Christos_Tsolakis)
#### Post date: [June 9, 2022, 5:20pm UTC](https://discourse.paraview.org/t/evenlyspacedstreamlines2d-not-working-properly/9776/2 "2022-06-09T17:20:26Z")

</div>

try to transform first your 3D velocity field to a 2D using the calculator filter and an expressions like this:  
`v_X*iHat + v_Y*jHat + 0 *kHat`

where `v` is the 3D velocity field. Use then this new field as input to `EvenlySpacedStreamlines2D`

 ![Screenshot from 2022-06-09 13-18-02](https://discourse.paraview.org/uploads/default/original/2X/7/7bb5328e758228ca9730428a2212daa6add90ecc.png)

---

<div class="post-metadata">

### Author: ![Trinxo123](https://discourse.paraview.org/letter_avatar_proxy/v4/letter/t/eb8c5e/32.png) [@Trinxo123](https://discourse.paraview.org/u/Trinxo123)
#### Post date: [June 9, 2022, 6:08pm UTC](https://discourse.paraview.org/t/evenlyspacedstreamlines2d-not-working-properly/9776/3 "2022-06-09T18:08:53Z")

</div>

Thanks for your message.

I tried and no matter what setting I put (line distance …), the program crash after clying apply in the EvenlySpaced… filter.  
I am using it in Windows with a good PC.

Marc

---

<div class="post-metadata">

### Author: ![Christos\_Tsolakis](https://discourse.paraview.org/user_avatar/discourse.paraview.org/christos_tsolakis/32/4450_2.png) [@Christos\_Tsolakis](https://discourse.paraview.org/u/Christos_Tsolakis)
#### Post date: [June 9, 2022, 6:14pm UTC](https://discourse.paraview.org/t/evenlyspacedstreamlines2d-not-working-properly/9776/4 "2022-06-09T18:14:44Z")

</div>

it is possible to share your data ?

---

<div class="post-metadata">

### Author: ![Trinxo123](https://discourse.paraview.org/letter_avatar_proxy/v4/letter/t/eb8c5e/32.png) [@Trinxo123](https://discourse.paraview.org/u/Trinxo123)
#### Post date: [June 9, 2022, 6:53pm UTC](https://discourse.paraview.org/t/evenlyspacedstreamlines2d-not-working-properly/9776/5 "2022-06-09T18:53:52Z")

</div>

Yes, but it’s very heavy. I am trying to put the XY plane at Z=0.01.  
It is impossible to share it here as it shows an error message.  
[https://drive.google.com/drive/folders/1lj8cDjMoc\_OmdCS2Ghcm6V3jRQIcdl51?usp=sharing](https://drive.google.com/drive/folders/1lj8cDjMoc_OmdCS2Ghcm6V3jRQIcdl51?usp=sharing)  
I think you will have to ask permission, if this method is not suitable for you, just suggest one.

Thanks,

Marc

---

<div class="post-metadata">

### Author: ![Christos\_Tsolakis](https://discourse.paraview.org/user_avatar/discourse.paraview.org/christos_tsolakis/32/4450_2.png) [@Christos\_Tsolakis](https://discourse.paraview.org/u/Christos_Tsolakis)
#### Post date: [June 9, 2022, 7:29pm UTC](https://discourse.paraview.org/t/evenlyspacedstreamlines2d-not-working-properly/9776/6 "2022-06-09T19:29:00Z")

</div>

I see multiple files and none of them seems familiar to me. How should Ioad the data ?

---

<div class="post-metadata">

### Author: ![Trinxo123](https://discourse.paraview.org/letter_avatar_proxy/v4/letter/t/eb8c5e/32.png) [@Trinxo123](https://discourse.paraview.org/u/Trinxo123)
#### Post date: [June 9, 2022, 7:33pm UTC](https://discourse.paraview.org/t/evenlyspacedstreamlines2d-not-working-properly/9776/7 "2022-06-09T19:33:34Z")

</div>

You have to load the file case.foam in Paraview.

---

<div class="post-metadata">

### Author: ![Christos\_Tsolakis](https://discourse.paraview.org/user_avatar/discourse.paraview.org/christos_tsolakis/32/4450_2.png) [@Christos\_Tsolakis](https://discourse.paraview.org/u/Christos_Tsolakis)
#### Post date: [June 9, 2022, 7:38pm UTC](https://discourse.paraview.org/t/evenlyspacedstreamlines2d-not-working-properly/9776/8 "2022-06-09T19:38:30Z")

</div>

in the dataset you provided this file is empty.

---

<div class="post-metadata">

### Author: ![Trinxo123](https://discourse.paraview.org/letter_avatar_proxy/v4/letter/t/eb8c5e/32.png) [@Trinxo123](https://discourse.paraview.org/u/Trinxo123)
#### Post date: [June 9, 2022, 7:43pm UTC](https://discourse.paraview.org/t/evenlyspacedstreamlines2d-not-working-properly/9776/9 "2022-06-09T19:43:02Z")

</div>

Yes it says 0 kb but you should be able to open it, at least I can.

---

<div class="post-metadata">

### Author: ![Christos\_Tsolakis](https://discourse.paraview.org/user_avatar/discourse.paraview.org/christos_tsolakis/32/4450_2.png) [@Christos\_Tsolakis](https://discourse.paraview.org/u/Christos_Tsolakis)
#### Post date: [June 9, 2022, 7:53pm UTC](https://discourse.paraview.org/t/evenlyspacedstreamlines2d-not-working-properly/9776/10 "2022-06-09T19:53:13Z")

</div>

I just get an error trying to do so. Could you save the slice you create as a vtk file , so we can start from the same reference point.

---

<div class="post-metadata">

### Author: ![Trinxo123](https://discourse.paraview.org/letter_avatar_proxy/v4/letter/t/eb8c5e/32.png) [@Trinxo123](https://discourse.paraview.org/u/Trinxo123)
#### Post date: [June 9, 2022, 8:07pm UTC](https://discourse.paraview.org/t/evenlyspacedstreamlines2d-not-working-properly/9776/11 "2022-06-09T20:07:25Z")

</div>

Hope it’s fine this time.  
[slice.vtm](https://discourse.paraview.org/uploads/short-url/dlV2INAZEb6nbhnhRJqXtyHlWgr.vtm) (603 Bytes)

---

<div class="post-metadata">

### Author: ![Trinxo123](https://discourse.paraview.org/letter_avatar_proxy/v4/letter/t/eb8c5e/32.png) [@Trinxo123](https://discourse.paraview.org/u/Trinxo123)
#### Post date: [June 9, 2022, 8:13pm UTC](https://discourse.paraview.org/t/evenlyspacedstreamlines2d-not-working-properly/9776/12 "2022-06-09T20:13:26Z")

</div>

Sorry, I think is not working , check the drive for the correct one.

---

<div class="post-metadata">

### Author: ![Christos\_Tsolakis](https://discourse.paraview.org/user_avatar/discourse.paraview.org/christos_tsolakis/32/4450_2.png) [@Christos\_Tsolakis](https://discourse.paraview.org/u/Christos_Tsolakis)
#### Post date: [June 10, 2022, 11:50pm UTC](https://discourse.paraview.org/t/evenlyspacedstreamlines2d-not-working-properly/9776/13 "2022-06-10T23:50:24Z")

</div>

Thank you for sharing the data. Indeed it seams to be some issue with the filter. This is the best I could get

 ![Screenshot from 2022-06-10 19-45-22](https://discourse.paraview.org/uploads/default/original/2X/5/511c3cb345088a9acc5e91ccdd16c36a38883ab0.png)

`U_XY = U_X*iHat + U_Y*jHat`

How about using the standard streamtracer filter with `U_XY` ?

---

<div class="post-metadata">

### Author: ![Gabriel\_Axtmann](https://discourse.paraview.org/user_avatar/discourse.paraview.org/gabriel_axtmann/32/1428_2.png) [@Gabriel\_Axtmann](https://discourse.paraview.org/u/Gabriel_Axtmann)
#### Post date: [June 13, 2022, 12:40pm UTC](https://discourse.paraview.org/t/evenlyspacedstreamlines2d-not-working-properly/9776/14 "2022-06-13T12:40:27Z")

</div>

Marc, this is the surface LIC filter…not streamlines.

Activate under Tools Manage Plugin…Surface LIC.

Restart paraview

Load your data and switch to surface lic representation

Make sure your velocity field is set as onout source.

---

<div class="post-metadata">

### Author: ![Christos\_Tsolakis](https://discourse.paraview.org/user_avatar/discourse.paraview.org/christos_tsolakis/32/4450_2.png) [@Christos\_Tsolakis](https://discourse.paraview.org/u/Christos_Tsolakis)
#### Post date: [June 13, 2022, 2:17pm UTC](https://discourse.paraview.org/t/evenlyspacedstreamlines2d-not-working-properly/9776/15 "2022-06-13T14:17:38Z")

</div>

> Marc, this is the surface LIC filter…not streamlines.

Totally forgot about SurfaceLIC ! Thank you @Gabriel_Axtmann ! Using this option generates results very close to you reference pictures:

 ![Screenshot from 2022-06-13 10-15-35](https://discourse.paraview.org/uploads/default/original/2X/4/4d19b0322626125f2b510d57c51ad7cda378dc8d.jpeg)

---

<div class="post-metadata">

### Author: ![Gabriel\_Axtmann](https://discourse.paraview.org/user_avatar/discourse.paraview.org/gabriel_axtmann/32/1428_2.png) [@Gabriel\_Axtmann](https://discourse.paraview.org/u/Gabriel_Axtmann)
#### Post date: [June 13, 2022, 2:30pm UTC](https://discourse.paraview.org/t/evenlyspacedstreamlines2d-not-working-properly/9776/16 "2022-06-13T14:30:14Z")

</div>

Now set color mode to multiply and set enhance contrast to both

---

<div class="post-metadata">

### Author: ![Trinxo123](https://discourse.paraview.org/letter_avatar_proxy/v4/letter/t/eb8c5e/32.png) [@Trinxo123](https://discourse.paraview.org/u/Trinxo123)
#### Post date: [June 18, 2022, 8:06am UTC](https://discourse.paraview.org/t/evenlyspacedstreamlines2d-not-working-properly/9776/17 "2022-06-18T08:06:52Z")

</div>

That worked! Thank you.
