Bugfix initialization of pij.

Also update namespace.