Minimum payment and payment due calculations, lines due and other helper functions