In response to your first quote: Most people would define, "knowing in your heart," as the conviction of the Holy Spirit. Masturbation can be good and can also me used to commit a sin; but the act in itself is not wrong. Lust and adultery, if married, are the things that are wrong. And if those things occur during a person's masturbatory session, he must stop those thoughts. Don't you understand that a person can lust and commit adultery without masturbation?
In response to your second quote: I must apologize for my vague question. I was not looking for the verse on adultery. I was asking for the verse that you explained at the top of your post: "The bible says if you go into your wife, you are one with your wife."
This was the closest verse I could think of: (1 Corinthians 6:15-17) 15Do you not know that your bodies are members of Christ himself? Shall I then take the members of Christ and unite them with a prostitute? Never! 16Do you not know that he who unites himself with a prostitute is one with her in body? For it is said, "The two will become one flesh."[2] 17But he who unites himself with the Lord is one with him in spirit.
"Uniting" yourself with a prostitute is immoral. But what exactly is the meaning of unite? If one can unite with God and a Prostitute then what could it mean? I believe that the word "unite," in this passage, means an intimate relationship, which, of course, could be sexual or not.
With that established, having an "intimate relationship" with a prostitute is immoral, because the intimate relationship, in this case, involves "unloving" and "selfish" sex. An intimate relationship (sex, in most cases) does mean, "to become one flesh." However, the absence of a marriage is not even mentioned in this verse.