Changeset 3135
- Timestamp:
- 2015-06-22T11:12:02-07:00 (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/f4grobner/term.lisp
r3134 r3135 45 45 46 46 (defmethod print-object ((self term) stream) 47 (format stream "#<TERM DIMENSION=~A EXPONENTS=~A VALUE=~A>"47 (format stream "#<TERM DIMENSION=~A EXPONENTS=~A COEFF=~A>" 48 48 (monom-dimension self) 49 49 (monom-exponents self) 50 (scalar- valueself)))50 (scalar-coeff self))) 51 51 52 52 (defmethod shared-initialize ((self term) slot-names … … 68 68 ;; value of the coefficient should be preserved. 69 69 (unless (slot-boundp new 'coeff) 70 (setf ( term-coeff new) 1))70 (setf (scalar-coeff new) 1)) 71 71 new) 72 72 … … 114 114 115 115 (defmethod unary-minus ((self term)) 116 (setf ( term-coeff self) (unary-minus (term-coeff self)))116 (setf (scalar-coeff self) (unary-minus (scalar-coeff self))) 117 117 self) 118 118 … … 122 122 123 123 (defmethod r-zerop ((self term)) 124 (r-zerop ( term-coeff self)))124 (r-zerop (scalar-coeff self))) 125 125 126 126 #| … … 129 129 "A human-readable representation of a term as a cons (MONOM . COEFF)." 130 130 (declare (type term term)) 131 (cons (monom->list (term-monom term)) ( term-coeff term)))131 (cons (monom->list (term-monom term)) (scalar-coeff term))) 132 132 133 133 |#
Note:
See TracChangeset
for help on using the changeset viewer.