JML

java.math
Class MutableBigInteger

java.lang.Object
  extended byjava.math.MutableBigInteger

class MutableBigInteger
extends Object


Field Summary
(package private)  int intLen
           
private static long LONG_MASK
           
(package private)  int offset
           
(package private)  int[] value
           
 
Constructor Summary
(package private) MutableBigInteger()
           
(package private) MutableBigInteger(int)
           
(package private) MutableBigInteger(int[])
           
(package private) MutableBigInteger(int[], int)
           
(package private) MutableBigInteger(BigInteger)
           
(package private) MutableBigInteger(MutableBigInteger)
           
 
Method Summary
(package private)  void add(MutableBigInteger)
           
(package private) static int binaryGcd(int, int)
           
private  MutableBigInteger binaryGCD(MutableBigInteger)
           
(package private)  void clear()
           
(package private)  int compare(MutableBigInteger)
           
(package private)  void copyValue(int[])
           
(package private)  void copyValue(MutableBigInteger)
           
private  int difference(MutableBigInteger)
           
private  int divadd(int[], int[], int)
           
(package private)  void divide(MutableBigInteger, MutableBigInteger, MutableBigInteger)
           
(package private)  void divideOneWord(int, MutableBigInteger)
           
private  void divWord(int[], long, int)
           
private  void ensureCapacity(int)
           
(package private)  MutableBigInteger euclidModInverse(int)
           
(package private) static MutableBigInteger fixup(MutableBigInteger, MutableBigInteger, int)
           
private  int getInt(int)
           
private  long getLong(int)
           
private  int getLowestSetBit()
           
(package private)  MutableBigInteger hybridGCD(MutableBigInteger)
           
(package private) static int inverseMod32(int)
           
(package private)  boolean isEven()
           
(package private)  boolean isNormal()
           
(package private)  boolean isOdd()
           
(package private)  boolean isOne()
           
(package private)  boolean isZero()
           
(package private)  void leftShift(int)
           
private  MutableBigInteger modInverse(MutableBigInteger)
           
(package private) static MutableBigInteger modInverseBP2(MutableBigInteger, int)
           
(package private)  MutableBigInteger modInverseMP2(int)
           
(package private)  void mul(int, MutableBigInteger)
           
private  int mulsub(int[], int[], int, int, int)
           
(package private)  void multiply(MutableBigInteger, MutableBigInteger)
           
(package private)  MutableBigInteger mutableModInverse(MutableBigInteger)
           
(package private)  void normalize()
           
private  void primitiveLeftShift(int)
           
private  void primitiveRightShift(int)
           
(package private)  void reset()
           
(package private)  void rightShift(int)
           
(package private)  void setInt(int, int)
           
(package private)  void setValue(int[], int)
           
(package private)  int subtract(MutableBigInteger)
           
(package private)  int[] toIntArray()
           
 String toString()
           
private  boolean unsignedLongCompare(long, long)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

LONG_MASK

private static final long LONG_MASK

intLen

int intLen

value

int[] value

offset

int offset
Constructor Detail

MutableBigInteger

MutableBigInteger()

MutableBigInteger

MutableBigInteger(int)

MutableBigInteger

MutableBigInteger(int[],
                  int)

MutableBigInteger

MutableBigInteger(int[])

MutableBigInteger

MutableBigInteger(BigInteger)

MutableBigInteger

MutableBigInteger(MutableBigInteger)
Method Detail

clear

void clear()

reset

void reset()

compare

final int compare(MutableBigInteger)

getLowestSetBit

private final int getLowestSetBit()

getInt

private final int getInt(int)

getLong

private final long getLong(int)

normalize

final void normalize()

ensureCapacity

private final void ensureCapacity(int)

toIntArray

int[] toIntArray()

setInt

void setInt(int,
            int)

setValue

void setValue(int[],
              int)

copyValue

void copyValue(MutableBigInteger)

copyValue

void copyValue(int[])

isOne

boolean isOne()

isZero

boolean isZero()

isEven

boolean isEven()

isOdd

boolean isOdd()

isNormal

boolean isNormal()

toString

public String toString()
Overrides:
toString in class Object

rightShift

void rightShift(int)

leftShift

void leftShift(int)

divadd

private int divadd(int[],
                   int[],
                   int)

mulsub

private int mulsub(int[],
                   int[],
                   int,
                   int,
                   int)

primitiveRightShift

private final void primitiveRightShift(int)

primitiveLeftShift

private final void primitiveLeftShift(int)

add

void add(MutableBigInteger)

subtract

int subtract(MutableBigInteger)

difference

private int difference(MutableBigInteger)

multiply

void multiply(MutableBigInteger,
              MutableBigInteger)

mul

void mul(int,
         MutableBigInteger)

divideOneWord

void divideOneWord(int,
                   MutableBigInteger)

divide

void divide(MutableBigInteger,
            MutableBigInteger,
            MutableBigInteger)

unsignedLongCompare

private boolean unsignedLongCompare(long,
                                    long)

divWord

private void divWord(int[],
                     long,
                     int)

hybridGCD

MutableBigInteger hybridGCD(MutableBigInteger)

binaryGCD

private MutableBigInteger binaryGCD(MutableBigInteger)

binaryGcd

static int binaryGcd(int,
                     int)

mutableModInverse

MutableBigInteger mutableModInverse(MutableBigInteger)

modInverseMP2

MutableBigInteger modInverseMP2(int)

inverseMod32

static int inverseMod32(int)

modInverseBP2

static MutableBigInteger modInverseBP2(MutableBigInteger,
                                       int)

modInverse

private MutableBigInteger modInverse(MutableBigInteger)

fixup

static MutableBigInteger fixup(MutableBigInteger,
                               MutableBigInteger,
                               int)

euclidModInverse

MutableBigInteger euclidModInverse(int)

JML

JML is Copyright (C) 1998-2002 by Iowa State University and is distributed under the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. This release depends on code from the MultiJava project and is based in part on the Kopi project Copyright (C) 1990-99 DMS Decision Management Systems Ges.m.b.H.