Accuracy of boundary conditions

Questions and remarks about code_saturne usage
Forum rules
Please read the forum usage recommendations before posting.
rodion
Posts: 98
Joined: Wed Jan 11, 2017 4:13 pm

Accuracy of boundary conditions

Post by rodion »

Hello everyone,

I am working with a model of electric arc plasma torch. In my model I got a fluid domain, a cathode and an anode. To achieve the desired electric current I impose electric potential difference for the anode and the cathode back surfaces.

Looking through my results I found an interesting phenomenon: the temperature in the boundary cells can be surprisingly higher than the temperature in the neighboring cells and the boundary condition.
For example the thermal boundary condition is 14000 J/kg, internal cells have enthalpy 14000 J/kg, but still the boundary cells are a bit hotter. Please find the picture attached. Does someone know what can be the reason?

Also there is a strange phenomenon with the electric current density distribution: in a cylindrical electrically conducting cathode the boundary cells have higher electric current than the internal cells. Which gives us higher total electric current in the boundary cells. And hence, we get nonconservation of electric current. Please find the picture attached. Is it supposed to be like that or it is a mistake?

Best regards,
Rodion
Attachments
BC_el_current_problem.png
BC_enthalpy_problem.png
Last edited by rodion on Sun Jun 10, 2018 4:59 pm, edited 2 times in total.
Yvan Fournier
Posts: 4209
Joined: Mon Feb 20, 2012 3:25 pm

Re: Accuracy of boundary conditions

Post by Yvan Fournier »

Hello,

Are you comparing the temperature at boundary cells or boundary faces ? On which version of the code ?

For temperature, we usually try to "reconstruct" values matching a given heat flux, so with turbulent wall laws, due to the boundary layer, the wall temperature may be significantly higher then the mean cell temperature. This might explain your observation.

If you are prescribing Dirichlet type boundary conditions, the value should match, and not be higher in boundary cells. Perhaps this is due to the temperature-enthalpy conversion in the electric arcs module (as there are separate functions for boundary faces and volume cells).

Best regards,

Yvan Fournier
rodion
Posts: 98
Joined: Wed Jan 11, 2017 4:13 pm

Re: Accuracy of boundary conditions

Post by rodion »

Thank you for your quick response, Yvan.

I use Code_Saturne 5.0.7. There is no turbulence in my model. The thermal variable in electric arc simulation is enthalpy. So temperature is just a property and that is why I do not refer to the temperature distribution here. The pictures attached above depict the values in the cells.
And yes, I have Dirichlet boundary condition for Enthalpy.

Also there is a similar problem in electric current density distribution.

Do you know what can be the reason? Probably the gradient calculation for boundary cells has some problem?

Best regards,
Rodion
Yvan Fournier
Posts: 4209
Joined: Mon Feb 20, 2012 3:25 pm

Re: Accuracy of boundary conditions

Post by Yvan Fournier »

Hello,

The gradient explanation is plausible, but might need checking. Is this a solver variable or computed property ?
If it is a variable, results are indeed strange.

Reproducing this on a small example mesh with a simpler setting (basic model) could help analyze this.

Best regards,

Yvan
rodion
Posts: 98
Joined: Wed Jan 11, 2017 4:13 pm

Re: Accuracy of boundary conditions

Post by rodion »

Dear Yvan,

Yes, Enthalpy is a solver variable. I cannot have temperature as the main thermal variable for electric arc simulation.

Also I have checked my other results and found that this problem appears ONLY with:
— Code_Saturne 5.0.7 (not for 5.0.5)
— Involved cs_user_internal_coupling_add_volumes( ) (i.e. with electrodes included into the simulation domain)
— Dirichlet boundary condition for enthalpy (see the picture above)

Without any of this conditions the problem does not appear. In other words either with CS 5.0.5, or with Neumann boundary condition for enthalpy, or without internal_coupling (i.e. without electrodes included into the domain) the boundary cells have adequate values of enthalpy.

