Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

Agreed that it is wrong. After very odd results with something more complicated, I tried convolving two rectangular distributions of unequal width as a test. It is easy enough to show that the result should be a trapezoidal distribution. The result of the convolution in Sage was kind-of the right shape, but the top of the trapezium was detached, and too high by a factor of (exactly) 4.

I'm not a hacker, but would be happy to provide some test cases to somebody who wants to have a go at fixing the code.