This file is indexed.

/usr/share/povray-3.7/include/shapesq.inc is in povray-includes 1:3.7.0.4-2.

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
334
335
336
337
338
339
// This work is licensed under the Creative Commons Attribution-ShareAlike 3.0 Unported License.
// To view a copy of this license, visit http://creativecommons.org/licenses/by-sa/3.0/ or send a
// letter to Creative Commons, 444 Castro Street, Suite 900, Mountain View, California, 94041, USA.

#ifndef(ShapesQ_Inc_Temp)
#declare ShapesQ_Inc_Temp = version;
#version 3.5;

#ifdef(View_POV_Include_Stack)
#   debug "including shapesq.inc\n"
#end

/*
              Persistence of Vision Raytracer Version 3.1
                      Quartic shapes include file
              Several cubic and quartic shape definitions
                          by Alexander Enzmann

 In the following descriptions, multiplication of two terms is
 shown as the two terms next to each other (i.e. x y, rather than
 x*y.  The expression c(n, m) is the binomial coefficient, n!/m!(n-m)!.

*/

/* Bicorn
  This curve looks like the top part of a paraboloid, bounded
  from below by another paraboloid.  The basic equation is:
     y^2 - (x^2 + z^2) y^2 - (x^2 + z^2 + 2 y - 1)^2 = 0.  */
#declare Bicorn =
 quartic
  {< 1,   0,   0,   0,  1,   0,   4,   2,   0, -2,
     0,   0,   0,   0,  0,   0,   0,   0,   0,  0,
     0,   0,   0,   1,  0,   3,   0,   4,   0, -4,
     1,   0,  -2,   0,  1>
  }

/* Crossed Trough
  This is a surface with four pieces that sweep up from the x-z plane.
  The equation is: y = x^2 z^2.  */
#declare Crossed_Trough =
 quartic
  {< 0,   0,   0,   0,  0,   0,   0,   4,   0,  0,
     0,   0,   0,   0,  0,   0,   0,   0,   0,  0,
     0,   0,   0,   0,  0,   0,   0,   0,   0, -1,
     0,   0,   0,   0,  0>
  }

/* a drop coming out of water? This is a curve formed by using the equation
  y = 1/2 x^2 (x + 1) as the radius of a cylinder having the x-axis as
  its central axis. The final form of the equation is:
     y^2 + z^2 = 0.5 (x^3 + x^2) */
#declare Cubic_Cylinder =
 quartic 
  {< 0,   0,   0,   -0.5, 0,   0,   0,   0,   0, -0.5,
     0,   0,   0,    0,   0,   0,   0,   0,   0,  0,
     0,   0,   0,    0,   0,   1,   0,   0,   0,  0,
     0,   0,   1,    0,   0>
  }

/* a cubic saddle. The equation is: z = x^3 - y^3. */
#declare Cubic_Saddle_1 =
 quartic 
  {< 0,   0,   0,    1,   0,   0,   0,   0,   0,  0,
     0,   0,   0,    0,   0,   0,   0,   0,   0,  0,
     0,   0,  -1,    0,   0,   0,   0,   0,   0,  0,
     0,   0,   0,   -1,   0>
  }

/* Variant of a devil's curve in 3-space.  This figure has a top and
  bottom part that are very similar to a hyperboloid of one sheet,
  however the central region is pinched in the middle leaving two
  teardrop shaped holes. The equation is:
     x^4 + 2 x^2 z^2 - 0.36 x^2 - y^4 + 0.25 y^2 + z^4 = 0.  */
#declare Devils_Curve =
 quartic 
  {<-1,   0,   0,    0,  0,   0,    0,  -2,   0,  0.36,
     0,   0,   0,    0,  0,   0,    0,   0,   0,  0,
     1,   0,   0,    0,  0,  -0.25, 0,   0,   0,  0,
    -1,   0,   0,    0,  0>
   }

/* Folium
  This is a folium rotated about the x-axis.  The formula is:
     2 x^2 - 3 x y^2 - 3 x z^2 + y^2 + z^2 = 0. */
#declare Folium =
 quartic 
  {< 0,   0,   0,    0,  0,   0,   0,   0,   0,  2,
     0,   0,  -3,    0,  0,   0,   0,  -3,   0,  0,
     0,   0,   0,    0,  0,   1,   0,   0,   0,  0,
     0,   0,   1,    0,  0>
  }

/* Glob - sort of like basic teardrop shape. The equation is:
   y^2 + z^2 = 0.5 x^5 + 0.5 x^4. */
#declare Glob_5 =
 poly 
  {5,
   <-0.5, 0,   0,  -0.5, 0,   0,   0,   0,   0,  0,
     0,   0,   0,   0,   0,   0,   0,   0,   0,  0,
     0,   0,   0,   0,   0,   0,   0,   0,   0,  0,
     0,   0,   0,   0,   0,   0,   0,   0,   0,  0,
     0,   0,   0,   0,   1,   0,   0,   0,   0,  0,
     0,   0,   0,   1,   0,   0>
  }