At the same time electric current density is a property derived from electric potential. Electric current density field has this problem with high values in boundary cells for different CS versions, for different geometries and for different types of boundary conditions for electric potential (either Neumann or Dirichlet).

Best regards,
Rodion
Yvan Fournier
Posts: 4209
Joined: Mon Feb 20, 2012 3:25 pm

Re: Accuracy of boundary conditions

Post by Yvan Fournier »

Hello,

This is very strange. Checking the changes between versions 5.0.5 and 5.0.7, I see no change which could explain this, except possibly postprocessing or renumbering issues. What mesh format are you using ? Any renumbering ?

Did you try running under Valgrind ? There might be another, more subtle issue which appears in a different form or is hidden depending on the version.

Best regards,

Yvan
rodion
Posts: 98
Joined: Wed Jan 11, 2017 4:13 pm

Re: Accuracy of boundary conditions

Post by rodion »

Dear Yvan,

I have taken a look at a more detailed result and found, that it exist in 5.0.5 too. This issue appears only during first several hundreds of time steps. But I had output for 5.0.5 only after 1000 steps. Sorry for misleading information.
My meshes have the format I-deas (*.unv) and they are constructed in ICEM-CFD.

I have found the same problem for another geometry. Please find the picture attached. Furthermore, we can see the similar effect at the intermediate Ogrid.

Maybe there is some problem with the mesh structure? Or Dirichlet boundary conditions in CS is not compatible with I-deas meshes?
Also I still can see a lot of cases where enthalpy is negative at some certain cells which had high velocity before. Or electric conductivity can be lower than any values in dp_ELE.

Excuse me, could you please explain what do you call "renumberring"?

Also do you have any idea about the source of too high electric current density values at the boundary cells?

Best regards,
Rodion
Attachments
BC_enthalpy_problem_F4.png
Yvan Fournier
Posts: 4209
Joined: Mon Feb 20, 2012 3:25 pm

Re: Accuracy of boundary conditions

Post by Yvan Fournier »

Hello,

The mesh format should not have any influence. The orthogonality of cells near the boundary may have an influence due to recontruction, but in your screenshots, the mesh seems quite clean in that area so this is probably not the cause).

If you do not know about mesh renumbering, it probably means you are not using it, so this cannot explain the issue either.

The problem might be specific to the electric arcs model, so a small test case on which we could try to reproduce this would be nice (the smallest case on which this appears would be nice).

Also, it the problem dissapears after a time, it might be due to transient or initialization-related issues (and might not be such an issue, though we need to understand it to be sure).

Regards,

Yvan
rodion
Posts: 98
Joined: Wed Jan 11, 2017 4:13 pm

Re: Accuracy of boundary conditions

Post by rodion »

Thank you for your quick response, Yvan.

Okay, I will try to reproduce the issue with a more simple case with electrodes and electric arc a bit later.

I was a bit worried by this issue because it may overestimate the fluid temperature at the cathode surface, which can change the fluid electric conductivity and eventually the the electric arc shape.

Best regards,
Rodion
rodion
Posts: 98
Joined: Wed Jan 11, 2017 4:13 pm

Re: Accuracy of boundary conditions

Post by rodion »

Dear Yvan,

I have built a small simple case with an electric arc in the gas gap. The plasma forming gas is Argon. Imposed electric current is 100 Amp. The case has only gas phase without solid electrodes.
The cylindrical domain is 20 mm high. The mesh consists of 72800 cells.

I have calculated the electric current values through the different cell layers. We can see that in the boundary layer the electric current value is about 80 A, in the second layer it is about 120 A, while the value of electric current through the internal layers is about 103 A. Please, take a look on the picture below.

Hence we can see discontinuity of electric current density about ±20% close to the boundary. I guess there should be some problem with electric potential gradient calculation at the boundary since electric current density is J=-σ∇φ.

Do you have any ideas for the solution of this problem?

Please find all the file for this case by the following link:
https://drive.google.com/open?id=1UlHgj ... HG2pV5BKCA

Best regards,
Rodion
Attachments
Electric current 2.png
Post Reply