CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM

Projecting Points onto .stl Defined Surface

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   August 17, 2012, 17:50
Default Projecting Points onto .stl Defined Surface
  #1
Member
 
Matthew J. Churchfield
Join Date: Nov 2009
Location: Boulder, Colorado, USA
Posts: 49
Rep Power: 19
mchurchf is on a distinguished road
I want to read in a .stl file and use it to define a surface. Then given an x,y location, I'd like to project onto the surface to find the z height. Can anyone help with how to do that. The surfaceDisplacement boundary condition that can be used for the "pointMotion" field with the moveDynamicMesh solver seems to be able to do this, but I can't figure out how to do that. I've taken the "transformPoints" utility and modified it to take a block mesh made with "blockMesh" and translate points vertically to conform to an analytical surface definition at the bottom, but now I want to have the ability to conform to a general surface definition that comes in the form of an .stl file.

Thank you,

Matt
mchurchf is offline   Reply With Quote

Old   August 17, 2012, 18:04
Default
  #2
Senior Member
 
Laurence R. McGlashan
Join Date: Mar 2009
Posts: 370
Rep Power: 23
l_r_mcglashan will become famous soon enough
Would functions such as findLine in triSurfaceMesh be what you're looking after?
__________________
Laurence R. McGlashan :: Website
l_r_mcglashan is offline   Reply With Quote

Old   August 17, 2012, 18:13
Default
  #3
Member
 
Matthew J. Churchfield
Join Date: Nov 2009
Location: Boulder, Colorado, USA
Posts: 49
Rep Power: 19
mchurchf is on a distinguished road
Laurence,

If I'm reading the code correctly, one would give start and end point fields of a segments, and findLine will return the intersections? If so, that's pretty neat.

Matt
mchurchf is offline   Reply With Quote

Old   August 17, 2012, 18:19
Default
  #4
Senior Member
 
Laurence R. McGlashan
Join Date: Mar 2009
Posts: 370
Rep Power: 23
l_r_mcglashan will become famous soon enough
Yes and an octree is used for the search, useful if you have a large surface. Hope that helps!
__________________
Laurence R. McGlashan :: Website
l_r_mcglashan 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
OpenFOAM static build on Cray XT5 asaijo OpenFOAM Installation 9 April 6, 2011 13:21
Calculating forces on a non-closed surface ScottN FLUENT 0 March 1, 2011 18:18
solid edge problem....can you help? cindy Main CFD Forum 3 April 5, 2004 14:43
CFX 5.5 Roued CFX 1 October 2, 2001 17:49
CFX4.3 -build analysis form Chie Min CFX 5 July 13, 2001 00:19


All times are GMT -4. The time now is 14:05.