What is the difference between Tahajjud prayer and night prayer, and do they have a particular Witr prayer other than that of Isha (evening prayer)?
Tahajjud and Qiyam-Al-Lail (night prayer) are two words for the same meaning which is offering voluntary prayer at night after sunset, but before dawn break. However, Tahajjud is offered after waking up; whereas, Qiyam-Al-Lail is permissible before sleeping, or after it. Therefore, every Tahajjud is a Qiyam, but not every Qiyam is a Tahajjud. Moreover, there is no specified Witr for both of them, but Witr after Isha is by itself the Witr of Qiyam, and it is a Sunnah to postpone it until after Qiyam if the worshiper thought that he was most probably going to wake up in order to offer it, but if he wasn`t sure of waking up, then he is at liberty to offer it before going to bed as was reported in the Prophet`s Hadith.
What is the ruling on determining the sex of the baby whether through killing the female spermatozoa, or any other way in order to have a male?
If it is done through having a certain type of food, taking a certain type of medication, or organizing the time of the marital relation, then it is permissible.
I am an author, and I have books stored with me. Is it permissible to pay my zakat in the form of books containing beneficial knowledge for poor students, such as chemistry and mathematics, or religious books that spread Islamic sciences?
Zakat on wealth must be paid in cash from the wealth itself. Therefore, you should pay your zakat in monetary form so that the poor can purchase what they need. And Allah Knows Best.
Is prayer nullified by having thoughts while performing it?
Prayer isn`t nullified by having thoughts while performing it, provided that the praying person offers all of its pillars and meets all of its conditions. However, the reward decreases significantly in the absence of reverence since a praying person is rewarded according to the attentiveness of his/her heart during prayer.