Check all of the math in the docs/operator_discretization_finite_differences.tex file. This has been separated from the older file, since I realized these notes will apply to all sorts of other examples.
A few things to check carefully:
I added in the boundary values for both the reflection and the absorbing barrier. Go through the algebra very carefully to make sure I didn't make a mistake in them.
You will also see that I think the formulas for (7) to (11) simplify in the boundary conditions (especially in the reflection case).
Do a sanity check that the upwind procedure (i.e. the sign of of $\mu_1$ doesn't effect the reflection boundary values in (17) and (20). My suspicion is that it does not since this seems to make the math add up for each row adding to 1 - as it should as a proper markov chain.
I think I modified your case of the $\mu < 0$ specialization correctly in (21) to (28), but I would check it out to be sure.
Check all of the math in the
docs/operator_discretization_finite_differences.tex
file. This has been separated from the older file, since I realized these notes will apply to all sorts of other examples.A few things to check carefully: