vidyut
vidyut copied to clipboard
अक्ष्णोति should use रषाभ्यां नो णः समानपदे
The derivation of अक्ष्णोति (अक्ष् 1.0742, लट् प्र.पु.ए.व ) uses अट्कुप्... to convert न् to ण्. Technically it should use रषाभ्यां as न् is immediately after ष्
Looks like same issue for a few other places, E.g. पुष्णाति.
@vipranarayan14 this should also be a good first issue if you want to try fixing it. You can navigate the codebase by grepping for specific rules, e.g. "8.4.1"
@vipranarayan14 has identified that the issue is in pada_8_4.rs, specifically this block:
https://github.com/ambuda-org/vidyut/blob/c886f287b622779ba15335aecc8002dddbf3ef73/vidyut-prakriya/src/tripadi/pada_8_4.rs#L194
My notes are that it's specifically this line within the block:
https://github.com/ambuda-org/vidyut/blob/c886f287b622779ba15335aecc8002dddbf3ef73/vidyut-prakriya/src/tripadi/pada_8_4.rs#L203
Here we apply only 8.4.2. Instead, we should use logic like this:
if the r/s and n are right next to each other {
p.run("8.4.1", |p| p.set_char_at(i_n, "R"));
} else {
p.run("8.4.2", |p| p.set_char_at(i_n, "R"));
}
We can evaluate the first condition by comparing i_rs (the index of r/s in the string) and i_n (the index of n in the string).
We can then confirm that this fix is correct by adding a test case to tests/prakriyas.rs to confirm that the prakriya for e.g. अक्ष्णोति uses 8.4.1 and that the prakriya for some other word uses 8.4.2 instead.