more efficient computations in stationary
removing testing code from kern.py (it's now in kern_tests.py