Simulation with the same configuration properties in different situations

50 views
Skip to first unread message

Mor Wainberg

unread,
Jul 18, 2022, 2:54:24 AM7/18/22
to mcx-users
Hello Dr. Fang,

I want to simulate with the same configuration (medium structure, number of photons, number of detectors, etc.) but in different situations.
The appropriate parameter is cfg.seeds? 
And if so what values make sense and should this variable be given?
Also, if I want to run the simulation multiple times then what range can cfg.seeds exist in?

I would greatly appreciate your answer, thank you very much
Mor Wainberg.

Qianqian Fang

unread,
Jul 20, 2022, 10:55:43 AM7/20/22
to mcx-...@googlegroups.com, Mor Wainberg

On 7/18/22 02:54, Mor Wainberg wrote:
Hello Dr. Fang,

I want to simulate with the same configuration (medium structure, number of photons, number of detectors, etc.) but in different situations.
The appropriate parameter is cfg.seeds?


it depends on how you define "different situations" - if that involves changing optical properties, source settings and other optics-dependent settings, then you will need to use other fields. but if you just want to test or reduce stochastic noise and randomness/convergence of the solutions, yes, setting cfg.seed (not .seeds) to a different value is what you are looking for.


And if so what values make sense and should this variable be given?




Also, if I want to run the simulation multiple times then what range can cfg.seeds exist in?


it is a 32-bit integer (if set to 0 or a negative value, mcx will use system clock as the seed), you are recommended to set it to a big positive number (so that every bit is randomized).

explicitly setting to a big positive integer has the benefit of creating somewhat reproducible results, but setting to 0 or negative value can not do the same.


Qianqian



I would greatly appreciate your answer, thank you very much
Mor Wainberg.
--
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 on the web visit https://groups.google.com/d/msgid/mcx-users/d4b608c3-09cc-4548-9294-1ad0d9c4fad7n%40googlegroups.com.


Mor Wainberg

unread,
Jul 23, 2022, 11:24:30 AM7/23/22
to mcx-users
thank you very much!

ב-יום רביעי, 20 ביולי 2022 בשעה 17:55:43 UTC+3, q.fang כתב/ה:
Reply all
Reply to author
Forward
0 new messages