/* Variant of a lemniscate - the two lobes are much more teardrop-like. */
#declare Twin_Glob =
 poly 
  {6,
   < 4,   0,   0,   0,   0,   0,   0,   0,   0, -4,
     0,   0,   0,   0,   0,   0,   0,   0,   0,  0,
     0,   0,   0,   0,   0,   0,   0,   0,   0,  0,
     0,   0,   0,   0,   0,   0,   0,   0,   0,  0,
     0,   0,   0,   0,   0,   0,   0,   0,   0,  0,
     0,   0,   0,   0,   0,   0,   0,   0,   0,  0,
     0,   0,   0,   0,   0,   0,   0,   0,   0,  0,
     1,   0,   0,   0,   0,   0,   0,   0,   0,  0,
     0,   1,   0,   0>
  }

/*  Approximation to the helix z = arctan(y/x).

   The helix can be approximated with an algebraic equation (kept to the
   range of a quartic) with the following steps:

      tan(z) = y/x   =>  sin(z)/cos(z) = y/x   =>

   (1) x sin(z) - y cos(z) = 0

   Using the taylor expansions for sin, cos about z = 0,

      sin(z) = z - z^3/3! + z^5/5! - ...
      cos(z) = 1 - z^2/2! + z^6/6! - ...

   Throwing out the high order terms, the expression (1) can be written as:

      x (z - z^3/6) - y (1 + z^2/2) = 0, or

  (2) -1/6 x z^3 + x z + 1/2 y z^2 - y = 0

  This helix (2) turns 90 degrees in the range 0 <= z <= sqrt(2)/2.  By using
  scale <2 2 2>, the helix defined below turns 90 degrees in the range
  0 <= z <= sqrt(2) = 1.4042.
*/
#declare Helix =
 quartic 
  {<  0,   0,   0,    0,  0,   0,   0,      0,   0,  0,
      0,   0,   0,    0,  0,   0,  -0.1666, 0,   1,  0,
      0,   0,   0,    0,  0,   0,   0,      0.5, 0, -1,
      0,   0,   0,    0,  0>
   clipped_by
    {object {Cylinder_Z scale 2}
     plane  { z, 1.4142}
     plane  {-z, 0}
    }
   bounded_by{clipped_by}
  }

/* This is an alternate Helix, using clipped_by instead of csg intersection. */
#declare Helix_1 = object {Helix}

/* Hyperbolic Torus having major radius sqrt(40), minor radius sqrt(12).
  This figure is generated by sweeping a circle along the arms of a
  hyperbola.  The equation is:

     x^4 + 2 x^2 y^2 - 2 x^2 z^2 - 104 x^2 + y^4 - 2 y^2 z^2 +
     56 y^2 + z^4 + 104 z^2 + 784 = 0.

  See the description for the torus below. */
#declare Hyperbolic_Torus_40_12 =
 quartic 
  {< 1,   0,   0,    0,     2,   0,   0,  -2,   0, -104,
     0,   0,   0,    0,     0,   0,   0,   0,   0,    0,
     1,   0,   0,   -2,     0,  56,   0,   0,   0,    0,
     1,   0, 104,    0,   784>
  }

/* Lemniscate of Gerono
  This figure looks like two teardrops with their pointed ends connected.
  It is formed by rotating the Lemniscate of Gerono about the x-axis.
  The formula is:
     x^4 - x^2 + y^2 + z^2 = 0. */
#declare Lemniscate =
 quartic 
  {< 1,   0,   0,   0,   0,   0,   0,   0,   0, -1,
     0,   0,   0,   0,   0,   0,   0,   0,   0,  0,
     0,   0,   0,   0,   0,   1,   0,   0,   0,  0,
     0,   0,   1,   0,   0>
  }

/* This is a figure with a bumpy sheet on one side and something that
  looks like a paraboloid (but with an internal bubble).  The formula
  is:
     (x^2 + y^2 + a c x)^2 - (x^2 + y^2)(c - a x)^2.

   -99*x^4+40*x^3-98*x^2*y^2-98*x^2*z^2+99*x^2+40*x*y^2+40*x*z^2+y^4+2*y^2*z^2
   -y^2+z^4-z^2

*/
#declare Quartic_Loop_1 =
 quartic 
  {<99,   0,   0, -40,  98,   0,   0,  98,   0, -99,
     0,   0, -40,   0,   0,   0,   0, -40,   0,   0,
    -1,   0,   0,  -2,   0,   1,   0,   0,   0,   0,
    -1,   0,   1,   0,   0>
  }

/* Monkey Saddle
  This surface has three parts that sweep up and three down.  This gives
  a saddle that has a place for two legs and a tail... The equation is:

     z = c (x^3 - 3 x y^2).

  The value c gives a vertical scale to the surface - the smaller the
  value of c, the flatter the surface will be (near the origin). */
#declare Monkey_Saddle =
 quartic 
  {< 0,   0,   0,   1,  0,   0,   0,   0,   0,  0,
     0,   0,  -3,   0,  0,   0,   0,   0,   0,  0,
     0,   0,   0,   0,  0,   0,   0,   0,   0,  0,
     0,   0,   0,  -1,  0>
  }

