Adjust the hyper prior code

Fix the maths. Also add a loop as it’s a newton-raphson scheme, a
single iteration won’t work on its own. However it’s still buggy
Support LDA/VB in main