    All Packages  Class Hierarchy  This Package  Previous  Next  Index

# Class JSci.physics.quantum.Operator

    java.lang.Object
       |
       +----JSci.physics.quantum.Operator

public class Operator
extends Object
implements Member, Serializable

The Operator class provides an object for encapsulating quantum mechanical operators.

##

representation

##

Operator(ComplexSquareMatrix)
  Constructs an operator given a matrix representation.

##

add(Operator)
  Returns the addition of this operator and another.
dimension()
  Returns the dimension.
equals(Object)
  Compares two operators for equality.
getRepresentation()
  Returns the representation.
hashCode()
  Returns a hashcode for this operator.
isSelfAdjoint()
  Returns true if this operator is self-adjoint.
isUnitary()
  Returns true if this operator is unitary.
multiply(KetVector)
  Returns the multiplication of this operator and a ket vector.
multiply(Operator)
  Returns the multiplication of this operator and another.
subtract(Operator)
  Returns the subtraction of this operator and another.
toString()
  Returns a string representing this operator.
trace()
  Returns the trace.

##

representation

     protected ComplexSquareMatrix representation

##

Operator

     public Operator(ComplexSquareMatrix rep)

  Constructs an operator given a matrix representation.

  Parameters:
    rep - a matrix representation

##

equals

     public boolean equals(Object a)

  Compares two operators for equality.

  Parameters:
    a - an operator
  Overrides:
    equals in class Object

toString

     public String toString()

  Returns a string representing this operator.

  Overrides:
    toString in class Object

hashCode

     public int hashCode()

  Returns a hashcode for this operator.

  Overrides:
    hashCode in class Object

getRepresentation

     public ComplexSquareMatrix getRepresentation()

  Returns the representation.

isSelfAdjoint

     public boolean isSelfAdjoint()

  Returns true if this operator is self-adjoint.

isUnitary

     public boolean isUnitary()

  Returns true if this operator is unitary.

trace

     public Complex trace()

  Returns the trace.

dimension

     public int dimension()

  Returns the dimension.

add

     public Operator add(Operator op)

  Returns the addition of this operator and another.

  Parameters:
    op - an operator
  Throws: MatrixDimensionException
    If the operators have different dimensions.

subtract

     public Operator subtract(Operator op)

  Returns the subtraction of this operator and another.

  Parameters:
    op - an operator
  Throws: MatrixDimensionException
    If the operators have different dimensions.

multiply

     public Operator multiply(Operator op)

  Returns the multiplication of this operator and another.

  Parameters:
    op - an operator
  Throws: MatrixDimensionException
    If the operators have different dimensions.

multiply

     public KetVector multiply(KetVector ket)

  Returns the multiplication of this operator and a ket vector.

  Parameters:
    ket - a ket vector
  Throws: DimensionException
    If the operator and vector have different dimensions.

    All Packages  Class Hierarchy  This Package  Previous  Next  Index