MCX Transmittance and detector query

9 views
Skip to first unread message

Samin Enam

unread,
Oct 30, 2025, 10:11:46 AM (7 days ago) Oct 30
to mcx-users
Dear Dr. Fang,
I am looking to map the transmittance over thickness for my model. I wanted to know, what would be the most responsible way to get transmittance? Do I use detectors? Or do I use the fluence map? And if I do end up using fluence map, do I add a zero-labeled layer and use that layer to map my fluence? Please let me know if my question was clear enough or if you need further details. 
But to sum it up, how would you calculate transmittance from the source through a tissue/biological layer most effectively and accurately in MCX?

Qianqian Fang

unread,
Oct 30, 2025, 12:08:31 PM (7 days ago) Oct 30
to mcx-...@googlegroups.com, Samin Enam

hi Samin,

to calculate transmittance, you need to compute the total energy passing through the boundary opposing to the side where the source is placed.

for example, if you place a source at z=0 of a slab domain, you should pad a layer of zeros on the z=max_z and set cfg.issaveref=1 and cfg.outputtype='energy'. after the simulation, sum the flux.dref values in the z=max_z layer. it should be a value less than 1 (as it is normalized - so that total launched energy is 1), which you can use to estimate the transmittance.

if you want to be sure, you can also pad a layer of zeros at z=0 (in addition to the changes above) and sum flux.dref at z=0 layer. This should give you the total diffuse reflectance. Summing the transmitance and reflectance should give you something close to 1.

if it is significantly less than 1, that means a good portion of the photons exits from the other 4 sides (x=0/y=0/x=max_x/y=max_y), then can increase your x/y dimension to minimize these energy leakages.

you can also set the 4 side boundaries to have a mirror or cyclic boundary condition, so that photons only exit from z=0 or z=max_z. see this example

https://github.com/fangq/mcx/blob/master/mcxlab/examples/demo_infinite_slab_cyclic_bc.m

Qianqian

On 10/29/25 18:41, Samin Enam wrote:

You don't often get email from samin...@gmail.com. Learn why this is important

Dear Dr. Fang,
I am looking to map the transmittance over thickness for my model. I wanted to know, what would be the most responsible way to get transmittance? Do I use detectors? Or do I use the fluence map? And if I do end up using fluence map, do I add a zero-labeled layer and use that layer to map my fluence? Please let me know if my question was clear enough or if you need further details. 
But to sum it up, how would you calculate transmittance from the source through a tissue/biological layer most effectively and accurately in MCX?
--
You received this message because you are subscribed to the Google Groups "mcx-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to mcx-users+...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/mcx-users/de328a68-b8e9-4624-92f9-99ba4d1289b4n%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages