Skip to content

Commit

Permalink
Merge branch 'master' of https://github.com/microhh/microhh into mast…
Browse files Browse the repository at this point in the history
…erupstream
  • Loading branch information
Chiil committed Dec 8, 2016
2 parents 38fe4a1 + 594c431 commit f146a60
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
10 changes: 5 additions & 5 deletions src/fields.cxx
Expand Up @@ -723,17 +723,17 @@ int Fields::randomize(Input* inputin, std::string fld, double* restrict data)
nerror += inputin->get_item(&rndz , "fields", "rndz" , fld, 0.);
nerror += inputin->get_item(&rndexp, "fields", "rndexp", fld, 0.);

// Find the location of the randomizer height.
int kendrnd = grid->kstart;
while (grid->z[kendrnd] < rndz)
++kendrnd;

if (rndz > grid->zsize)
{
master->print_error("randomizer height rndz (%f) higher than domain top (%f)\n", rndz, grid->zsize);
return 1;
}

// Find the location of the randomizer height.
int kendrnd = grid->kstart;
while (grid->z[kendrnd] < rndz)
++kendrnd;

// Issue a warning if the randomization depth is larger than zero, but less than the first model level.
if (kendrnd == grid->kstart && rndz > 0.)
master->print_warning("randomization depth is less than the height of the first model level\n");
Expand Down
2 changes: 1 addition & 1 deletion src/stats.cxx
Expand Up @@ -1028,7 +1028,7 @@ void Stats::calc_cover(double* restrict data, double* restrict maskbot, int* res
}
}
*cover /= (double)*nmaskbot;
grid->get_prof(cover,1);
master->sum(cover,1);
}
else
*cover = NC_FILL_DOUBLE;
Expand Down

0 comments on commit f146a60

Please sign in to comment.