Lines Matching refs:numBits
329 int numBits = (int)(((numDigits * bitsPerDigit[radix]) >>> 10) + 1);
330 int numWords = (numBits + 31) >>> 5;
391 int numBits = (int)(((numDigits * bitsPerDigit[10]) >>> 10) + 1);
392 numWords = (numBits + 31) >>> 5;
481 * the range 0 to (2<sup>{@code numBits}</sup> - 1), inclusive.
486 * @param numBits maximum bitLength of the new BigInteger.
489 * @throws IllegalArgumentException {@code numBits} is negative.
492 public BigInteger(int numBits, Random rnd) {
493 this(1, randomBits(numBits, rnd));
496 private static byte[] randomBits(int numBits, Random rnd) {
497 if (numBits < 0)
498 throw new IllegalArgumentException("numBits must be non-negative");
499 int numBytes = (int)(((long)numBits+7)/8); // avoid overflow
505 int excessBits = 8*numBytes - numBits;