diff --git a/CMakeLists.txt b/CMakeLists.txt index a20157588..9c9cc1862 100755 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -71,7 +71,7 @@ set(CMAKE_INSTALL_BINDIR "${CMAKE_INSTALL_ROOT}/bin") set(CMAKE_INSTALL_INCLUDEDIR "${CMAKE_INSTALL_ROOT}/include") set(CMAKE_INSTALL_LIBDIR "${CMAKE_INSTALL_ROOT}/lib") set(CMAKE_INSTALL_PVPLUGINDIR "${CMAKE_INSTALL_ROOT}/lib/pv_plugin") # Must be in separate dir! -set(CMAKE_BDM_PVPLUGINDIR "${CMAKE_INSTALL_ROOT}/../paraview_plugin/") +set(CMAKE_BDM_PVPLUGINDIR "${CMAKE_SOURCE_DIR}/paraview_plugin/") set(CMAKE_INSTALL_CMAKEDIR "${CMAKE_INSTALL_ROOT}/cmake") set(CMAKE_INSTALL_DATADIR "${CMAKE_INSTALL_ROOT}/share") set(CMAKE_INSTALL_CMAKEDATADIR "${CMAKE_INSTALL_DATADIR}/cmake") diff --git a/doc/dev_guide/contribute.md b/doc/dev_guide/contribute.md index 1da4a23b4..94874885c 100644 --- a/doc/dev_guide/contribute.md +++ b/doc/dev_guide/contribute.md @@ -68,7 +68,11 @@ Also for intermediate commit messages: have a look at #### 7. Compile and run tests ``` bash -make && make check +make && make run-check +``` +or +``` bash +ninja && ninja run-check ``` Please make sure that there are no compiler warnings diff --git a/src/core/diffusion/diffusion_grid.cc b/src/core/diffusion/diffusion_grid.cc index 592ea00c7..98826efcb 100644 --- a/src/core/diffusion/diffusion_grid.cc +++ b/src/core/diffusion/diffusion_grid.cc @@ -303,9 +303,9 @@ void DiffusionGrid::ChangeConcentrationBy(size_t idx, double amount) { std::lock_guard guard(locks_[idx]); assert(idx < locks_.size()); c1_[idx] += amount; - c1_[idx] = (c1_[idx] > upper_threshold_) - ? upper_threshold_ - : (c1_[idx] < lower_threshold_) ? lower_threshold_ : c1_[idx]; + c1_[idx] = (c1_[idx] > upper_threshold_) ? upper_threshold_ + : (c1_[idx] < lower_threshold_) ? lower_threshold_ + : c1_[idx]; } /// Get the concentration at specified position diff --git a/src/core/diffusion/euler_grid.cc b/src/core/diffusion/euler_grid.cc index faa58baed..e221b6b80 100644 --- a/src/core/diffusion/euler_grid.cc +++ b/src/core/diffusion/euler_grid.cc @@ -122,10 +122,11 @@ void EulerGrid::DiffuseWithOpenEdge(double dt) { ++s; ++b; ++t; - c2_[c] = c1_[c] * (1 - mu_ * dt) + - (d * dt * ibl2) * - (c1_[c - 1] - 2 * c1_[c] + c1_[c + 1] + c1_[s] - - 2 * c1_[c] + c1_[n] + c1_[b] - 2 * c1_[c] + c1_[t]); + c2_[c] = + c1_[c] * (1 - mu_ * dt) + + (d * dt * ibl2) * (c1_[c - 1] - 2 * c1_[c] + c1_[c + 1] + + l[0] * c1_[s] - 2 * c1_[c] + l[1] * c1_[n] + + l[2] * c1_[b] - 2 * c1_[c] + l[3] * c1_[t]); } ++c; ++n; diff --git a/util/housekeeping/check-submission.sh b/util/housekeeping/check-submission.sh index a6d9c48d7..96c38d2e6 100755 --- a/util/housekeeping/check-submission.sh +++ b/util/housekeeping/check-submission.sh @@ -26,7 +26,7 @@ LAST_RET_VAL=$? if [ $LAST_RET_VAL != 0 ]; then RETURN_VALUE=$LAST_RET_VAL fi -cmake --build $BINARY_DIR --target check +cmake --build $BINARY_DIR --target run-check LAST_RET_VAL=$? if [ $LAST_RET_VAL != 0 ]; then RETURN_VALUE=$LAST_RET_VAL