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

Two ODE objects simultaneously

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   November 28, 2012, 22:46
Default Two ODE objects simultaneously
  #1
New Member
 
James Behzadi
Join Date: Oct 2011
Location: Sydney, Australia
Posts: 27
Rep Power: 15
JBUNSW is on a distinguished road
Dear all,

I have a rather non-conventional problem to solve. It is a PDE which people split it into stiff and nonstiff ODE's. The result of this "operator splitting" is two different sets of ODE's which can be solved separately.

The problem is that the number of equations are not the same. Let's say I have n1_ nonstiff ODE's and n2_ stiff ODE's.

My understanding of existing architecture of OpenFOAM 2.0.x is that, it allows the use of only one ODE solver at a time. The ODE object is constructed at runtime, and all the variables used in the integration are initialised at the constructor of the ODESolver class, viz.
Code:
Foam::ODESolver::ODESolver(const ODE& ode)
 :
     n_(ode.nEqns()),
     yScale_(n_),
     dydx_(n_)
 {}
My understanding is that constructor can initialise the ODE object for either n1_ or n2_ not both. Currently I am solving the stiff part with SIBS and for the nonstiff part, I am using the LU solver that comes with OpenFOAM. I would like to solve my nonstiff ODE's with some jacobian-free ODE solver like RK.

I searched the forum in hope of finding something relevant. I cam up with the following threads, but apparently none of them address my problem.

A trial of implementing of CVODE as ODESolver
Problem implementing CVODE ODE solver (see post #15)
OpenFOAM 1.7 and CVODE

My questions:
1) Is there any way to create two ode objects that one of them uses one ODEsolver (SIBS per say) and the other one uses another (RK for example)?!
2) Or rephrasing my first question, is there any way to use the same ODE solver (SIBS for example) to solve two different sets of ODE's with n1_ and n2_ equations?!

Jalal
JBUNSW is offline   Reply With Quote

Reply

Tags
cvode, operator splitting, rk ode solver, sibs ode solver, stiff non-stiff ode


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
Using ODE in OpenFoam skabilan OpenFOAM Programming & Development 22 April 6, 2022 07:05
Is it possible to accelerate the ode solver of reactingFoam? pajofego OpenFOAM Running, Solving & CFD 2 August 10, 2014 06:38
IcePak network objects in parallel solver Alexey FLUENT 1 December 25, 2013 09:32
reactingFoam: ODE Solver KRR4 "Too many integration steps" pajofego OpenFOAM 3 May 18, 2013 16:15
Warning when I add my objects Xu Phoenics 0 November 21, 2008 13:30


All times are GMT -4. The time now is 03:50.