mirror of
https://github.com/openmc-dev/openmc.git
synced 2026-07-28 14:15:42 -04:00
Moving some comments.
This commit is contained in:
parent
f912506b8e
commit
1aa7abd7fa
1 changed files with 5 additions and 2 deletions
|
|
@ -1,3 +1,4 @@
|
|||
|
||||
#include "openmc/cell.h"
|
||||
|
||||
#include <cmath>
|
||||
|
|
@ -616,7 +617,8 @@ DAGCell::DAGCell() : Cell{} {};
|
|||
std::pair<double, int32_t>
|
||||
DAGCell::distance(Position r, Direction u, int32_t on_surface) const
|
||||
{
|
||||
// if we've changed direction, reset the history and update last direction
|
||||
// if we've changed direction or we're not on a surface,
|
||||
// reset the history and update last direction
|
||||
if (u != last_dir || on_surface == 0) {
|
||||
history.reset();
|
||||
last_dir = u;
|
||||
|
|
@ -633,7 +635,8 @@ DAGCell::distance(Position r, Direction u, int32_t on_surface) const
|
|||
int surf_idx;
|
||||
if (hit_surf != 0) {
|
||||
surf_idx = dagmc_ptr_->index_by_handle(hit_surf);
|
||||
} else { // indicate that particle is lost
|
||||
} else {
|
||||
// indicate that particle is lost
|
||||
surf_idx = -1;
|
||||
dist = INFINITY;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue