Over to You

You built three simulations in this chapter, used two different statistical distributions, drew pictures in C++, and briefly looked at property-based testing. The models you simulated used stochastic differential equations—equations with a random element. They were a special type of random walk known as Markov processes; the next step depends on the current state only. You built a discrete simulation of these by finding values at specific time intervals.

Think about some other property-based tests for your code. Look at unit tests in a project you are working on—can you see any magic numbers? Try property-based testing on that code and see what happens.

Try out some different models. Your stock prices tend to go up over time. ...

Get Genetic Algorithms and Machine Learning for Programmers now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.