You use CIDR notation to get the # of IP addresses that are available in that block. It does not, however, specify where the range has to begin or end – the only requirement is that they be sequential.

Say, for example, that you wanted to assign 8 IP addresses for friends when coming to visit for a LAN party. You also want them to start at the IP address. That means they'd get .16 through .23 as their own. Here's what the CIDR would look like:

The mathematical formula for determining the size of the range of IP addresses is:

2 ^ (32 - /$x)

where $x represents the /29 above.

Using that case, 32-29 is 3, so 2 to the power of 3 (or, 2x2x2) is 8.

See this table on Wikipedia for a better example.

You can move the starting around point all you want, but they are still going to be assigned the same number of IP addresses.

So, if you wanted them to have 75 through 82, here's the notation: is the starting point, with the range extending to 2^(32-29), or, 2^3, or, 2x2x2, or 8.

So here's the IP addresses they'd have:

Now, let's look at expanding past the 192.168.1 subnet into 192.168.2 as well. Since you have 256 IP addresses available on the first one ( through, then the next range would start at If you wanted to add those 256 as well, through, then you would use notation /23, for 512.

So if you wrote, it would mean these IP addresses:

Now, remember that everything is increased by the power of 2, so your options are always going to be doubled:

2^0 = 1
2^2 = 2
2^3 = 8
2^4 = 16
2^5 = 32
2^6 = 64
2^7 = 128
2^8 = 256
2^9 = 512
2^10 = 1024
2^11 = 2048
2^12 = 4096
2^13 = 8192
2^14 = 16384
2^15 = 32768
2^16 = 65536

With that in mind, you can easily know that whatever # of IP addresses available you have in your range, the next amount number available is going to be double what you currently have.

That is, if you have, which gives you 8, then if you go down one # – from to – 20 being the next possible range size, then your number 8 is going to double to 16.

The opposite is also true, going from to is going to give you less addresess – 4.

The reason this can get confusing, trying to keep track of which numbers are higher or lower, remember that the higher the number on the CIDR, the lower the amount of possible IPs. Instinct may tell you that /32 is higher than /24 and so a /32 notation means more. The opposite is true. It's like a see-saw! Only one can be high. - the notation is high, so the IPs is low - the notation is low, so the IPs is high

The power of 2 is also evident when crossing the first 256 # of IP addresses. If starting at, and extending to 512, then you're only adding one set of 256s. So 1.0 would expand to 2.0. But what if you wanted to add more? The power of 2 applies, so you'd then have to jump by 4, next. now goes to The next one would be 4 times 2, so 8 is the next possible block. Going from to And so on, and so on:,,,, etc.