Adding an internal heat source for compressibleTwoPhaseEulerFoam
1 Attachment(s)
Hello dear Foamers,
I am working on the simulation of a plasma-arc-welding process and I am using the compressibleTwoPhaseEulerFoam Solver now, because it calculates the two phases (I use Argon and Air) and the temperature which I am looking for mainly. But to be exact enough I need a heat source, where the electrical current is flowing through the plasma. I would try to create a new Field "q" which would describe the increasing energy in the cells relative to the geometrical size of the cell. I found already an interesting post like this one: http://www.cfd-online.com/Forums/ope...ionfoam-2.html And this one: http://www.cfd-online.com/Forums/ope...ew-solver.html But the solver is still different. I don't have a TEqn.H. I guess I need to change the EEqn.H, but I don't know how to do it in detail. I don't know much about C++ and the "Programmers Guide" didn't enlighten me much too. My plan would be: - a readable heat source file for the Mesh [Joule/Second/m³] - accessing the volumetric size of the cells [m³] - calculating the total additional energy of the cell [Joule/Second/m³]*[m³]*[StepTimeSeconds] - subtracting it in the right part of the following equation Code:
Also I attached a slice of my 3D-model. I would appreciate your help a lot. Sincerely Kenna |
Current try
Well, so far I could create a Qp (heat flux) field with this dimensions (0, 2, -3, 0, 0, 0, 0).
I put a Qp file in the latest Time folder and put where the electric arc should be, via setFieldsDict in a cylindrical Form the value 2.14748e+09. The rest stays zero. in the createFields.H from the solver I entered this: Code:
Info<< "Reading field Qp\n" << endl; I added Qp very simple in the EEqn. Code:
fvScalarMatrix he1Eqn Code:
dimensions [0 2 -3 0 0 0 0]; Code:
dimensions [0 2 -3 0 0 0 0]; |
Could you try without the red line (and the comma at the line above after "mesh").
Quote:
|
Quote:
The temperature is rising in the right area. The pressure doesn't change as expected, because it is an open system. So far I have no further question :) |
All times are GMT -4. The time now is 07:36. |