Connect expenses to members
- What
- Groups can record shared expenses.
- Why
- A useful balance needs to account for who paid and who shares the cost.
- How
- The application uses member and expense information to calculate balances.
Group expense management and settlement application with greedy debt resolution.
Group travelers struggle with complex multi-payer expenses, uneven currency splits, and awkward manual debt reconciliation.
Full-Stack Software Engineer (Sole Developer)
Minimizes total required cash transactions across participants using a greedy debt-simplification algorithm.
Tripmate helps groups record shared expenses, calculate who owes whom and simplify the final settlement between members using a greedy graph resolution algorithm.
Implemented a greedy balance resolution graph algorithm in TypeScript, multi-party expense splitting logic, UPI deep links, and PDF summary exports.

The application stores groups, members and shared expense information. Expense and member relationships support the balance and settlement calculations.
trip_idcreator_idexpense_idamountpayer_idsplit_typesettledcategoryThe interface connects group and expense actions to stored application data. Settlement amounts are used to create UPI payment links; PDF generation makes the expense information exportable.
End-to-end system lifecycle
Settlement engine · Minimized-debt greedy balance resolution. Excerpt from the repository source.
// Minimized-debt greedy balance resolution algorithm
export function simplifyDebts(balances: Map<string, number>): Settlement[] {
const debtors = [...balances.entries()].filter(([_, b]) => b < -0.01).sort((a,b) => a[1] - b[1]);
const creditors = [...balances.entries()].filter(([_, b]) => b > 0.01).sort((a,b) => b[1] - a[1]);
const settlements: Settlement[] = [];
// Greedy balance resolution cancels circular obligations
return settleGreedy(debtors, creditors, settlements);
}The group expense interface brings expense entry, member balances and settlement actions together.
Next.js · React · TypeScript · PostgreSQL/data-backed application · Expense calculations · Settlement logic · API integration · PDF generation