close Warning: Can't synchronize with repository "(default)" (The repository directory has changed, you should resynchronize the repository with: trac-admin $ENV repository resync '(default)'). Look in the Trac log for more information.

Changeset 2808 for branches/f4grobner


Ignore:
Timestamp:
2015-06-20T22:08:23-07:00 (9 years ago)
Author:
Marek Rychlik
Message:

* empty log message *

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/f4grobner/ring.lisp

    r2720 r2808  
    7474
    7575(defgeneric r-zerop (object)
    76   (:method ((self number)) (zerop self)))
     76  (:method ((self number)) (zerop self))
     77  (:documentation "Tests whether a ring element is 0."))
    7778
    7879(defgeneric r+ (x y)
    79   (:method ((x number) (y number)) (+ x y)))
     80  (:method ((x number) (y number)) (+ x y))
     81  (:documentation "Adds ring elements."))
    8082
    8183(defgeneric r- (x y)
    82   (:method ((x number) (y number)) (- x y)))
     84  (:method ((x number) (y number)) (- x y))
     85  (:documentation "Subtracts ring elements."))
    8386
    8487(defgeneric r* (x y)
    85   (:method ((x number) (y number)) (* x y)))
     88  (:method ((x number) (y number)) (* x y))
     89  (:documentation "Multiplies ring elements."))
    8690
    87 (defgeneric r-tensor-product (x y))
     91(defgeneric r-tensor-product (x y)
     92  (:documentation "Takes a tensor product of two objects."))
    8893
    8994(defgeneric r/ (x y)
    90   (:method ((x number) (y number)) (/ x y)))
     95  (:method ((x number) (y number)) (/ x y))
     96  (:documentation "Divides ring elements."))
    9197
    9298(defgeneric r-lcm (x y)
    93   (:method ((x integer) (y integer)) (lcm x y)))
     99  (:method ((x integer) (y integer)) (lcm x y))
     100  (:documentation "Returns the least common multiple of ring elements."))
    94101
    95102(defgeneric r-expt (x y)
    96   (:method ((x integer) (y integer)) (expt x y)))
     103  (:method ((x integer) (y integer)) (expt x y))
     104  (:documentation "Raises X to power Y."))
    97105
    98106(defgeneric r-ezgcd (x y)
    99107  (:method ((x integer) (y integer)
    100108            &aux (c (gcd x y)))
    101     (values c (/ x c) (/ y c))))
     109    (values c (/ x c) (/ y c)))
     110  (:documentation "Solves the diophantine system: X=C*X1, Y=C*X2, C=GCD(X,Y)"))
    102111
    103112(defgeneric r-gcd (x y)
Note: See TracChangeset for help on using the changeset viewer.