fangq / mcx

Monte Carlo eXtreme (MCX) - GPU-accelerated photon transport simulator
http://mcx.space
Other
127 stars 71 forks source link

MCXLAB : The problem of inconsistency between the calculated optical path length of the trajectory output by mcxlab and the partial length returned by detphoton.ppath #231

Open kurodexue opened 1 week ago

kurodexue commented 1 week ago

MCX is a very interesting job, but I encountered problems during its use.

I have a requirement to calculate the maximum depth of each photon. I used a trajectory to calculate it, but there is a problem. The output trajectory should be the scattering point position, incident position, and exit position of each photon, which is also the case in reality. However, its index order is different from the indices of photons in detphoton such as detphoton.v, detphoton.p, and detphoton.ppath. I used Trajectory to manually calculate the path length of photons in a single-layer medium and compared it with the value of detphoton.ppath. The values are the same, but the order of indices is messy. Is it possible for trajectory to output photons in the order of detphoton output?

Thank you!