Performance improvements and bugfixes

Removed the BitMath class previously used for string parsing and
replaced it with BigInt itself.
Also rewrote the add_at_pos function, which contained a bug
that would appear with certain value/shift combinations. Also shows
that maybe the testcases need improvement ;)