|
[Sponsors] |
January 11, 2016, 02:11 |
Error about correctPhi during compilation
|
#1 |
New Member
Federica
Join Date: Oct 2015
Posts: 13
Rep Power: 11 |
Hi everybody,
I'm trying to compile a new solver, but during the compilation I have this error: correctPhi.H:2:1: error: expected constructor, destructor, or type conversion before ‘(’ token ( ^ In file included from correctPhi.H:11:0, from myInterPhaseChangeFoam.C:41: /opt/OpenFOAM/OpenFOAM-3.0.0/src/finiteVolume/lnInclude/continuityErrs.H:32:1: error: expected unqualified-id before ‘{’ token { ^ What is wrong with my solver? The correctPhi.H file is this: CorrectPhi ( U, phi, p_rgh, dimensionedScalar("rAUf", dimTime/rho.dimensions(), 1), geometricZeroField(), pimple ); #include "continuityErrs.H" I am using OpenFoam 3.0.0 Thank you! |
|
January 26, 2017, 15:16 |
|
#2 |
Member
Linyan X
Join Date: Dec 2015
Posts: 43
Rep Power: 10 |
Hi my friend,
Were you create your solver based on 'interFoam' solver? Is there anything updated for this system's complaint? I am also facing this problem. Regards, Linyan |
|
June 16, 2017, 07:27 |
|
#3 | |
Senior Member
Nguyen Duy Trong
Join Date: Apr 2014
Posts: 124
Rep Power: 12 |
Quote:
Have you solved your problem, could you please share with me the way to overcome it? Thanks in advance |
||
November 1, 2017, 19:55 |
|
#4 |
New Member
Join Date: Sep 2017
Posts: 7
Rep Power: 9 |
Hi
I faced the same error while trying to build a custom interFoam solver. What solved it was being more specific about the include CorrectPhi.H (Capital C) . So, at the includes before main I changed #include "CorrectPhi.H" with #include "cfdTools/general/CorrectPhi/CorrectPhi.H", and added -I$(LIB_SRC)/finiteVolume \ to my options file. We are not using the same version of OpenFOAM but I hope this helps. Last edited by Genji; November 2, 2017 at 12:04. |
|
November 27, 2017, 16:53 |
|
#5 | |
Senior Member
Nguyen Duy Trong
Join Date: Apr 2014
Posts: 124
Rep Power: 12 |
Quote:
It works well. Thank you very much for your suggestion. |
||
December 2, 2020, 08:03 |
|
#6 | |
New Member
Daniele
Join Date: Oct 2016
Posts: 2
Rep Power: 0 |
Quote:
#include "CorrectPhi.H" with #include "path/where/CorrectPhi/is/effectively/located", (in my case /opt/OpenFOAM/OpenFOAM-v2006/src/finiteVolume/lnInclude/CorrectPhi.H) Thank you very much! |
||
June 5, 2021, 17:03 |
|
#7 |
New Member
Deshik
Join Date: Jun 2021
Location: India
Posts: 5
Rep Power: 5 |
Hi! I have tried all the suggestions you gave in this thread. Earlier I used to get errors, and when I followed all your suggestions, now I didn't get any. But when I run a test case I didn't get the results. (you can see in the image)
If anyone resolved this issue completely please help.. I have also attached the appropriate files.... Thanks in advance.. |
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Compilation error for OpenFOAM-ext on Ubantu 10.04 32 bit | Sargam05 | OpenFOAM Installation | 13 | March 22, 2014 06:21 |
[swak4Foam] swak4Foam compilation for OF-2.0.0 | camoesas | OpenFOAM Community Contributions | 19 | December 10, 2012 14:24 |
Compilation Error (V 1.7.1; Icc 12.1.0, OpenMPI 1.4.3) | floydfan | OpenFOAM Installation | 7 | December 20, 2011 06:56 |
errors during compilation and installation of OpenFOAM-1.7.x on Ubuntu 10.04 | ftec | OpenFOAM Installation | 7 | February 23, 2011 07:07 |
Compilation Error.... | Arnab | Siemens | 4 | September 12, 2004 16:54 |