/* Parabolic Torus having major radius sqrt(40), minor radius sqrt(12).
  This figure is generated by sweeping a circle along the arms of a
  parabola.  The equation is:

     x^4 + 2 x^2 y^2 - 2 x^2 z - 104 x^2 + y^4 - 2 y^2 z +
     56 y^2 + z^2 + 104 z + 784 = 0.

  See the description for the torus below. */
#declare Parabolic_Torus_40_12 =
 quartic 
  {< 1,   0,   0,    0,     2,   0,   0,   0,  -2, -104,
     0,   0,   0,    0,     0,   0,   0,   0,   0,    0,
     1,   0,   0,    0,    -2,  56,   0,   0,   0,    0,
     0,   0,   1,  104,   784>
  }

/* Piriform
  This figure looks like a hersheys kiss. It is formed by sweeping
  a Piriform about the x-axis.  a basic form of the equation is:
     (x^4 - x^3) + y^2 + z^2 = 0.
*/
#declare Piriform =
 quartic 
  {< 4,   0,   0,   -4,  0,   0,   0,   0,   0,  0,
     0,   0,   0,    0,  0,   0,   0,   0,   0,  0,
     0,   0,   0,    0,  0,   1,   0,   0,   0,  0,
     0,   0,   1,    0,  0>
  }

/* n-Roll Mill
  This curve in the plane looks like several hyperbolas with their
  bumps arranged about the origin.  The general formula is:

     x^n - c(n,2) x^(n-2) y^2 + c(n,4) x^(n-4) y^4 - ... = a

  When rendering in 3-Space, the resulting figure looks like a
  cylinder with indented sides.
*/

/* Quartic parabola - a 4th degree polynomial (has two bumps at the bottom)
  that has been swept around the z axis. The equation is:
     0.1 x^4 - x^2 - y^2 - z^2 + 0.9 = 0. */
#declare Quartic_Paraboloid =
 quartic 
  {< 0.1, 0,   0,  0,   0,   0,   0,   0,   0,  -1,
     0,   0,   0,  0,   0,   0,   0,   0,   0,   0,
     0,   0,   0,  0,   0,   0,   0,   0,   0,  -1,
     0,   0,  -1,  0,   0.9>
  }

/* Quartic Cylinder - a Space Needle?  */
#declare Quartic_Cylinder =
 quartic 
  {< 0,   0,   0,    0,   1,   0,   0,   0,   0,   0.01,
     0,   0,   0,    0,   0,   0,   0,   0,   0,   0,
     0,   0,   0,    1,   0,   0,   0,   0,   0,   0,
     0,   0,   0.01, 0,  -0.01>
  }

/* Steiners quartic surface */
#declare Steiner_Surface =
 quartic 
  {< 0,   0,   0,  0,  1,   0,   0,   1,   0,   0,
     0,   0,   0,  0,  1,   0,   0,   0,   0,   0,
     0,   0,   0,  1,  0,   0,   0,   0,   0,   0,
     0,   0,   0,  0,  0>
  }

/* Torus having major radius sqrt(40), minor radius sqrt(12) */
#declare Torus_40_12 =
 quartic 
  {< 1,   0,   0,    0,     2,   0,   0,   2,   0, -104,
     0,   0,   0,    0,     0,   0,   0,   0,   0,    0,
     1,   0,   0,    2,     0,  56,   0,   0,   0,    0,
     1,   0, -104,   0,   784>
  }

/* Witch of Agnesi */
#declare Witch_Hat =
 quartic 
  {<  0,   0,   0,   0,   0,   0,   1,   0,   0,   0,
      0,   0,   0,   0,   0,   0,   0,   0,   0,   0,
      0,   0,   0,   0,   0,   0,   0,   1,   0,   0.04,
      0,   0,   0,   0,   0.04>
  }

/* very rough approximation to the sin-wave surface z = sin(2 pi x y).
  In order to get an approximation good to 7 decimals at a distance of
  1 from the origin would require a polynomial of degree around 60.  This
  would require around 200k coefficients. For best results, scale by
  something like <1 1 0.2>. */
#declare Sinsurf =
 poly 
  {6,
   <    0,   0,   0,    0,  0,   0,   0,   0,   0,  0,
    -1116.226, 0, 0,    0,  0,   0,   0,   0,   0,  0,
        0,   0,   0,    0,  0,   0,   0,   0,   0,  0,
        0,   0,   0,    0,  0,   0,   0,   0,   0,  0,
        0,   0,   0,    0,  0,   0,   0,   0,   0, 18.8496,
        0,   0,   0,    0,  0,   0,   0,   0,   0,  0,
        0,   0,   0,    0,  0,   0,   0,   0,   0,  0,
        0,   0,   0,    0,  0,   0,   0,   0,   0,  0,
        0,   0,  -1,    0>
   }

/* Empty quartic equation.  Ready to be filled with numbers...
  quartic
   {< 0,   0,   0,   0,   0,   0,   0,   0,   0,   0,
      0,   0,   0,   0,   0,   0,   0,   0,   0,   0,
      0,   0,   0,   0,   0,   0,   0,   0,   0,   0,
      0,   0,   0,   0,   0>
   }
*/

#version ShapesQ_Inc_Temp;
#end