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

Projecting Points onto .stl Defined Surface

Register Blogs Members List Search Today's Posts Mark Forums Read

Reply
 
LinkBack Thread Tools Display Modes
Old   August 17, 2012, 16:50
Default Projecting Points onto .stl Defined Surface
  #1
Member
 
Matthew J. Churchfield
Join Date: Nov 2009
Location: Boulder, Colorado, USA
Posts: 48
Rep Power: 7
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, 17:04
Default
  #2
Senior Member
 
Laurence R. McGlashan
Join Date: Mar 2009
Posts: 367
Rep Power: 13
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, 17:13
Default
  #3
Member
 
Matthew J. Churchfield
Join Date: Nov 2009
Location: Boulder, Colorado, USA
Posts: 48
Rep Power: 7
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, 17:19
Default
  #4
Senior Member
 
Laurence R. McGlashan
Join Date: Mar 2009
Posts: 367
Rep Power: 13
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

Thread Tools
Display Modes

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 On
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 12:21
Calculating forces on a non-closed surface ScottN FLUENT 0 March 1, 2011 17:18
solid edge problem....can you help? cindy Main CFD Forum 3 April 5, 2004 13:43
CFX 5.5 Roued CFX 1 October 2, 2001 16:49
CFX4.3 -build analysis form Chie Min CFX 5 July 12, 2001 23:19


All times are GMT -4. The time now is 15:37.