2 Attachment(s)
Hi,
same solutions with simple and pimple. Attachements |
2 Attachment(s)
Hi,
unfortunately I have mixed up the correct solver with an old one with errors. A thunder storm killed the hard disk with the new, correct version and I posted my obsolete one - always back up, and correct old stuff as well ... So the correct scalar equation with sources: Code:
tmp<fvScalarMatrix> TEqn Code:
sources.constrain(TEqn()); Add sourcesProperties folder to your constant folder with entries: Code:
age I double-checked this solution, and it gives the exact values of the solver that Andrew King has attached a while back. Andrew, thanks for your solution, quite useful! About the term in the laplacian, I "borrowed" the idea from Daniel C, here's what he said about the issue. I set DT to zero since I don't want additional diffusion. I don't know if this method can be used in a steady-state case since there's no explicit time stepping. But if the solution matches the transient version more or less than it can be valid. WARNING: I don't validated any result to real world tests. Feel free to correct the solver, add your thoughts, thank you! About your question: if the flow is laminar, incompressible and you now the inlet properties (velocity / flow rate), I think it's just some basic calculations and it depends on the geometry of the diffusor. When the flow is turbulent I don't know how to calculate it, maybe there's some good approximations out there. |
Hi
also it seems a dead thread.but I hope not and propound my question! I have a inflow patch and need a lot to know if the inflowing fluid has reached to outflow patch or not. preferably by rhoPimpleFoam. both the fluid that rest in the channel at first(internalField) and the fluid is entering are the same (air) but entering air has more pressure and temperature. is it possible to track entering air particles through the unsteady case I have? to give more information if is important to answer the case is a rectangular tube with one inflow and one outflow patch. how to modify the files in this thread in my case? |
Quote:
you can use implement a conserved scalar transport equation for that! At the beginning your scalar is 1 at the inlet and the rest is zero. While simulating your scalar is transported through the domain. In your case you should only use the transport due to convection and so you can have a look when the scalar reaches the outlet! Hope its helpful. Tobi |
Hi Tobias
thanks for rapid reply! I haven't modified a solver to solve for a new equation. then could you please guide me. I've added this in createFields: Code:
volScalarField age in the folder of solver I have to add this: Code:
// --- Scalar Transport and what should be assign for DT?and also change nut to mut(since my case is compressible,unsteady) correct? (does it work if I switch to a turbulent case too?) |
Hi,
have a look at my solver: https://github.com/shor-ty/scalarRhoSimpleFoam Then use the scalarEqn.H and the entry in the createFields.H for your own pimple solver! If there are any problems ask me! Have a nice evening, Tobi |
thanks.
1)I can't download.this error occurs: Code:
https://github.com/shor-ty/scalarRhoSimpleFoam.git Code:
// --- Scalar transport should I delete laplacian term totally?why you have not done this to delete laplacian term?then how can account for turbulence? 4)what does this term is added?what does do? Code:
- fvm::Sp(fvc::div(phi), S) |
hi
could you please help me with questions?:) |
Quote:
i was at work till now. 1. on my computer the github link is working! 2. you have to set ddt into that equation; in my case I used the SIMPLE algo (steady-state; ddt = 0) 3. let the diffusion term in your case 4. thats a numerical trick for stabilisation |
|
thanks.then can you please give me a more description (or there is a source and internet link for that) about the term you has added for more stability.because may it be necessary to give some description in my thesis about each of terms in equations.
|
Quote:
|
ok.thank you.that would be nice.then i wait untill you come back.
and what does that expression argument in parenthesis in solve() function mean?is that for cases we have moving mesh? Code:
SEqn().solve(mesh.solver("S")); |
and also in rhoPimpleFoam solver below is the position of gasEquation.H suitable(several times it solves) or it is better to be after pimple.loop() to solve one time each time step?
Code:
int main(int argc, char *argv[]) |
1 Attachment(s)
hello again
excuse me for questions. I run the case but gas(scalar value) is not between 0 and 1 as the snapshot. how to resolve? thanks. |
Quote:
http://www.cfd-online.com/Forums/ope...tml#post407482 |
yes.at last i put the name gas in return of S.because air flowing in has a higher pressure and temperature than air in domain.shouln't it be between 0 and 1
|
The value of your scalar depend on yuor BC settings!
|
i have set it 1 for inflow and 0 for initial condition as you told.
Maybe because my case is compressible a change should be done. The dimension is zero[0 0 0 0 0 0].is it correct? |
I am a bit confused couse the tutorial added in my git repo is not the one i build for that. Its the CO/H2/N2 mesh :D
well maybe I have time to resolve that mesh but first I reset my computer for Arch Linux |
All times are GMT -4. The time now is 11:03. |