CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Programming & Development (https://www.cfd-online.com/Forums/openfoam-programming-development/)
-   -   where can I find functions definition in OF? (https://www.cfd-online.com/Forums/openfoam-programming-development/112184-where-can-i-find-functions-definition.html)

asoltoon January 23, 2013 08:57

where can I find functions definition in OF?
 
Hello guys,
I wanna see some function definitions in KEpsilon.C, but I don't know where it is. I'v also searched in the OpenFoam.org 's C++ source guide but it was not useful.
I would be grateful if anybody could help me.

Thanks in advance.

Hisham January 23, 2013 09:12

Hello Ali

What do you mean by definition: the code or some explanation?

Is there a specific function that you are searching for?

Best regards,
Hisham

asoltoon January 23, 2013 10:14

Hello Hisham,
I mean the code implementation. There is lots of functions I would like to see their code, but for instance how I could find the DkEff() implementation. The function is used in KEpsilon.C.

Thanks

Hisham January 23, 2013 13:05

Quote:

Originally Posted by asoltoon (Post 403583)
Hello Hisham,
I mean the code implementation. There is lots of functions I would like to see their code, but for instance how I could find the DkEff() implementation. The function is used in KEpsilon.C.

Thanks

You just press on any link that says:
Definition at line 185 of file kEpsilon.C.

the kEpsilon.C link will take you to:
http://foam.sourceforge.net/docs/cpp/a08551_source.html

asoltoon January 23, 2013 14:00

But line 185 of the link that you mentioned doesn't point to the implementation of the DkEff() function. This function is declared at line 253 of kEpsilon.C & its implementation should be in another class I think. and when I click on the function colored in blue (at line 253), the opened page doesn't show me the function's code.

Thanks for your reply man ;)

mm.abdollahzadeh January 23, 2013 14:43

Quote:

Originally Posted by asoltoon (Post 403613)
But line 185 of the link that you mentioned doesn't point to the implementation of the DkEff() function. This function is declared at line 253 of kEpsilon.C & its implementation should be in another class I think. and when I click on the function colored in blue (at line 253), the opened page doesn't show me the function's code.

Thanks for your reply man ;)

Hi

you could find the definition in

Definition at line 129 of file kEpsilon.H.

Cheers
mahdi

Hisham January 23, 2013 15:55

@ mahdi .. thanks

@ all: Sorry .. I just meant to tell you that the file is accessible from such lines that says definition at line ....

I hope this wasn't confusing ... :confused:


You can also find the function in your computer by going to the source code directory and typing:
Code:

grep -iIr "DkEff" .
and don't forget the "."

and then use Ctrl+f to search for the function inside the file after you open it with your text editor

Hisham


All times are GMT -4. The time now is 22:39.