Thanks for query,
Your pain related to infection i.e. Vaginits you got due to infection.
This is a vaginal infection
& due to inflammation of vaginal wall you get infection.
As the discharge is yellowish green there might be chances of bacterial infection too.
you should require medicines to control it.
Consult your doctor .