What was the purpose of the Tree of the knowledge of good and evil

I think that’s essentially the same point that @Alan_Smithee was making here:

That whole thread has some good stuff, but the specific post I linked to is particularly good and particularly relevant to this question.