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

Conditional patching?

Register Blogs Community New Posts Updated Threads Search

Like Tree1Likes
  • 1 Post By hjasak

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   August 11, 2015, 11:10
Default Conditional patching?
  #1
New Member
 
Londo
Join Date: Feb 2015
Posts: 14
Rep Power: 11
Londo is on a distinguished road
How do I do conditional patching? Basically I am looking at two different scenarios:

1) Timed change. Let's say that I want to change a temperature of a certain region in the mesh at t = t0.

2) Property conditional change. Let's say that I want to open a valve when I reach a certain pressure value (let's say, max(p) = p_max)?

Can be this done without meddling with the code?
Londo is offline   Reply With Quote

Old   August 12, 2015, 00:27
Default
  #2
Senior Member
 
Hrvoje Jasak
Join Date: Mar 2009
Location: London, England
Posts: 1,905
Rep Power: 33
hjasak will become famous soon enough
Yup. Use a mixed boundary condition and switch the value fraction. That will do most things.

If you want to be really fancy, you can have a topologically changing mesh and a rematch topo modifier to move faces from one patch to another
banji likes this.
__________________
Hrvoje Jasak
Providing commercial FOAM/OpenFOAM and CFD Consulting: http://wikki.co.uk
hjasak is offline   Reply With Quote

Old   August 12, 2015, 10:26
Default
  #3
New Member
 
Londo
Join Date: Feb 2015
Posts: 14
Rep Power: 11
Londo is on a distinguished road
First of all, thank you for the reply.

Quote:
Originally Posted by hjasak View Post
Yup. Use a mixed boundary condition and switch the value fraction. That will do most things.
But this works only on the boundaries. What if I want to suddenly change something inside the computational domain? Let's say that I have an ignition source that I shut off after a certain time?

Quote:
Originally Posted by hjasak View Post
If you want to be really fancy, you can have a topologically changing mesh and a rematch topo modifier to move faces from one patch to another
That seems somewhat cumbersome. Is there a simpler way?
Londo is offline   Reply With Quote

Old   August 12, 2015, 12:06
Default
  #4
Senior Member
 
anonymous
Join Date: Aug 2014
Posts: 205
Rep Power: 12
ssss is on a distinguished road
You can use groovyBC for that task, it will let you use conditional expressions without digging with the boundary condition code
ssss 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
How to define the conditional open state for domain interface sakalido CFX 12 May 3, 2017 08:42
[OpenFOAM.org] Compile OF 2.3 on Mac OS X .... the patch gschaider OpenFOAM Installation 225 August 25, 2015 19:43
patch error OF v2.2.2 mac hewei OpenFOAM Installation 4 November 30, 2013 16:55
2.0.x on Mac OSX niklas OpenFOAM Installation 74 March 28, 2012 16:46
OpenFOAM on MinGW crosscompiler hosted on Linux allenzhao OpenFOAM Installation 127 January 30, 2009 19:08


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