|
[Sponsors] |
How to bring OpenFoam 2.1 viscosityModel to OpenFoam 2.2 |
![]() |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
![]() |
![]() |
#1 |
New Member
Marvin
Join Date: Jan 2014
Posts: 11
Rep Power: 13 ![]() |
Hello,
I'm trying to bring my viscosityModel from OpenFoam 2.1 to OpenFoam 2.2. I was told it worked with 2.1. So I have two questions. Can I simply install OF2.1 besides OF2.2 to check if the viscosity Model really works? The error that comes when typing wmake in OF 2.2 is marvin@marvin-VirtualBox:~/OpenFOAM/marvin-2.2.1/src/transportModels/viscoelastic$ wmake SOURCE=viscoelasticLaws/LPTT/LPTT.C ; g++ -m64 -Dlinux64 -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor -O3 -DNoRepository -ftemplate-depth-100 -I/opt/openfoam221/src/finiteVolume/lnInclude -IlnInclude -I. -I/opt/openfoam221/src/OpenFOAM/lnInclude -I/opt/openfoam221/src/OSspecific/POSIX/lnInclude -fPIC -c $SOURCE -o Make/linux64GccDPOpt/LPTT.o viscoelasticLaws/LPTT/LPTT.C: In member function ‘virtual void Foam::LPTT::correct()’: viscoelasticLaws/LPTT/LPTT.C:112:66: error: no match for ‘operator-’ in ‘Foam: ![]() ![]() ![]() ![]() viscoelasticLaws/LPTT/LPTT.C:112:66: note: candidates are: and then there are hundreds of canditates listed at the end it says: make: *** [Make/linux64GccDPOpt/LPTT.o] Error 1 I can't find that file LPTT.o. What can I do to debug? I already looked into the LPTT.c file but don't see what I should change in line 112 :66 .................................................. .......................................row 66 .................................................. ..........................................| .................................................. ..........................................v line 112: - fvm::Sp( epsilon_ / etaP_ * tr(tau_) + 1/lambda_, tau_ ) Has anyone experience with bringing models from one version to a newer version? Is there any changelog or comparable document? Thanks a lot for your help Last edited by Marvin_Rauch; January 20, 2014 at 05:15. |
|
![]() |
![]() |
![]() |
![]() |
#2 | |
Senior Member
|
Hi,
Quote:
|
||
![]() |
![]() |
![]() |
![]() |
#3 |
New Member
Marvin
Join Date: Jan 2014
Posts: 11
Rep Power: 13 ![]() |
Thanks, I haven't been able to reach my OpenFOAM pc. Here is the equation:
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * // tmp<fvVectorMatrix> LPTT::divTau(volVectorField& U) const { // dimensionedScalar etaPEff = (1 + 1/epsilon_)*etaP_; dimensionedScalar etaPEff = etaP_; return ( fvc::div(tau_/rho_, "div(tau)") - fvc::laplacian(etaPEff/rho_, U, "laplacian(etaPEff,U)") + fvm::laplacian( (etaPEff + etaS_)/rho_, U, "laplacian(etaPEff+etaS,U)") ); } void LPTT::correct() { // Velocity gradient tensor volTensorField L = fvc::grad( U() ); // Convected derivate term volTensorField C = tau_ & L; // Twice the rate of deformation tensor volSymmTensorField twoD = twoSymm( L ); // Stress transport equation tmp<fvSymmTensorMatrix> tauEqn ( fvm::ddt(tau_) + fvm::div(phi(), tau_) == etaP_ / lambda_ * twoD + twoSymm( C ) - zeta_ / 2 * ( (tau_ & twoD) + (twoD & tau_) ) - fvm::Sp( epsilon_ / etaP_ * tr(tau_) + 1/lambda_, tau_ ) ); tauEqn().relax(); solve(tauEqn); } I hope this helps you to help me with my problems. ![]() Thanks in advance! |
|
![]() |
![]() |
![]() |
![]() |
#4 |
Senior Member
|
From the error message and code I can suppose that OpenFOAM doesn't know how to subtract Tensor from SymmTensor. In the RHS of the equation all terms are SymmTensors except -fvm::Sp(...).
And answering one of your first questions: yes, you can install 2.1.x along with 2.2.2. |
|
![]() |
![]() |
![]() |
Tags |
changelog, lptt, models |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
[OpenFOAM.org] Patches to compile OpenFOAM 2.2 on Mac OS X | gschaider | OpenFOAM Installation | 136 | October 10, 2017 17:25 |
openfoam 2.2 force coefficients 0 | mihaipruna | OpenFOAM Running, Solving & CFD | 9 | February 19, 2017 08:32 |
Cross-compiling OpenFOAM 1.7.0 on Linux for Windows 32 and 64bits with Mingw-w64 | wyldckat | OpenFOAM Announcements from Other Sources | 3 | September 8, 2010 06:25 |
Cross-compiling OpenFOAM 1.6 on Linux for Windows 32 and 64bits with Mingw-w64 | wyldckat | OpenFOAM Announcements from Other Sources | 7 | January 19, 2010 15:39 |
OpenFOAM Training and Workshop | Hrvoje Jasak | Main CFD Forum | 0 | October 7, 2005 07:14 |