CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Visualization & Post-Processing Software > ParaView

[OpenFOAM] Plot over curved lines

Register Blogs Community New Posts Updated Threads Search

Like Tree12Likes
  • 7 Post By WaterHammer1985
  • 2 Post By TommyM
  • 1 Post By gigili206
  • 2 Post By Mihir

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   January 29, 2020, 05:22
Post Plot over curved lines
  #1
Member
 
Tommaso M.
Join Date: Sep 2018
Location: Milan, Italy
Posts: 67
Rep Power: 7
TommyM is on a distinguished road
Hi All,
I need to extract the temperature profile along nozzle walls (attached image).
There is the filter "plot over a line" to my knowledge but it plots only over a straight line, while I need to plot over a curved line.
Any suggestions?
Thanks in advance.


Tommy
Attached Images
File Type: png nozzle.png (17.8 KB, 88 views)
TommyM is offline   Reply With Quote

Old   February 3, 2020, 14:25
Default
  #2
Member
 
Join Date: Nov 2015
Posts: 38
Rep Power: 10
WaterHammer1985 is on a distinguished road
1. Create a .csv file of the XYZ points that defines the curve

2. Import .csv file into Paraview

3. Apply Filter "Table to Points" to the .csv file

4. Create a polyline of the points (got this from another post awhile back but I don't have link to it): Apply Filter "Programmable Filter".
Code:
output.Points = inputs[0].Points
numPoints = len(output.Points)

pointIds = vtk.vtkIdList()
pointIds.SetNumberOfIds(numPoints)
for i in range(numPoints):
    pointIds.SetId(i, i)

output.Allocate(1, 1)
output.InsertNextCell(vtk.VTK_POLY_LINE, pointIds)
5. Then use Filter "Slice Along Polyline" using the newly created polyline from step 4.

There may be a more streamlined approach to this workflow but this has worked for me.
WaterHammer1985 is offline   Reply With Quote

Old   February 4, 2020, 13:30
Default
  #3
Member
 
Tommaso M.
Join Date: Sep 2018
Location: Milan, Italy
Posts: 67
Rep Power: 7
TommyM is on a distinguished road
Hi,
Thanks for your help. It works!
I have just founded another way that seems to be more simple. I import in Paraview only the "wall" patch and then I use the filter "Plot over intersections" putting the plane to intersect the patch.
Anyway your method can be applied to a generic polyline and it can be used for example to extract the velocity profile around a turbomachine.
Thanks again,


Tommy
TommyM is offline   Reply With Quote

Old   December 23, 2020, 14:45
Default
  #4
Lil
New Member
 
Lila
Join Date: Nov 2019
Posts: 7
Rep Power: 6
Lil is on a distinguished road
Hello,

I tried this method but I don't know how to get data over the spline created. Any help please?

Thanks
Lili
Lil is offline   Reply With Quote

Old   September 16, 2021, 15:46
Default
  #5
New Member
 
M.H
Join Date: Dec 2013
Posts: 11
Rep Power: 12
gigili206 is on a distinguished road
Quote:
Originally Posted by Lil View Post
Hello,

I tried this method but I don't know how to get data over the spline created. Any help please?

Thanks
Lili
I am writing this for anyone who might see this later.

Once you created your slice over poly line, just use the filter "plot on intersection curves" to plot the data. You can export the data using file>save data.
WaterHammer1985 likes this.
gigili206 is offline   Reply With Quote

Old   September 25, 2021, 16:52
Default
  #6
Senior Member
 
Arijit Saha
Join Date: Feb 2019
Location: Singapore
Posts: 132
Rep Power: 7
ari003 is on a distinguished road
Quote:
Originally Posted by gigili206 View Post
I am writing this for anyone who might see this later.

Once you created your slice over poly line, just use the filter "plot on intersection curves" to plot the data. You can export the data using file>save data.
While using programmable Filter I'm experiencing this error
Quote:
ERROR: In /home/ubuntu/OpenFOAM/ThirdParty-dev/ParaView-5.6.0/VTK/Common/ExecutionModel/vtkDemandDrivenPipeline.cxx, line 709
vtkPVCompositeDataPipeline (0x55ee6fdd2a80): Input port 1 of algorithm vtkSliceAlongPolyPlane(0x55ee729fbb90) has 0 connections but is not optional.

ERROR: In /home/ubuntu/OpenFOAM/ThirdParty-dev/ParaView-5.6.0/VTK/Common/ExecutionModel/vtkDemandDrivenPipeline.cxx, line 709
vtkPVCompositeDataPipeline (0x55ee6fdd2a80): Input port 1 of algorithm vtkSliceAlongPolyPlane(0x55ee729fbb90) has 0 connections but is not optional.

ERROR: In /home/ubuntu/OpenFOAM/ThirdParty-dev/ParaView-5.6.0/VTK/Common/ExecutionModel/vtkDemandDrivenPipeline.cxx, line 709
vtkPVCompositeDataPipeline (0x55ee6fdd2a80): Input port 1 of algorithm vtkSliceAlongPolyPlane(0x55ee729fbb90) has 0 connections but is not optional.

ERROR: In /home/ubuntu/OpenFOAM/ThirdParty-dev/ParaView-5.6.0/VTK/Common/ExecutionModel/vtkDemandDrivenPipeline.cxx, line 709
vtkPVCompositeDataPipeline (0x55ee6fdd2a80): Input port 1 of algorithm vtkSliceAlongPolyPlane(0x55ee729fbb90) has 0 connections but is not optional.

ERROR: In /home/ubuntu/OpenFOAM/ThirdParty-dev/ParaView-5.6.0/VTK/Common/ExecutionModel/vtkDemandDrivenPipeline.cxx, line 709
vtkPVCompositeDataPipeline (0x55ee6fdd2a80): Input port 1 of algorithm vtkSliceAlongPolyPlane(0x55ee729fbb90) has 0 connections but is not optional.

ERROR: In /home/ubuntu/OpenFOAM/ThirdParty-dev/ParaView-5.6.0/VTK/Common/ExecutionModel/vtkDemandDrivenPipeline.cxx, line 709
vtkPVCompositeDataPipeline (0x55ee6fdd2a80): Input port 1 of algorithm vtkSliceAlongPolyPlane(0x55ee729fbb90) has 0 connections but is not optional.

ERROR: In /home/ubuntu/OpenFOAM/ThirdParty-dev/ParaView-5.6.0/VTK/Common/ExecutionModel/vtkDemandDrivenPipeline.cxx, line 709
vtkPVCompositeDataPipeline (0x55ee6fdd2a80): Input port 1 of algorithm vtkSliceAlongPolyPlane(0x55ee729fbb90) has 0 connections but is not optional.

ERROR: In /home/ubuntu/OpenFOAM/ThirdParty-dev/ParaView-5.6.0/VTK/Common/ExecutionModel/vtkDemandDrivenPipeline.cxx, line 709
vtkPVCompositeDataPipeline (0x55ee6fdd2a80): Input port 1 of algorithm vtkSliceAlongPolyPlane(0x55ee729fbb90) has 0 connections but is not optional.

ERROR: In /home/ubuntu/OpenFOAM/ThirdParty-dev/ParaView-5.6.0/VTK/Common/ExecutionModel/vtkDemandDrivenPipeline.cxx, line 709
vtkPVCompositeDataPipeline (0x55ee6fdd2a80): Input port 1 of algorithm vtkSliceAlongPolyPlane(0x55ee729fbb90) has 0 connections but is not optional.

Warning: In /home/ubuntu/OpenFOAM/ThirdParty-dev/ParaView-5.6.0/VTK/Common/DataModel/vtkDataObject.cxx, line 521
vtkTable (0x55ee7566e340): Attempted to ShallowCopy from null.

ERROR: In /home/ubuntu/OpenFOAM/ThirdParty-dev/ParaView-5.6.0/VTK/Common/ExecutionModel/vtkDemandDrivenPipeline.cxx, line 709
vtkPVCompositeDataPipeline (0x55ee6fdd2a80): Input port 1 of algorithm vtkSliceAlongPolyPlane(0x55ee729fbb90) has 0 connections but is not optional.

Traceback (most recent call last):
File "<string>", line 22, in <module>
File "<string>", line 2, in RequestData
TypeError: 'NoneType' object has no attribute '__getitem__'
Can you tell me how you did this succesfully? Thanks in advance
ari003 is offline   Reply With Quote

Old   March 12, 2022, 17:30
Default Help !
  #7
Senior Member
 
qutadah
Join Date: Jun 2021
Location: USA
Posts: 101
Rep Power: 4
qutadah.r is on a distinguished road
Hey,



I am also trying to plot on curved blades, the problem is there are 6 blades in an impeller and I dont know how to get plots for each of the blades and also to be able to differentiate between the left intersection and right intersection sides of the plane with the wall.


I imported the blades VTK and used plot on intersection. However all I get is only one plot and not sure how to make different plots for each blade and each side of the 3D blade respectively.


Here is a photo of what I was able to do till now.

Thanks!
Attached Images
File Type: png Unbenannt.PNG (87.8 KB, 55 views)
qutadah.r is offline   Reply With Quote

Old   March 13, 2022, 16:55
Default
  #8
Member
 
Join Date: Nov 2015
Posts: 38
Rep Power: 10
WaterHammer1985 is on a distinguished road
I'd suggest using what you have and then applying Clip filters (probably will take multiple) to isolate the area of interest.
WaterHammer1985 is offline   Reply With Quote

Old   March 17, 2022, 20:03
Default
  #9
Senior Member
 
qutadah
Join Date: Jun 2021
Location: USA
Posts: 101
Rep Power: 4
qutadah.r is on a distinguished road
Quote:
Originally Posted by WaterHammer1985 View Post
I'd suggest using what you have and then applying Clip filters (probably will take multiple) to isolate the area of interest.

I have actually used the vtk file and used extractSurfaces, Connectivity (to closest), Slice and plot Data. It worked


Any idea how I could plot it along arc length of the blade? right now, its just pointId or index.


Thanks!
Attached Images
File Type: jpg Unbenannt.jpg (90.1 KB, 36 views)
qutadah.r is offline   Reply With Quote

Old   April 7, 2022, 13:41
Default
  #10
New Member
 
Mihir
Join Date: Dec 2021
Posts: 2
Rep Power: 0
Mihir is on a distinguished road
1. Create a list of x,y,z points of the polyline in excel sheet.
2. In paraview go to filters -->Poly Line Source
3. You will get options to add your co-ordinates, Increase the number of coordinates till you want for your polyline and then directly copy paste the coordinates, then click on apply.
4. Go to filter --> Slice along polyline, then for database select your geometry and for polyline select PolyLineSource and then apply.
5. Finally select filter --> plot on Intersection Curve, If your geometry is in x-y plane, select z normal for the new Plane and then click on Apply.
JohanDiaz and unilord like this.
Mihir is offline   Reply With Quote

Old   April 7, 2022, 16:36
Default
  #11
Senior Member
 
qutadah
Join Date: Jun 2021
Location: USA
Posts: 101
Rep Power: 4
qutadah.r is on a distinguished road
actually i just used append to arc length and it worked.
qutadah.r is offline   Reply With Quote

Old   April 6, 2023, 03:32
Default problem of slice orientation
  #12
New Member
 
Join Date: Apr 2023
Posts: 11
Rep Power: 3
little_fish is on a distinguished road
hello,



i m trying to do a slice along polyline on a heicoidale pipe, but i have a problem with the orientation of my plan (see picture).



i would like to have a plan with z normal..


is this possible with this filter ? or i have to change my method ?
Attached Images
File Type: jpg Capture d’écran du 2023-04-04 15-36-34.jpg (88.3 KB, 21 views)
little_fish is offline   Reply With Quote

Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
plot Cp over curved line in bend wall using fluent or cfd post hesham Visualization & Post-Processing 1 September 7, 2022 08:07
generating 2d-planar contour plots from a contour plot on a curved surface alinik CFX 3 May 21, 2016 06:17
plot pressure profile along curved pipe Amar Kad CFX 1 March 20, 2016 18:46
How to plot contour lines in Tecplot 360 using Excel file Iqbal Tecplot 1 May 30, 2012 19:22
plot vectors perpendicular to curved surface azmir Siemens 3 October 19, 2004 01:48


All times are GMT -4. The time now is 18:21.