|
[Sponsors] |
October 21, 2014, 10:10 |
fvMatrix (my code is working, but why?!)
|
#1 |
New Member
Join Date: Jul 2014
Posts: 13
Rep Power: 11 |
Hi everybody,
I have always thought that when defining a fvMatrix for an equation([a][x] = [b]), the matrix of coefficients ([a]) is introduced using fvm:: operators and everything that goes to the source vector ([b]) should be a geometric field of the same type as the unknown [x] (at least according to the programmers guide). BUT when trying to add a source term to my energy equation, I used a scalar (not a volScalarField) and it worked! The implementation is as bellow: fvScalarMatrix TEqn ( fvm::ddt(T) + fvm::div(phi, T) - fvm::laplacian(alpha, T) + Q ); where Q has already been defined as: dimensionedScalar Q ( transportProperties.lookup("Q") ); How is it possible?! Could somebody explain me a little bit plz? Many thanks, P |
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
COBRAS code | novan tofany | Main CFD Forum | 0 | October 8, 2012 04:40 |
Femlab: why isn't this code working? | Max | COMSOL | 2 | April 9, 2008 09:35 |
Design Integration with CFD? | John C. Chien | Main CFD Forum | 19 | May 17, 2001 15:56 |
What is the Better Way to Do CFD? | John C. Chien | Main CFD Forum | 54 | April 23, 2001 08:10 |
own Code vs. commercial code | Bernhard Mueck | Main CFD Forum | 10 | February 16, 2000 10:07 |