Nearly implemented evaluation function