How to multiply volScalarField and fvScalarMatrix ?
Dear Foamers,
I am interested in multiplying or dividing a fvScalarMatrix by a volScalarField. In a case of a fvc operator like fvc::div or fvc::laplacian the code compiles. For example : Quote:
Quote:
Unfortunately when it comes to implicit operator (fvm) the code doesn't compile : Quote:
How can we solve this issue ? Am I asking something unrealistic ? In a pure mathematical way it makes sense. But OpenFOAM doesn't seem to like it. All help would absolutely be helpful. F |
Hello Fauster,
laplacian is misspelled. |
Quote:
Quote:
I can copy paste the message error at compilation but for me it's like this is not authorized by OpenFOAM. For example if you try to do something like fvc::interpolate(surfaceScalarField). |
Dear Fauster,
I had same problem as you. It seems if you switch the order of multiplication, it works OK. That is volScalarField*fvScalarMatrix IS possible. But, fvScalarMatrix*volScalarField gives compilation error: Code:
volScalarField rhoCp1 = rho1*alpha1*mixture.thermo1().Cp() + rho2*alpha2*mixture.thermo2().Cp(); |
All times are GMT -4. The time now is 09:12. |