|
[Sponsors] |
April 30, 2012, 11:01 |
|
#81 | |||
New Member
Join Date: Apr 2012
Posts: 5
Rep Power: 14 |
Hello Niels,
First of all thanks for your work. I have followed the installation tutorial on the openFOAM Wiki to put waves2foam on my Mac (OS X 10.6.8 Snow Leopard). The problem is, I think the applications you created in the waves2foam directory are not taken into account when making ./Allwmake. I have this message : Quote:
Quote:
Furthermore, there is also a dependency list problem : Quote:
Where exactly shall I put the waves2foam directory ? Thanks in advance, |
||||
April 30, 2012, 12:11 |
|
#82 |
Senior Member
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Copenhagen, Denmark
Posts: 1,903
Rep Power: 37 |
Hi Nektos
I might not be able to help you, as I am not a MAC-person, but I will give me best guess. First of all, resolving the first error is the most important thing, as the other might disappear in doing so. To me the error suggests that the environmental variable WM_PROJECT_VERSION_NUMBER is not being set correctly in the waves2Foam/Allwmake and waves2Foam/src/Allwmake scripts. This is probably due to a difference between linux and MAC, since we have made a smooth compilation on 2.1.x on Ubuntu/Red hat. Thus, the first step is to figure out, whether or not this environmental variable is set at all, e.g. put Code:
echo "My variable: "$WM_PROJECT_VERSION_NUMBER Code:
#wmake libso With respect to the location of waves2Foam it really does not matter. I, however, always place it here: Code:
$FOAM_RUN/../applications/utilities Niels |
|
April 30, 2012, 12:31 |
|
#83 | |
Member
Björn Windén
Join Date: Feb 2012
Location: National Maritime Research Institute, Tokyo, Japan
Posts: 37
Rep Power: 14 |
Quote:
//Björn |
||
April 30, 2012, 13:27 |
|
#84 | |
New Member
Join Date: Apr 2012
Posts: 5
Rep Power: 14 |
Hey Niels,
Thanks for your answer. I have corrected manually all the "if" in the waves2foam files, it was quite long but now there is no problem with this 2n1n0. When I use "wmake" on the application folder, the only thing that does not work is "waveFoam". I have followed the Wiki instructions but I get this message : Quote:
Thx, Pierre. |
||
April 30, 2012, 13:53 |
|
#85 |
Senior Member
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Copenhagen, Denmark
Posts: 1,903
Rep Power: 37 |
Hi Pierre,
First of all, what was needed to succeed with the compilation? Secondly: Have you renamed interFoam.C to waveFoam.C? If that is the case and if you have corrected waveFoam/Make/files, then do the following in this succession in the waveFoam directory: Code:
wclean all wmake Niels |
|
May 1, 2012, 05:45 |
|
#86 | |||
New Member
Join Date: Apr 2012
Posts: 5
Rep Power: 14 |
Hi Niels,
First to succeed with the compilation I modified all the files in which you had the "if" concerning the openFOAM version. After that, it works. Then, I followed the exact tutorial on the wiki (modifying interFoam.C into waveFoam.C, and Make/Options and Make/Files, but I still get the message : Quote:
Quote:
Quote:
When I do that I get many errors like "*** was not declared in this scope". Thanks, Pierre. |
||||
May 1, 2012, 06:02 |
|
#87 |
Senior Member
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Copenhagen, Denmark
Posts: 1,903
Rep Power: 37 |
Hi Pierre,
Could you please be more specific on what was needed in relation to the "pre-processor if"s? Did you delete the if-statements and merely kept those lines relevant for 2.1.0? Secondly, the wiki was not completely clear on the naming. It has been updated, however, the essence is that interFoam.C -> waveFoam.C in Make/files. Besides that, you give so little information on the compilation errors that it is not possible to help. Regards, Niels |
|
May 1, 2012, 06:15 |
|
#88 |
Senior Member
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Copenhagen, Denmark
Posts: 1,903
Rep Power: 37 |
Hi Dominic and Björn,
I tried to have a look in the modified stokesFirstCurrent, and to me the most prominent difference is that the current is not ramped. Is that true? In that case, I believe you should be able to reproduce the results using combinedWaves with stokesFirst and potentialCurrent, where "Tsoft 0.0;" is stated in the latter waveTheory. Otherwise, there might be a bug in combinedWaves. Kind regards, Niels |
|
May 1, 2012, 06:37 |
|
#89 |
New Member
Join Date: Apr 2012
Posts: 5
Rep Power: 14 |
Sorry Niels, I am a beginner in computer science.
I deleted the "if-statements" and only left the condition appropriate for openFoam 2.1.0. I changed the Make/files as you said in your last post. The errors I have are in my .txt attached file. I hope it will help. Thanks for your help, |
|
May 1, 2012, 07:14 |
|
#90 | |
Member
Björn Windén
Join Date: Feb 2012
Location: National Maritime Research Institute, Tokyo, Japan
Posts: 37
Rep Power: 14 |
Quote:
//Björn |
||
May 1, 2012, 07:18 |
|
#91 |
Senior Member
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Copenhagen, Denmark
Posts: 1,903
Rep Power: 37 |
Hi Pierre
Thanks for the log file. It also helped me to identify the problem in compiling on a Mac. There will, as soon as I am on my linux installation, be made an update of the Allwmake script. The problem was a difference in the handling of newline characters between linux and Mac (Darwin) in "sed". Secondly, you get a lot of unpleasant errors, which I really do not understand the origin of, so in order to get it working, I suggests the following: 1. Copy the needed files from the interFoam directory to your own solver directory under waves2Foam. 2. Change interFoam.C -> waveFoam.C 3. Change the Make/files into Code:
waveFoam.C EXE = $(FOAM_USER_APPBIN)/waveFoam Furthermore, note that you have put "-DOFVERSION=2n1n0" in the options file, when you compile the solver, however, it should merely read "-DOFVERSION=21". Kind regards, Niels |
|
May 1, 2012, 07:19 |
|
#92 | |
New Member
Feng
Join Date: Oct 2011
Posts: 6
Rep Power: 15 |
Quote:
I have followed the installation tutorial on the openFOAM Wiki to put waves2foam on my linux desktop. The version of openFoam I used is 2.0.1. I have modified interfoam to wavefoam in a new folder. But when I wmake it, the following error happed: [QUOTE][Making dependency list for source file waveFoam.C could not open file relaxationZone.H for source file waveFoam.C could not open file readWaveProperties.H for source file waveFoam.C SOURCE=waveFoam.C ; g++ -m64 -Dlinux64 -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor -O3 -DNoRepository -ftemplate-depth-100 -I/home/users/feng/OpenFOAM/OpenFOAM-2.0.1/src/transportModels -I/home/users/feng/OpenFOAM/OpenFOAM-2.0.1/src/transportModels/incompressible/lnInclude -I/home/users/feng/OpenFOAM/OpenFOAM-2.0.1/src/transportModels/interfaceProperties/lnInclude -I/home/users/feng/OpenFOAM/OpenFOAM-2.0.1/src/turbulenceModels/incompressible/turbulenceModel -I/home/users/feng/OpenFOAM/OpenFOAM-2.0.1/src/finiteVolume/lnInclude -IlnInclude -I. -I/home/users/feng/OpenFOAM/OpenFOAM-2.0.1/src/OpenFOAM/lnInclude -I/home/users/feng/OpenFOAM/OpenFOAM-2.0.1/src/OSspecific/POSIX/lnInclude -fPIC -c $SOURCE -o Make/linux64GccDPOpt/waveFoam.o waveFoam.C:50:28: error: relaxationZone.H: No such file or directory waveFoam.C:67:36: error: readWaveProperties.H: No such file or directory In file included from waveFoam.C:70: createFields.H: In function ‘int main(int, char**)’: createFields.H:148: error: ‘relaxationZone’ was not declared in this scope createFields.H:148: error: expected ‘;’ before ‘relaxing’ waveFoam.C:97: error: ‘relaxing’ was not declared in this scope /home/users/feng/OpenFOAM/OpenFOAM-2.0.1/src/finiteVolume/lnInclude/readTimeControls.H:38: warning: unused variable ‘maxDeltaT’ make: *** [Make/linux64GccDPOpt/waveFoam.o] Error 1/QUOTE] Do you have an idea what I could do ? Best Regards feng |
||
May 1, 2012, 07:21 |
|
#93 |
Senior Member
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Copenhagen, Denmark
Posts: 1,903
Rep Power: 37 |
Hi Björn
Thanks, keep me posted on your progress, such that we can get these problems eliminated. All the best, Niels P.S. You should be able to use the new surfaceElevation utility to track the surface elevation in your domain easily. |
|
May 1, 2012, 07:24 |
|
#94 |
Senior Member
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Copenhagen, Denmark
Posts: 1,903
Rep Power: 37 |
Hi Feng,
You have not modified the Make/options file in your waveFoam directory as stated on the wiki (http://openfoamwiki.net/index.php/Co...2Foam#waveFoam). Kind regards, Niels |
|
May 1, 2012, 07:42 |
|
#95 |
Member
Björn Windén
Join Date: Feb 2012
Location: National Maritime Research Institute, Tokyo, Japan
Posts: 37
Rep Power: 14 |
Hi Niels.
The only difference I can see is that combinedWaves sums up the velocity contributions from different components in Code:
U += combinedWavesPtr_[cI]->U(x, time); Code:
scalar Uhorz = PI_ * H_ / period_ * Foam::cosh(K_ * (Z + h_)) / Foam::sinh(K_ * h_) * Foam::cos(omega_ * time - (k_ & x) + (k_ & current_) * time + phi_); Code:
return Uhorz * k_ / K_ - Uvert * direction_ + current_ //Björn |
|
May 1, 2012, 09:03 |
|
#96 |
New Member
Join Date: Apr 2012
Posts: 5
Rep Power: 14 |
Thanks Niels for your answer, wmake worked on waveFoam when I did what you said.
I will wait for your Allwmake file, and come back if i have any further problem. |
|
May 1, 2012, 09:17 |
|
#97 | |
New Member
Feng
Join Date: Oct 2011
Posts: 6
Rep Power: 15 |
Quote:
Thank you very for your apply. I have double cheak the Make/options file, I found that I just miss a "\" before -DOFVERSION=20 \ what a stupid mistake. I will follow the tuitions in waves2foam to learn about it. Hope it will help me for my research. best Rehards Feng |
||
May 1, 2012, 23:37 |
solitary waves with waves2Foam
|
#98 |
New Member
Stefan
Join Date: Jan 2011
Location: Bremen
Posts: 20
Rep Power: 15 |
Hi all,
I am currently playing around with the solitary waves, implemented in waves2Foam. I installed the package on a Ubuntu 11.10 system with OF210. All works fine. I already found out that its good to set x0 = -wave length. Are there already experiences and recommendations on min. length of relaxation zone and soft start option in dependency of wave length? Cheers Stefan Last edited by holodeck10; May 1, 2012 at 23:53. |
|
May 2, 2012, 05:14 |
|
#99 |
Senior Member
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Copenhagen, Denmark
Posts: 1,903
Rep Power: 37 |
Hi Pierre,
Allwmake and src/Allwmake is now updated to handle the problems with "sed". I hope this has solved the problems. Kind regards, Niels |
|
May 4, 2012, 05:12 |
|
#100 |
New Member
Philipp Lösse
Join Date: Nov 2011
Location: Germany
Posts: 2
Rep Power: 0 |
Hi Niels,
you asked for feedback about your post-processing utility with OF 2.1 in the old thread: In my case it is working well and without problems. I am currently running OF 2.1.x Best regards Philipp |
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Map of the OpenFOAM Forum - Understanding where to post your questions! | wyldckat | OpenFOAM | 10 | September 2, 2021 06:29 |
Re-Project topics | protocol | STAR-CCM+ | 0 | March 22, 2016 06:25 |
Waves2Foam Related Topics | seoseonguk | OpenFOAM Running, Solving & CFD | 0 | March 1, 2016 23:18 |
Waves2Foam Related Topics | seoseonguk | OpenFOAM Running, Solving & CFD | 0 | March 1, 2016 23:14 |
Error: "Cannot find file points" related to changing parallelized code to serial? | Suyf | OpenFOAM Running, Solving & CFD | 0 | February 12, 2015 05:31 |