CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Programming & Development

Diffenence between omega_ and omega_()

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   July 24, 2020, 05:19
Post Diffenence between omega_ and omega_()
  #1
New Member
 
You Wu
Join Date: Nov 2018
Posts: 16
Rep Power: 8
Youwu is on a distinguished road
Hi all,
I'm working on k - omega SST model recently. After reading the code, I found a problem.
In the definition of epsilonByk, omega_() is used:
Code:
template<class BasicEddyViscosityModel>
tmp<volScalarField::Internal>
kOmegaSSTBase<BasicEddyViscosityModel>::epsilonByk
(
    const volScalarField& F1,
    const volTensorField& gradU
) const
{
    return betaStar_*omega_();
}
However, in the definition of F2, omega_ is used:
Code:
template<class BasicEddyViscosityModel>
tmp<volScalarField> kOmegaSSTBase<BasicEddyViscosityModel>::F2() const
{
    tmp<volScalarField> arg2 = min
    (
        max
        (
            (scalar(2)/betaStar_)*sqrt(k_)/(omega_*y_),
            scalar(500)*(this->mu()/this->rho_)/(sqr(y_)*omega_)
        ),
        scalar(100)
    );
    return tanh(sqr(arg2));
}
I tried to output omega_ and omega_() into a log file, and they are exactly the same volscalarfield.
But sometimes when I tried to change omega_() into omega_, I got compiling errors.
So, what's the difference between omega_ and omega_()? What
do those parentheses mean?
Youwu is offline   Reply With Quote

Old   July 24, 2020, 07:50
Default
  #2
Senior Member
 
Join Date: Dec 2019
Location: Cologne, Germany
Posts: 369
Rep Power: 8
geth03 is on a distinguished road
i think omega_ is the variable and omega_() is the getter function for omega_.
geth03 is offline   Reply With Quote

Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
[solids4Foam] How to calculate drag coeff when using solids4Foam amuzeshi OpenFOAM CC Toolkits for Fluid-Structure Interaction 15 November 7, 2019 13:50
Initial and Final Residual of omega 0 by calculation with k-w turbulence model Stuntmanbob OpenFOAM Running, Solving & CFD 3 August 18, 2019 06:02
Behaviour of the kOmegaSST in a steady-state case Max1234 OpenFOAM Running, Solving & CFD 18 October 31, 2018 09:03
Floating point exception error lpz_michele OpenFOAM Running, Solving & CFD 53 October 19, 2015 03:50
how to calculate the omega at inlet boundary in k omega sst Scabbard OpenFOAM Running, Solving & CFD 2 September 30, 2014 14:06


All times are GMT -4. The time now is 01:41.