Onan knew that the aoffspring would not be his; so when he went in to his brother's wife, he wasted his seed on the ground in order not to give offspring to his brother.