implement the linear kernel with psi2 format