Start a LyX writeup of the mathematics I have wrought from the firmament.
Conclusion of the Introduction, and tweaked TODOs in proofs.md
Generation and alternate Bartlett forms.
first pass at runtime counting
O(d^4) is soooo painful
Generating inverse wisharts and start of the more efficient inverse wishart algorithm.
tests of the Bartlett distributions
Mistake!!
okay, first draft of the alg in place;

next: make test plots
plotit
instrumenting inverse wisharts.

the naivesampler and the snappysampler don't seem to quiiite agree in some marginals. We'll have to look into this.

Current timings out of NIW.R:
on ~1e5 samples: (forgive the accidentally negatives)
Loading required package: MASS
   user  system elapsed
-12.704   0.000 -12.721
   user  system elapsed
 -5.270  -0.004  -5.279

on ~1e6 samples:
   user  system elapsed
 127.16    0.03  127.48
   user  system elapsed
 55.200   0.037  55.339

My prediction in mathematics.lyx that the improved algorithm is
only a piddly 2-fold speedup is panning out nicely...
There's still some optimizations to be made, though.
Wrote test() method which makes nice plots automatically.

To do this, rewrote much of the instrumentation in CPS
 (Continuation-Passing-Style) and exploited R's lispy roots.
tidy prints, and bump runtime to be more reasonable
Checking the runtime differences, so far.

Timings for this commit:
Starting test runs
------------------
Beginning rNIW.extremelynaive ...
Runtime for rNIW.extremelynaive :
   user  system elapsed
 12.463   0.013  12.498

Beginning rNIW.naive ...
Runtime for rNIW.naive :
   user  system elapsed
  8.473   0.013   8.499

Beginning rNIW.snappy1 ...
Runtime for rNIW.snappy1 :
   user  system elapsed
  5.220   0.004   5.235
snappy2, snappy3, and notes I might as well commit here and now.

Timings for this version:
Starting test runs
------------------
Beginning rNIW.extremelynaive ...
Runtime for rNIW.extremelynaive :
   user  system elapsed
 12.566   0.013  12.611

Beginning rNIW.naive ...
Runtime for rNIW.naive :
   user  system elapsed
  8.743   0.000   8.758

Beginning rNIW.snappy1 ...
Runtime for rNIW.snappy1 :
   user  system elapsed
  5.340   0.007   5.357

Beginning rNIW.snappy2 ...
Runtime for rNIW.snappy2 :
   user  system elapsed
  4.214   0.000   4.225

Beginning rNIW.snappy3 ...
Runtime for rNIW.snappy3 :
   user  system elapsed
  4.076   0.003   4.090

So, I've still only gotten 2 times faster for all this effort than the naive algorithm.
Also the diff between snappy2 and snappy3 shows there's a gain but only marginal gains in using R's vectorized ops.

I need to investigate triangular matrix multiplies. That will give me another factor-2 speedup.