Is having a nocturnal emission (wet dream) a sin?
Having a nocturnal emission or a wet dream where you ejaculate semen is not a sin; just as a girl experiencing her menstrual period is not sinning.
In the Old Testament, God selected a number of things which many people naturally viewed as disgusting, dirty, or uncomfortable to talk about and called them "unclean." Unclean things were to help the people of Israel to understand the nature of sin and the spread of sin, even though the things called unclean were not in themselves sinful. For example, because of a pig's natural dirty lifestyle and its willingness to eat just about anything, it was called unclean. A dead body was unclean and touching it made the person unclean. God also selected two natural body functions for uncleanness: menstruation for women and ejaculations for men. For example, "If there is among you any man who is unclean because of a nocturnal emission, then he must go outside the camp; he may not reenter the camp. But it shall be when evening approaches, he shall bathe himself with water, and at sundown he may reenter the camp" (Deuteronomy 23:10-11). This meant that everyone would experience being unclean frequently -- just as sin is widespread and hard to avoid.
But keep in mind, that while uncleanness illustrated sin, the things causing uncleanness were not necessarily sinful. For example, in commenting about abstaining from certain foods, Paul said, "For every creature of God is good, and nothing is to be refused if it is received with thanksgiving; for it is sanctified by the word of God and prayer" (I Timothy 4:4-5). Hence, Paul is saying there is nothing wrong with pork, in and of itself. It was a sin for a Jew to break the laws of uncleanness, but it doesn't follow that the items selected for the uncleanness laws were in themselves sinful.
What usually bothers most Christian men though is the nature of the dreams that often accompany nocturnal emissions. Frequently they are of a sexual theme; though, not always. This makes sense since the body, during the dream, is involved in gearing up for an ejaculation. You would expect that the mind and the body to be following the same general theme of sex. It is disturbing, though, to dream about things which are not proper for a Christian to do. I've known young men to be guilt ridden over the possibility that they might be a fornicator or a homosexual deep inside. We must acknowledge that while we are asleep, we do not have control over the contents of our dreams. Pray to God for protection from evil thoughts during the night, but realize that Satan tries us at all times. If you understand that homosexuality and fornication are wrong while you are awake, then don't be concerned about the thoughts that come during your sleep.