Dear Varun,
Good idea. Regarding the Chakrapata Harana, I think what is given in the classics is merely an approximation. If you are coding using C++, then you can build the logic in this manner. You can take chalit chart and find out how far a Graha is displaced from the Lagna sphuta in reverse (12 to 7). For Krura, you can assign reduction of 1 when the Graha is just behind the lagna sphuta and 0 when it is 180 from the Lagna Sphuta. Shubha grahas are 1/2 of the Kruragrahas. Based on the figures given by Maharishi Parashara, I plot a graph considering the following:
- 12th house starts from Sphuta of the lagna and extends 30degree backward. Meaning Lagna Sphuta is the beginning of the 1st house and not the middle.
- The reduction is highest when the Sphuta is close to the Lagna Sphuta and zero 180 degrees from the Lagna Sphuta.
The Harana for the intermediate points are based on linear interpolation. I think it should be based on an exponential curve as the overall structure of teh curve represents. The specified values for the different houses by the Maharishi could be approximations and not the precise values. You can explore both possibilities, but I suggest you use the Bhava instead of Rasi, as the Harana is applied based on visible and invisible half of the zodiac.
Let me know what you find, and I will be happy to discuss more.
Cheers!