errors fixed at nelder_mead and powell method specs.