Taking some baby steps making my first module. The goal is to implement a Brownian Bridge, that simulates the stochastic ODE
dy = (y_f - y)/(t_f - t)dt + r dB
starting from an initial value of y, where y_f is a final value and t_f is the final time. dB is a Brownian noise process increment.
The code for my first stab at this is at:
It more or less does what I want but I am sure I am making lots of mistakes and there is a lot of room for improvement. Any constructive comments are welcome.