Products & Services Solutions Academia Support User Community Company

Learn more about SimEvents   

se_setseeds - Set seed values for blocks with random number generators

Syntax

se_setseeds(seedstruct)
se_setseeds(seedstruct, sysid)
oldseedstruct = se_setseeds(seedstruct...)
[oldseedstruct, status] = se_setseeds(seedstruct...)

Description

se_setseeds(seedstruct) sets the seed parameter values for all SimEvents blocks specified in seedstruct.

se_setseeds(seedstruct, sysid) applies the seed values to the system sysid, overriding the system specified in the system field of seedstruct.

oldseedstruct = se_setseeds(seedstruct...) stores the original seed values in oldseedstruct before setting them to the values specified in seedstruct.

[oldseedstruct, status] = se_setseeds(seedstruct...) returns status information indicating when the function does not set a seed.

Inputs

seedstruct

Structure having the same fields as the output of the se_getseeds function:

  • system — Value of the sysid input to se_getseeds

  • seeds — Structure array, of which each element has these fields:

    • block — Path name of a block that uses a random number generator, relative to system

    • value — Numeric seed value of the block

sysid

System name or subsystem path name.

Outputs

oldseedstruct

Structure representing original seed values. The form of oldseedstruct is the same as that of seedstruct.

status

Logical array whose nth entry is false if the nth block in seedstruct meets one of these conditions:

  • Does not exist

  • Is not a SimEvents block

  • Does not have a seed parameter in its current configuration

See Also

se_getseeds | se_randomizeseeds

Tutorials

How To

  


Related Products & Applications

Learn more about Simulink through this collection of videos, articles, technical literature and the Getting Started with Simulink Guide.

 © 1984-2009- The MathWorks, Inc.    -   Site Help   -   Patents   -   Trademarks   -   Privacy Policy   -   Preventing Piracy   -   RSS