Majority of people don’t even recognize that they have sexual thoughts during their worldly activities! It is good that you realize, ‘I have sexual thoughts while studying.’ With this awareness, you will definitely come out of this problem.

The solution to your problem is descriptively mentioned in the book (available free online): “Brahmcharya: Celibacy Attained with Understanding” expounded by Param Pujya Dada Bhagwan [https://www.dadabhagwan.org].
It is a wonderful book, explaining many solutions that can help you win over your sexual thoughts! I will briefly explain it in my own words, but do make it a point to study this book well.

Solutions to Minimize or Stop Sexual Thoughts
Make a firm ‘Determination’
Make a firm determination that I don’t want to indulge into any sexual matters. I don’t want to get attracted to anyone nor do I want to harness any sexual desires, imaginations or sexual dreams or do flirting, sexual gestures towards any person. I want to focus on my studies. Every day tell God about this determination of yours.

Ask God for ‘Strength’
Ask God every day, ‘please give me the strength to remain as a Celibate’. Celibacy means having no sexual relationships, thoughts, attractions, desires, gestures, flirting, imaginations or sexual dreams with any person.
‘Pluck out’ sexual thoughts as soon as they crop
If a sexual thought arises, immediately pluck it out. Immediate means within next second! If you don’t pluck it, it will continue for hours! Try any trick that helps you pluck it.

For example: See your Guru’s photo or of any person who is practicing celibacy such as Param Pujya Dada Bhagwan. That will immediately diffuse your thought. If it helps, keep the photo in your pocket or close to you.
Second example: Take your mind away from sexual thoughts to some other activity such as, cut a fruit, wash a bathroom, clean your desk, or any other activity, which takes your mind away! The activity must be such that you get totally involved in it.

Practice 3D Vision
When you see the person in your thoughts, see the person in three steps:
1.See the person without clothes
2.See the person without skin
3.See the intestines, fecal matter, blood, flesh, and bones in the person.

Our body contains stinking matter! That is why we have to urinate and excrete fecal matter every day! Further, just imagine, when the persons’ accident happens, his/her blood and pus falls all over the floor! You won’t even feel like touching them! I would suggest that you see some horrible pictures with bloody intestines, hands, legs, or any other body part.These pictures will stop your thoughts or attraction.Following these three steps one-after-the-other is referred to as three-dimensional (3D) vision.

Analyze and Solve
When you are relaxed, analyze your thoughts. Ask these questions to yourself:
•Why are you getting these sexual thoughts?
•Are you attracted to someone? What are the qualities of attraction?
•What is the benefit of a relationship?
•If you get married, then what will be the consequence?
•What if the person that you are attracted to, becomes retarded?
•What if you lose your job, will the person love you anymore?

From the answers, you can solve the problem. If you feel, that I am attracted to tall rich girl and she will keep me happy forever, then analyze this thought. “What if she gets retarded after an accident?” Her blood and pus will be all over the car. Her intestines will be hanging on the car’s windowsill. Will you touch her open intestines? Her skull would be open with blood gushing out! “Will she give you happiness after retardation?” Answer will be, No. Therefore, don’t keep any expectations from any person.

Touching the persons’ skin is not a happy moment. If there were pleasure in it, then you would have touched the intestines and her open skull! This way, provide evidences that there is no pleasure or happiness in sexual thoughts or in sex. You have to solve this problem from its roots with such evidences.

Apologize
Everyday apologize in your mind towards the person who is in your sexual thought. Say sorry (in your mind), and make a strong determination not to see that person in this manner.Secondly, apologize for having the sexual thought towards the person. Say sorry (in your mind) and make a strong determination that you don’t want to fall in such sexual activities. When you apologize every day, your sexual thoughts will soon disappear!

Please visit: https://www.dadabhagwan.org/path-to-happiness/spiritual-science/practice...

Author's Bio: 

Ambalal M. Patel was a civil contractor by profession. In June 1958, spontaneous Self-Realization occurred within Ambalal M. Patel. From this point on, Ambalal became a Gnani Purush, and the Lord that manifest within him became known as Dada Bhagwan. A Gnani Purush is One who has realized the Self and is able help others do the same. Param Pujya Dada Bhagwan used to go from town to town and country-to-country to give satsang (spiritual discourse) and impart the knowledge of the Self, as well as knowledge of harmonious worldly interactions to everyone who came to meet him. This spiritual science, known as Akram Vignan, is the step-less path to Self-realization.