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

Search Results

Register Blogs Community New Posts Updated Threads Search

Showing results 1 to 25 of 29
Search took 0.00 seconds.
Search: Posts Made By: babakflame
Forum: OpenFOAM Programming & Development April 9, 2018, 13:19
Replies: 47
Views: 6,186
Posted By babakflame
Philip, These terms are all constant scalars...

Philip,

These terms are all constant scalars (eKbT, Dinv) or constant outward vector (currentj) with known values given in the case folder (defined this way in createFields.H file)

Regards
Forum: OpenFOAM Programming & Development April 7, 2018, 16:48
Replies: 47
Views: 6,186
Posted By babakflame
Thank you philip for the comments. I...

Thank you philip for the comments.

I understood the points you raised in the snippet. The code compiles successfully.
:)


I am running my cases in parallel. Do I need to add reduce function ...
Forum: OpenFOAM Programming & Development April 6, 2018, 15:07
Replies: 47
Views: 6,186
Posted By babakflame
Philip, thanks for your reply. I think the...

Philip,

thanks for your reply. I think the second forAll loop


forAll(patchI, faceI){
if(cMinus.boundaryField()[patchI][faceI] < 0){
gradcMinusField...
Forum: OpenFOAM Programming & Development April 6, 2018, 12:53
Replies: 47
Views: 6,186
Posted By babakflame
Many Thanks Philip I am working on your...

Many Thanks Philip

I am working on your proposed snippet and appologize for the caused confusions:o.

I had read that page, but maybe I need to re-read again:o

Regards
Forum: OpenFOAM Programming & Development April 5, 2018, 15:03
Replies: 47
Views: 6,186
Posted By babakflame
Dear Fellows I want to make a slight change...

Dear Fellows

I want to make a slight change to this boundary to not be applied when the value at the patch becomes negative (go back to zero gradient).

Before this change, the working boundary...
Forum: OpenFOAM Programming & Development April 1, 2018, 22:51
Replies: 47
Views: 6,186
Posted By babakflame
A question regarding this boundary condition

Dear Fellows

I have written the following boundary condition:

\frac{d c^+}{dy} = - j^+- c^+ \frac{d \varphi}{dy}


in OpenFOAM as:
Forum: OpenFOAM Programming & Development March 30, 2018, 21:28
Replies: 47
Views: 6,186
Posted By babakflame
Dear Fellows I have a question with regard...

Dear Fellows

I have a question with regard to this custom boundary conditions as attached, any hint is appreciated.
Forum: OpenFOAM Programming & Development June 10, 2017, 20:01
Replies: 47
Views: 6,186
Posted By babakflame
Arjun, Thanks for your reply. Here, I...

Arjun,


Thanks for your reply. Here, I am interested in tracking ions in laminar fluids. Two transport equations are solved (3 unkowns incluing anions, cations and electric potential) plus a...
Forum: OpenFOAM Programming & Development June 8, 2017, 21:42
Replies: 47
Views: 6,186
Posted By babakflame
Arjun, I realized that explicit...

Arjun,

I realized that explicit discretizing of Poisson equation in my case leads to immediate divergence.

Regards
Forum: OpenFOAM Programming & Development June 7, 2017, 10:29
Replies: 47
Views: 6,186
Posted By babakflame
Dear Arjun Thanks for your comment. So,...

Dear Arjun

Thanks for your comment. So, basically, what you recommend is:


fvScalarMatrix UeEqn
(
fvc::laplacian(eps,Ue) == -rhoE
);
...
Forum: OpenFOAM Programming & Development June 6, 2017, 23:22
Replies: 47
Views: 6,186
Posted By babakflame
Hi Arjun At first, I applied the...

Hi Arjun

At first, I applied the under-relaxation to the matrix of coefficients (under-relaxing equation) as follows:



fvScalarMatrix UeEqn
(
...
Forum: OpenFOAM Programming & Development June 6, 2017, 20:35
Replies: 47
Views: 6,186
Posted By babakflame
Unfortunately, above snippet did not help. It...

Unfortunately, above snippet did not help.
It seems that although it gaurantees that in each time step initial residual is less than a specific value, however, after couple of iterations, it...
Forum: OpenFOAM Programming & Development June 6, 2017, 18:52
Replies: 47
Views: 6,186
Posted By babakflame
Dear Philip, This is the snippet that I...

Dear Philip,

This is the snippet that I can think of:


const scalar& convergenceTolerance = 0.01;
scalar& initialResidualA = 0.0;
scalar& initialResidualB = 0.0;
scalar& initialResidual =...
Forum: OpenFOAM Programming & Development June 6, 2017, 16:43
Replies: 47
Views: 6,186
Posted By babakflame
Dear Philip Many thanks for your reply....

Dear Philip

Many thanks for your reply. The idea of looping over cPlus and cMinus equations and then get to Ue equation looks interesting. However, I have a question here:confused::confused:,...
Forum: OpenFOAM Programming & Development June 2, 2017, 21:51
Replies: 47
Views: 6,186
Posted By babakflame
Dear Philip The idea of under-relaxing...

Dear Philip
The idea of under-relaxing boundary conditions helped in the context of stabilization. Although, still the solution is unstable in the range of Ue greater than 10. But at least helped...
Forum: OpenFOAM Programming & Development May 27, 2017, 16:58
Replies: 47
Views: 6,186
Posted By babakflame
Thanks Philip The idea of coupled solver...

Thanks Philip

The idea of coupled solver (coupling these 3 equations before pimple loop) is interesting for me too. I found out that Foam-Extend has some coupled solver examples. I will proceed...
Forum: OpenFOAM Programming & Development May 26, 2017, 16:35
Replies: 47
Views: 6,186
Posted By babakflame
I have applied under-relaxation for the 3...

I have applied under-relaxation for the 3 equations of cPlus, cMinus and Ue. But how can I under-relax boundary conditions??

If you meant Fields, I have applied that too with values around 0.1, no...
Forum: OpenFOAM Programming & Development May 26, 2017, 14:08
Replies: 47
Views: 6,186
Posted By babakflame
This is the situation of residuals a few time...

This is the situation of residuals a few time steps before divergence:


Courant Number mean: 0.0135133107361 max: 0.0199948706422
Interface Courant Number mean: 0 max: 0
deltaT =...
Forum: OpenFOAM Programming & Development May 26, 2017, 14:00
Replies: 47
Views: 6,186
Posted By babakflame
Dear Philip many thanks for your help. ...

Dear Philip

many thanks for your help.

First of all, these are boundary files in 0 folder:
cPlus

FoamFile
{
version 2.0;
Forum: OpenFOAM Programming & Development May 26, 2017, 12:07
Replies: 47
Views: 6,186
Posted By babakflame
As you can see above philip, the Ue variable is...

As you can see above philip, the Ue variable is found through the Poisson equation (laplace with source term).

My boundary condition for Ue is Dirichlet type. I have tried the followings:


...
Forum: OpenFOAM Programming & Development May 25, 2017, 14:19
Replies: 47
Views: 6,186
Posted By babakflame
Dear Philip Many thanks for your help. ...

Dear Philip

Many thanks for your help.

Here is the main part of code (.C) file:


int main(int argc, char *argv[])
{
#include "setRootCase.H"
Forum: OpenFOAM Programming & Development May 19, 2017, 21:52
Replies: 47
Views: 6,186
Posted By babakflame
Even underrelaxing the related equations as...

Even underrelaxing the related equations as follows did not work.


relaxationFactors
{
fields
{

}
equations
Forum: OpenFOAM Programming & Development May 19, 2017, 14:22
Replies: 47
Views: 6,186
Posted By babakflame
Dear Fellows As abovementioned, I have...

Dear Fellows

As abovementioned, I have successfully implemented fixed flux boundary condition. However, after non-dimensionalizing my solver and boundary conditions, some scales are introduced...
Forum: OpenFOAM Programming & Development March 8, 2017, 10:21
Replies: 47
Views: 6,186
Posted By babakflame
Dear Philip Many thanks. I am gonna...

Dear Philip

Many thanks. I am gonna investigate term by term (in the way that you mentioned) to see exactly whats going on.

Regards
Forum: OpenFOAM Programming & Development March 7, 2017, 23:17
Replies: 47
Views: 6,186
Posted By babakflame
Dear Philip Many thanks for your reply.:) ...

Dear Philip

Many thanks for your reply.:)

As a respond to your comments:



I wasn't aware of the direction of n in OpenFoam in the way that you had mentioned, but by resimulating my...
Showing results 1 to 25 of 29

 
Forum Jump

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