adding function to test k-values