Brihat Parashara Hora Shastra
त्रिभिर्भक्तं च शेषांकैः सा पुनस्त्रिबिधा स्मृता । दष्टिश्चेष्टा विचेष्टा च तत्फलं तथयाम्यहम् ॥ ३७॥
The product so arrived at should be divided by 3. In the process of calculation, if it happens, that the remainder is 1, it is Drishti, if 2, it is Chesht and, if 0, it is Vichesht.
english translation
tribhirbhaktaM ca zeSAMkaiH sA punastribidhA smRtA । daSTizceSTA viceSTA ca tatphalaM tathayAmyaham ॥ 37॥
hk transliteration by Sanscript