Simple Trigonometry. You have already defined all of the things you need. If you wanted to get really accurate, then use the Pitch Diameter of the thread, but it will not make much of a difference.
Dave
Generally, I will not give you the answer to your question, but I **will** guide you into discovering how to solve this yourself.