Question about O notation

In Ian Chivers book on page 84 I read:
Word size and integer numbers:

Number of bits      Power of 2             Power of 10
32                          (2**31)-1               O(10**9)

I have an idea what is meant with big O notation but I don’t understand what it means in this context.
I did some googling, but didn’t find any understandable explanations.
I suppose that for you computer gurus this is a ridiculous question but I’m just a humble structural engineer.

Roger

In the context I take it as “of the order of”

2^{31}-1 = 2 .147483647*10^9

1 Like

In mathematics, there are well-defined meanings for large O() and small o() notations that you can find described online or in textbooks, but when used in this way, it just means “order of magnitude.” O(10**9) means that the actual number is probably larger than 10**8 and smaller than 10**10. It is not a specific approximation, and it is not a rigorous bound.

2 Likes

Ok. Thanks!

Verzonden vanaf Outlook voor Android

Yes, as @PierU and @RonShepard said, in physics O(10^9) is equal to O(1). But in this context O(n) means something like 10^(log10(n)) = n <= O(n) <= 10^(log10(n) + 1) = 10*n. Possibly it could also mean n/10 <= O(n) <= 10*n or some other such combination. Intuitively, to the order of 1000, I would say that is between 500 and 5000. So that would suggest 0.5*n <= O(n) <= 5*n as the most accurate definition.