/usr/share/axiom-20170501/src/algebra/SPACEC.spad is in axiom-source 20170501-3.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 | )abbrev category SPACEC ThreeSpaceCategory
++ Description:
++ The category ThreeSpaceCategory is used for creating
++ three dimensional objects using functions for defining points, curves,
++ polygons, constructs and the subspaces containing them.
ThreeSpaceCategory(R) : Category == SIG where
R : Ring
I ==> Integer
PI ==> PositiveInteger
NNI ==> NonNegativeInteger
L ==> List
B ==> Boolean
O ==> OutputForm
SUBSPACE ==> SubSpace(3,R)
POINT ==> Point(R)
PROP ==> SubSpaceComponentProperty()
REP3D ==> Record(lp:L POINT,llliPt:L L L NNI, llProp:L L PROP, lProp:L PROP)
OBJ3D ==> Record(points:NNI, curves:NNI, polygons:NNI, constructs:NNI)
SIG ==> SetCategory with
create3Space : () -> %
++ create3Space() creates a \spadtype{ThreeSpace} object capable of
++ holding point, curve, mesh components and any combination.
create3Space : SUBSPACE -> %
++ create3Space(s) creates a \spadtype{ThreeSpace} object containing
++ objects pre-defined within some \spadtype{SubSpace} s.
numberOfComponents : % -> NNI
++ numberOfComponents(s) returns the number of distinct
++ object components in the indicated \spadtype{ThreeSpace}, s, such
++ as points, curves, polygons, and constructs.
numberOfComposites : % -> NNI
++ numberOfComposites(s) returns the number of supercomponents,
++ or composites, in the \spadtype{ThreeSpace}, s; Composites are
++ arbitrary groupings of otherwise distinct and unrelated components;
++ A \spadtype{ThreeSpace} need not have any composites defined at all
++ and, outside of the requirement that no component can belong
++ to more than one composite at a time, the definition and
++ interpretation of composites are unrestricted.
merge : L % -> %
++ merge([s1,s2,...,sn]) will create a new \spadtype{ThreeSpace} that
++ has the components of all the ones in the list; Groupings of
++ components into composites are maintained.
merge : (%,%) -> %
++ merge(s1,s2) will create a new \spadtype{ThreeSpace} that has the
++ components of \spad{s1} and \spad{s2}; Groupings of components
++ into composites are maintained.
composite : L % -> %
++ composite([s1,s2,...,sn]) will create a new \spadtype{ThreeSpace}
++ that is a union of all the components from each
++ \spadtype{ThreeSpace} in the parameter list, grouped as a composite.
components : % -> L %
++ components(s) takes the \spadtype{ThreeSpace} s, and creates a list
++ containing a unique \spadtype{ThreeSpace} for each single component
++ of s. If s has no components defined, the list returned is empty.
composites : % -> L %
++ composites(s) takes the \spadtype{ThreeSpace} s, and creates a list
++ containing a unique \spadtype{ThreeSpace} for each single composite
++ of s. If s has no composites defined (composites need to be
++ explicitly created), the list returned is empty. Note that not all
++ the components need to be part of a composite.
copy : % -> %
++ copy(s) returns a new \spadtype{ThreeSpace} that is an exact copy
++ of s.
enterPointData : (%,L POINT) -> NNI
++ enterPointData(s,[p0,p1,...,pn]) adds a list of points from p0
++ through pn to the \spadtype{ThreeSpace}, s, and returns the index,
++ to the starting point of the list;
modifyPointData : (%,NNI,POINT) -> %
++ modifyPointData(s,i,p) changes the point at the indexed
++ location i in the \spadtype{ThreeSpace}, s, to that of point p.
++ This is useful for making changes to a point which has been
++ transformed.
-- 3D primitives
point : (%,POINT) -> %
++ point(s,p) adds a point component defined by the point, p,
++ specified as a list from \spad{List(R)}, to the
++ \spadtype{ThreeSpace}, s, where R is the \spadtype{Ring} over
++ which the point is defined.
point : (%,L R) -> %
++ point(s,[x,y,z]) adds a point component defined by a list of
++ elements which are from the \spad{PointDomain(R)} to the
++ \spadtype{ThreeSpace}, s, where R is the \spadtype{Ring} over
++ which the point elements are defined.
point : (%,NNI) -> %
++ point(s,i) adds a point component which is placed into a component
++ list of the \spadtype{ThreeSpace}, s, at the index given by i.
point : POINT -> %
++ point(p) returns a \spadtype{ThreeSpace} object which is composed
++ of one component, the point p.
point : % -> POINT
++ point(s) checks to see if the \spadtype{ThreeSpace}, s, is
++ composed of only a single point and if so, returns the point.
++ An error is signaled otherwise.
point? : % -> B
++ point?(s) queries whether the \spadtype{ThreeSpace}, s, is
++ composed of a single component which is a point and returns the
++ boolean result.
curve : (%,L POINT) -> %
++ curve(s,[p0,p1,...,pn]) adds a space curve component defined by a
++ list of points \spad{p0} through \spad{pn}, to the
++ \spadtype{ThreeSpace} s.
curve : (%,L L R) -> %
++ curve(s,[[p0],[p1],...,[pn]]) adds a space curve which is a list of
++ points p0 through pn defined by lists of elements from the domain
++ \spad{PointDomain(m,R)}, where R is the \spadtype{Ring} over which
++ the point elements are defined and m is the dimension of the
++ points, to the \spadtype{ThreeSpace} s.
curve : L POINT -> %
++ curve([p0,p1,p2,...,pn]) creates a space curve defined
++ by the list of points \spad{p0} through \spad{pn}, and returns the
++ \spadtype{ThreeSpace} whose component is the curve.
curve : % -> L POINT
++ curve(s) checks to see if the \spadtype{ThreeSpace}, s, is
++ composed of a single curve defined by a list of points and if so,
++ returns the curve, that is, list of points. An error is signaled
++ otherwise.
curve? : % -> B
++ curve?(s) queries whether the \spadtype{ThreeSpace}, s, is a curve,
++ that is, has one component, a list of list of points, and returns
++ true if it is, or false otherwise.
closedCurve : (%,L POINT) -> %
++ closedCurve(s,[p0,p1,...,pn,p0]) adds a closed curve component
++ which is a list of points defined by the first element p0 through
++ the last element pn and back to the first element p0 again, to the
++ \spadtype{ThreeSpace} s.
closedCurve : (%,L L R) -> %
++ closedCurve(s,[[lr0],[lr1],...,[lrn],[lr0]]) adds a closed curve
++ component defined by a list of points \spad{lr0} through
++ \spad{lrn}, which are lists of elements from the domain
++ \spad{PointDomain(m,R)}, where R is the \spadtype{Ring} over which
++ the point elements are defined and m is the dimension of the
++ points, in which the last element of the list of points contains
++ a copy of the first element list, lr0.
++ The closed curve is added to the \spadtype{ThreeSpace}, s.
closedCurve : L POINT -> %
++ closedCurve(lp) sets a list of points defined by the first element
++ of lp through the last element of lp and back to the first elelment
++ again and returns a \spadtype{ThreeSpace} whose component is the
++ closed curve defined by lp.
closedCurve : % -> L POINT
++ closedCurve(s) checks to see if the \spadtype{ThreeSpace}, s, is
++ composed of a single closed curve component defined by a list of
++ points in which the first point is also the last point, all of
++ which are from the domain \spad{PointDomain(m,R)} and if so,
++ returns the list of points. An error is signaled otherwise.
closedCurve? : % -> B
++ closedCurve?(s) returns true if the \spadtype{ThreeSpace} s
++ contains a single closed curve component, that is, the first element
++ of the curve is also the last element, or false otherwise.
polygon : (%,L POINT) -> %
++ polygon(s,[p0,p1,...,pn]) adds a polygon component defined by a
++ list of points, p0 throught pn, to the \spadtype{ThreeSpace} s.
polygon : (%,L L R) -> %
++ polygon(s,[[r0],[r1],...,[rn]]) adds a polygon component defined
++ by a list of points \spad{r0} through \spad{rn}, which are lists of
++ elements from the domain \spad{PointDomain(m,R)} to the
++ \spadtype{ThreeSpace} s, where m is the dimension of the points
++ and R is the \spadtype{Ring} over which the points are defined.
polygon : L POINT -> %
++ polygon([p0,p1,...,pn]) creates a polygon defined by a list of
++ points, p0 through pn, and returns a \spadtype{ThreeSpace} whose
++ component is the polygon.
polygon : % -> L POINT
++ polygon(s) checks to see if the \spadtype{ThreeSpace}, s, is
++ composed of a single polygon component defined by a list of
++ points, and if so, returns the list of points; An error is
++ signaled otherwise.
polygon? : % -> B
++ polygon?(s) returns true if the \spadtype{ThreeSpace} s contains
++ a single polygon component, or false otherwise.
mesh : (%,L L POINT,L PROP,PROP) -> %
++ mesh(s,[[p0],[p1],...,[pn]],[props],prop) adds a surface component,
++ defined over a list curves which contains lists of points, to the
++ \spadtype{ThreeSpace} s; props is a list which contains the
++ subspace component properties for each surface parameter, and
++ prop is the subspace component property by which the points are
++ defined.
mesh : (%,L L L R,L PROP,PROP) -> %
++ mesh(s, LLLR, [props], prop)
++ where LLLR is of the form:
++ [[[r10]...,[r1m]],[[r20]...,[r2m]],...,[[rn0]...,[rnm]]],
++ adds a surface component to the \spadtype{ThreeSpace} s, which is
++ defined over a rectangular domain of size WxH where W is the number
++ of lists of points from the domain \spad{PointDomain(R)} and H is
++ the number of elements in each of those lists; lprops is the list
++ of the subspace component properties for each curve list, and
++ prop is the subspace component property by which the points are
++ defined.
mesh : (%,L L POINT,B,B) -> %
++ mesh(s, LLP, close1, close2)
++ where LLP is of the form [[p0],[p1],...,[pn]] adds a surface
++ component to the \spadtype{ThreeSpace}, which is defined over a
++ list of curves, in which each of these curves is a list of points.
++ The boolean arguments close1 and close2 indicate how the surface
++ is to be closed. Argument close1 equal true
++ means that each individual list (a curve) is to be closed, that is,
++ the last point of the list is to be connected to the first point.
++ Argument close2 equal true
++ means that the boundary at one end of the surface is to be
++ connected to the boundary at the other end, that is, the boundaries
++ are defined as the first list of points (curve) and
++ the last list of points (curve).
mesh : (%,L L L R,B,B) -> %
++ mesh(s, LLLR, close1, close2)
++ where LLLR is of the form
++ [[[r10]...,[r1m]],[[r20]...,[r2m]],...,[[rn0]...,[rnm]]],
++ adds a surface component to the \spadtype{ThreeSpace} s, which is
++ defined over a rectangular domain of size WxH where W is the number
++ of lists of points from the domain \spad{PointDomain(R)} and H is
++ the number of elements in each of those lists; the booleans close1
++ and close2 indicate how the surface is to be closed: if close1 is
++ true this means that each individual list (a curve) is to be
++ closed (that is,
++ the last point of the list is to be connected to the first point);
++ if close2 is true, this means that the boundary at one end of the
++ surface is to be connected to the boundary at the other end
++ (the boundaries are defined as the first list of points (curve)
++ and the last list of points (curve)).
mesh : L L POINT -> %
++ mesh([[p0],[p1],...,[pn]]) creates a surface defined by a list of
++ curves which are lists, p0 through pn, of points, and returns a
++ \spadtype{ThreeSpace} whose component is the surface.
mesh : (L L POINT,B,B) -> %
++ mesh([[p0],[p1],...,[pn]], close1, close2) creates a surface
++ defined over a list of curves, p0 through pn, which are lists of
++ points; the booleans close1 and close2 indicate how the surface is
++ to be closed: close1 set to true means that each individual list
++ (a curve) is to be closed (that is, the last point of the list is
++ to be connected to the first point); close2 set to true means
++ that the boundary at one end of the surface is to be connected to
++ the boundary at the other end (the boundaries are defined as the
++ first list of points (curve) and the last list of points (curve));
++ the \spadtype{ThreeSpace} containing this surface is returned.
mesh : % -> L L POINT
++ mesh(s) checks to see if the \spadtype{ThreeSpace}, s, is
++ composed of a single surface component defined by a list curves
++ which contain lists of points, and if so, returns the list of
++ lists of points; An error is signaled otherwise.
mesh? : % -> B
++ mesh?(s) returns true if the \spadtype{ThreeSpace} s is composed
++ of one component, a mesh comprising a list of curves which are lists
++ of points, or returns false if otherwise
lp : % -> L POINT
++ lp(s) returns the list of points component which the
++ \spadtype{ThreeSpace}, s, contains; these points are used by
++ reference, that is, the component holds indices referring to the
++ points rather than the points themselves. This allows for sharing
++ of the points.
lllip : % -> L L L NNI
++ lllip(s) checks to see if the \spadtype{ThreeSpace}, s, is
++ composed of a list of components, which are lists of curves,
++ which are lists of indices to points, and if so, returns the list
++ of lists of lists; An error is signaled otherwise.
lllp : % -> L L L POINT -- used by view3D
++ lllp(s) checks to see if the \spadtype{ThreeSpace}, s, is
++ composed of a list of components, which are lists of curves,
++ which are lists of points, and if so, returns the list of
++ lists of lists; An error is signaled otherwise.
llprop : % -> L L PROP -- used by view3D
++ llprop(s) checks to see if the \spadtype{ThreeSpace}, s, is
++ composed of a list of curves which are lists of the
++ subspace component properties of the curves, and if so, returns the
++ list of lists; An error is signaled otherwise.
lprop : % -> L PROP -- used by view3D
++ lprop(s) checks to see if the \spadtype{ThreeSpace}, s, is
++ composed of a list of subspace component properties, and if so,
++ returns the list; An error is signaled otherwise.
objects : % -> OBJ3D
++ objects(s) returns the \spadtype{ThreeSpace}, s, in the form of a
++ 3D object record containing information on the number of points,
++ curves, polygons and constructs comprising the
++ \spadtype{ThreeSpace}..
check : % -> % -- used by mesh
++ check(s) returns lllpt, list of lists of lists of point information
++ about the \spadtype{ThreeSpace} s.
subspace : % -> SUBSPACE
++ subspace(s) returns the \spadtype{SubSpace} which holds all the
++ point information in the \spadtype{ThreeSpace}, s.
coerce : % -> O
++ coerce(s) returns the \spadtype{ThreeSpace} s to Output format.
|