# Which application should I use to solve this equation

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

 January 20, 2011, 23:58 Which application should I use to solve this equation #1 New Member   qi bin Join Date: Jan 2011 Posts: 5 Rep Power: 7 Hello Foamers, I am a beginner, which application should I use to solve these equation In region 1 ∇∙[(1-s)^1.5 ∇c]=0 ∇∙[s^3 (-4.24s+〖3s〗^2)∇s]=0 In region 2 ∇∙[(1-s)^1.5 ∇c]=1-s ∇∙[s^3 (-4.24s+〖3s〗^2)∇s]=1-s anyhelp will be thankful.

 January 21, 2011, 03:29 #2 Senior Member   Bernhard Join Date: Sep 2009 Location: Delft Posts: 790 Rep Power: 14 I suggest to write your own application, that is what you can do with OpenFOAM relatively easily. No guarantees for convergent solutions however. Especially since you equations are not very linear in s Good luck!

 January 21, 2011, 05:00 #3 New Member   qi bin Join Date: Jan 2011 Posts: 5 Rep Power: 7 Thanks. Are there similar standard applications I can modify to solve it?

 January 21, 2011, 05:22 #4 Senior Member   Bernhard Join Date: Sep 2009 Location: Delft Posts: 790 Rep Power: 14 You can have a look in the basic solvers to start with.

 January 21, 2011, 07:46 #5 Senior Member   Cyprien Join Date: Feb 2010 Location: Stanford University Posts: 246 Rep Power: 10 Hi! I think you can start from laplacianFoam and define a source term that depends on the region you consider. You can develop something like that : Code: ```volScalarField source = alpha * (1-S) + (scalar(1)-alpha); volScalarField Sc = pow((1-S),1.5); volScalarField Ss = pow(S,3)*(-4.24*S + pow(3*S,2)) solve ( fvm::laplacian(Sc,c) == source ); solve ( fvm::laplacian(Ss,S) == source );``` where alpha is a volScalarField defined by - 0 within Region 1 - 1 within Region 2 I advise you to use the setFields utility to set up alpha. Be careful to the units. Best regards, Cyp Last edited by Cyp; January 21, 2011 at 10:16.

 January 24, 2011, 02:01 #6 New Member   qi bin Join Date: Jan 2011 Posts: 5 Rep Power: 7 Thanks a lot Another question, how can I deal with the interface boundary condition between region1 and region2. Suppose c(region1)=c(region2).

 January 24, 2011, 05:06 #7 Senior Member   Cyprien Join Date: Feb 2010 Location: Stanford University Posts: 246 Rep Power: 10 I guess that if you defined your 2 regions by an indicator function such as "alpha", the continuity is automatically garanteed. Regards, Cyp

January 24, 2011, 16:52
#8
Senior Member

Ben K
Join Date: Feb 2010
Posts: 140
Rep Power: 11
Quote:
 Originally Posted by qibintj Another question, how can I deal with the interface boundary condition between region1 and region2. Suppose c(region1)=c(region2).
You can use conjugateHeatFoam (in the dev versions) or chtMultiRegionFoam for this. These solvers will ensure a continuous flux between the regions as well as c(region1)=c(region2).

 Thread Tools Display Modes Linear Mode

 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 OffTrackbacks are On Pingbacks are On Refbacks are On Forum Rules

 Similar Threads Thread Thread Starter Forum Replies Last Post dut_thinker FLOW-3D 2 September 2, 2010 22:17 Se-Hee CFX 0 December 27, 2007 02:00 Anil CFX 8 September 25, 2007 12:57 Tomik FLUENT 1 January 8, 2006 07:18 sreenivas CFX 0 May 14, 2004 09:35

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