fixed the minus log likelihood function