How to have multiple seeds for random generation in Simulink?

I have a model in Simulink that uses the `Random Number` block. This `Random Number` block uses a `Seed` value for the generation of random values. Now if I have multiple copies of my model:
main.slx
|
|-----> child_1.slx (Random Number block inside)
|
|
|-----> child_2.slx (Random Number block inside)
|
|
|-----> child_3.slx (Random Number block inside)
How can I set the `Seed` of `Random Number` to be different in each copy?

 Akzeptierte Antwort

TAB
TAB am 24 Aug. 2018

0 Stimmen

  1. In Child model --> Create Model parameter for seed.
  2. In "Model Block" in Parent model --> Pass the seed value in "Model Argument" field

Weitere Antworten (0)

Kategorien

Mehr zu Random Number Generation finden Sie in Hilfe-Center und File Exchange

Produkte

Version

R2018a

Gefragt:

am 24 Aug. 2018

Beantwortet:

TAB
am 24 Aug. 2018

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by