DIRECTORY Rope, IO, AlgebraClasses, ASAtomicFormulaOps, Variables, Polynomials; QESamplePointStructure: CEDAR DEFINITIONS = BEGIN SamplePoint: TYPE = AlgebraClasses.Object; SamplePointData: TYPE = REF SamplePointDataRec; SamplePointDataRec: TYPE ~ RECORD [ cell: CellIndex, -- cell to which this sample point belongs SELECT type:* FROM null => [ ], extended => [ basePoint: PTS.Point, -- an (r-1)-tuple of elements of baseNumberField; this should be a pointer to a cell sample point in one lower dimension definingPolynomial: POL.Polynomial, -- a univariate algebraic polynomial over baseNumberField. isolatingInterval: RI.RatInterval _ NIL, -- for root of definingPolynomial ], primitive => [ point: PTS.Point -- an r-tuple of elements of primitiveNumberField ], ENDCASE ]; SamplePoint: TYPE = AC.Object; SamplePointData: TYPE = REF SamplePointDataRec; SamplePointDataRec: TYPE = RECORD [ cell: AC.Object _ NIL, -- cell to which this sample point belongs basePoint: Vectors.Vector _ NIL, -- an (r-1)-tuple of elements of baseNumberField. definingPolynomial: POL.Polynomial _ NIL, -- a univariate algebraic polynomial over baseNumberField. isolatingInterval: RI.RatInterval _ NIL, -- for root of definingPolynomial point: Vectors.Vector _ NIL -- an r-tuple of elements of primitiveNumberField ]; SamplePointStructureData: TYPE = REF SamplePointStructureDataRec; SamplePointStructureDataRec: TYPE = RECORD [ variable: Variables.Variable, -- variable in terms of which the minimal polynomials of sample point primitive elements will be expressed; need to know it to be able to instantiate a Real Algeraic Numbers structure to read such primtive elements dimension: Ints.Int -- for primitive sample points, implies a vector of this length of elements of some ExtensionField; for extended sample points, implies a vector of length one less of elements of some ExtensionField, a defining polynomial with coefficients over that field, and an isolating interval. ]; MakeSamplePointStructure: AC.BinaryOp; PrintName: AC.ToRopeOp; ShortPrintName: AC.ToRopeOp; Variable: AC.UnaryOp; Dimension: AC.UnaryOp; IsSamplePointStructure: AC.UnaryPredicate; Recast: AC.BinaryOp; CanRecast: AC.BinaryPredicate; ToExpr: AC.ToExprOp; LegalFirstChar: AC.LegalFirstCharOp; Read: AC.ReadOp; FromRope: AC.FromRopeOp; ToRope: AC.ToRopeOp; Write: AC.WriteOp; MakePrimitiveSamplePoint: AC.BinaryImbedOp; MakePrimitiveSamplePointFromData: AC.BinaryOp; Cell: AC.UnaryOp; BasePoint: AC.UnaryOp; DefiningPolynomial: AC.UnaryOp; IsolatingInterval: AC.UnaryOp; Point: AC.UnaryOp; SetCell: AC.BinaryOp; Equal: AC.EqualityOp; END. ξQESamplePointStructure.mesa Last Edited by: January 28, 1988 2:33:42 pm PST Algebraic points as they occur as cad sample points. New Element Representation Old SamplePoint Representation Next three fields are nonNIL iff we have an extended sample point Next field nonNIL iff we have a primitive sample point All four of the above fields are NIL iff we have a NIL sample point Instance Data for SamplePoint Structures SamplePoint Structure Ops arguments are variable: Variables.Variable and dimension: Ints.Int selector: return the variable characterizing this particular Sample Point Structure selector: return the dimension characterizing this particular Sample Point Structure I/O and Conversion Constructors Make primitive or NIL sample point. first arg is the Cell to which this Sample Point belongs. Second arg is the point, i.e. Vectors.Vector, of elements of some ExtensionField which correspond to some primitive sample point. Third arg is the Sample Point Structure to imbed in. We get a NIL sample point iff second arg = NIL. Make primitive or NIL sample point. first arg is the Cell to which this Sample Point belongs. Second arg is the point, i.e. Vectors.Vector, of elements of some ExtensionField which correspond to some primitive sample point. Instantiates the Sample Point Structure defined by the variable of the minimal polynomial of the primitive element of the point elements, and the point dimension, then calls MakePrimitiveSamplePoint with the appropriate arguments. Checks if supplied Cell argument is in fact a Cell; if not, passes NIL for that arg in the call to MakePrimitiveSamplePoint. The purpose of this routine is to be able to create a Sample Point "on the fly", i.e. without being given a structure. Intended to be registered as method "samplePoint", invokable by Evaluator. This is an example of a Method which is really Structure-independent, i.e. it should be available in the system without requiring any particular structure to have been instantiated, it can know a priori exactly how to check its arguments for validity, and of course, it is not naturally associable with any of the Structures of its arguments. Selectors Operations Args are a SamplePoint and a Cell. Assigns Cell to SamplePoint's cell field. Comparison Κ˜Jšœ™J™/J™Jšœ4™4J™J˜šΟk ˜ Jšœ˜Jšœ˜Jšœ˜Jšœ˜Jšœ ˜ Jšœ ˜ —J˜head2šœœ ˜)J˜—Jšœ˜headšΟn™Jšœ œ˜*J™Jšœœœ˜/codešœœ˜šœ˜JšœΟc*˜;šœ˜˜ M˜—˜ Jšœ œŸx˜ŽJšœœ Ÿ;˜_JšœœœŸ!˜JM˜—˜JšœœŸ1˜BM˜—Mš˜—M˜———šž™Jšœ œœ˜J˜Jšœœœ˜/šœœœ˜#Jšœœ œŸ*˜AJ˜J™AJšœœŸ1˜RJšœœœŸ;˜eJšœœœŸ!˜JJ˜J™6JšœœŸ1˜MJ˜J™CJšœ˜——šœ(™(Mšœœœ˜Ašœœœ˜,MšœŸΦ˜τMšœŸœ˜°M˜——šœ™šžœœ ˜&MšœB™BJ™—šž œœ ˜M˜—šžœœ ˜M˜—šžœœ ˜MšœT™TM™—šž œœ ˜MšœU™UM™—šžœœ˜*M™——šœ™šžœœ ˜J˜—šž œœ˜J˜—šžœœ ˜J˜—šžœœ˜$J˜—šžœœ˜J˜—šžœœ ˜J˜—šžœœ ˜J˜—Jšžœ ˜—šœ ™ šžœœ˜+Jšœ#™#Jšœρ™ρJ™/J™J™—šž œœ ˜.Jšœ#™#Jšœ½™½Jšœδ™δJšœΒ™ΒJ™Φ——™ šžœœ ˜J˜—šž œœ ˜J˜—šžœœ ˜J˜—šžœœ ˜J˜—Jšžœœ ˜—™ šžœœ ˜JšœM™M——šœ ™ Jšžœœ ˜˜J™——Jšœ˜—…— <G