Adding Equations in custom solver
Hi Foamers,
I know this is a silly question but I would like to know how to write the following equation in Openfoam custom solver. http://ars.els-cdn.com/content/image...01558-si16.gif I have wrote the following line. tmp<fvScalar> rhoCEqn ( fvm::laplacian(epsilonR, rhoC) == rhoC / (sqr(lamdaD) ; ); where, epsilonR and lamdaD are constants Regards, Rafath |
Hi,
You can do directly: solve ( fvm::laplacian(epsilonR, rhoC) - (rhoC / Foam::sqr(lamdaD)) ); and you must read your "lamdaD" value by defining it in your createFields.H file as the following: dimensionedScalar lambaD ( transportProperties.lookup("lamdaD") ); then before lunching the simulation, you must provide the value of lamdaD in the case_Folder/constant/transportProperties like : lamdaD lamdaD [ 0 ---- dimensions---- 0 ] its_value; Have Fun ! T.D. Quote:
|
thanks a lot T.D .:)
|
All times are GMT -4. The time now is 07:40. |