https://github.com/SillyDev2026/Bnum4/blob/main/Bnum4.lua
Its binary math basically faster allocations, low gc and is good for fast ops as in operations per second
#What other implementation should I add
1 messages · Page 1 of 1 (latest)
** You are now Level 14! **
So many things can be implemented but the problem is that it’s going to be hard lol
Tested it out against my Bnum and other versions that others have made and the system I have it’s faster since it’s going on binary instead of repeated calcs and calls
Did some testing without using calls like
function Bnum.log(n1, n2) return Bnum.div(Bnum.log10(n1), Bnum.log10(n2)) it’s slower but did its own so it doesn’t rely on other functions that’s why it’s so many lines
And then tested with all the same but the downside it’s slower when u do a
convert, function calls that do its math and then at the end normalize then return .new() went from 2s down to 0.16s to 0.28s
As a start;
Comment ur code more
Follow principles such as trying to avoid if statement nesting
Use better variable names
Don’t need todo avoid ifs that’s how ur supposed todo it
And also don’t need todo better var names because one to much to write
And also trying to make it sleek not unreadable as in like
local man1, exp2= value1Man, value1Exp from buffer read and number
did you just request and then dismiss the tips you got
I said implement not what to fix
Can’t u read
It says nothing about fixing it’s just asking what can I implement next
so you're denying any help
based on this reaction, why would anyone attempt to help?
shorthand should not become obfuscation
I doubt this is faster than normal lua math ops
You have so many if checks
An if check is already slower than a f64 and f64 math op in luau
Have you tried benching it?
@royal jewel ur smart
really? how slow?
Not sure about how much actually
But calling this faster makes no sense
Cuz this is a big num module
It's obv gonna be slow than normal nums
Also whats the size limit this thing can reach before losing all precision
Oh so it is for Bnum
Do they not know binary is faster then an table
Make a bench system and run it 1,000,000 times as in
for i = 1000000 do
Then run the function
And table math is slower then binary
put it on wally