There is no "profitable betting algorithm" for playing a -ev game with a limited bankroll and a max win ceiling. There are methods that will allow you to (probably) go for long periods of time before you lose your bankroll, but you are making several -ev bets in a row. You can't magically make -ev bets +ev.