I ran this equation using your example and the 40 bit pvk was found whether I ran the bsgs algo in the 50bit, 40bit or 30bit range. The same public key was found as long as I did not search in a range above 50bit. I don’t understand why it’s finding the same public and private key pair on line 120 in the output file. How is it finding a 40 bit private key in a 50 bit or 30 bit range? Do you know why?
I'm not sure why this would happen as I don't really know much about how these algorithms work.
Maybe the algorithm's precomputed table covers the entire area of these smaller ranges without the need for further calculations?
You can reach out to the person who created the BSGS implementation you are using
I'm sure they will be able to better answer you.