Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dryden model random seed repeat and not random #22

Open
mlouielu opened this issue Jan 29, 2021 · 0 comments
Open

Dryden model random seed repeat and not random #22

mlouielu opened this issue Jan 29, 2021 · 0 comments

Comments

@mlouielu
Copy link
Contributor

In cad::Wind::apply_turbuance_if_have(), insert this line after guass_value calculated:

        std::cout << seed2 << " " << gauss_value << std::endl;

Generate like this:

62842502 -2.58333
62842502 -2.58333
62842502 -2.58333
62842502 -2.58333
62842502 -2.58333
62842502 -2.58333
62842502 -2.58333
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
[01/29,16:12:28.949] Server sim_time = 75.000000
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649
2218566459 4.72649

Shows that seed always get the same.


Fix: seed should only init once.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant