Ignore:
Timestamp:
Apr 9, 2013, 8:44:10 PM (13 years ago)
Author:
Julian Iseringhausen <isering@…>
Children:
b3075a
Parents:
1a1be0
Message:

Fixed position to index conversion errors.# Please enter the commit message for your changes. Lines starting

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/units/particle/comm_mpi_particle.cpp

    r1a1be0 r866ac4  
    8787
    8888  for (int i=0; i<num_particles_local; ++i) {
    89     index = grid.Global().GlobalBegin() + static_cast<Index>((Vector(&x[3*i]) - grid.Extent().Begin()) / grid.Extent().MeshWidth());
     89    index = grid.Global().GlobalBegin() + static_cast<Index>(((Vector(&x[3*i]) - grid.Extent().Begin()) / grid.Extent().MeshWidth()).Floor());
    9090    for (int j=0; j<size; ++j)
    9191      if (index.IsInBounds(begin_remote[j], end_remote[j])) {
Note: See TracChangeset for help on using the changeset viewer.