Commit 21b31984 authored by Alain O' Miniussi's avatar Alain O' Miniussi
Browse files

Merge commit 'c70465b5' into 597-compile-with-cuda

parents 832f0c68 c70465b5
......@@ -795,22 +795,18 @@ namespace fargOCA {
} else if ( temp < t456*pow(rho,2.381e-2)){
// to avoid overflow
real ts4 = 1.e-4*temp;
real rho13 = cbrt(rho);
real rho23 = rho13*rho13;
real ts42 = ts4*ts4;
real ts44 = ts42*ts42;
real ts48 = ts44*ts44;
// disjoint opacity laws for 3, 4, and 5.
real o3=bk3*ts4;
real o4=bk4*rho23/(ts48*ts4);
real o5=bk5*rho23*ts42*ts4;
real o4 = bk4*pow(cbrt(rho),2)/pow(ts4,9);
real o5 = bk5*pow(cbrt(rho),2)*pow(ts4,3);
// parameters used for smoothing
real o4an = pow(o4,4);
real o3an = pow(o3,4);
real o3an = pow(bk3*ts4,4);
// smoothed and continuous opacity law for regions 3, 4, and 5.
// FortranForm opacty=((o4an*o3an/(o4an+o3an))+(o5/(1+6.561e-5/ts48))**4)**0.25
opacity = pow((o4an*o3an/(o4an+o3an))+pow(o5/(1.0+6.561e-5/ts48),4.0),0.25);
opacity = pow((o4an*o3an/(o4an+o3an))+pow(o5/(1+6.561e-5/pow(ts4,8)),4),0.25);
} else if (temp < t678*pow(rho,2.267e-1) || rho <= 1.0e-10){
// to avoid overflow
real ts4 = 1.e-4*temp;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment