text:
# Painting a cube with 3 colors (each used for 2 faces).

A cube is about to get fully painted using $3$ different colors. Each color is being used for $2$ faces of a cube. How many different cubes can be created this way?

I saw this in a fifth grade math contest and it does not appear to be an easy problem. It took me almost ten minutes to figure out the answer (which happens to be $6$) but I did it by imagination and visualization which is not nearly as satisfactory as a rigid proof.

Could somebody offer an interpretation in terms of advanced mathematics? Group theory (see Burnside's lemma) or maybe graph theory is what comes to mind...

• This seems to relate to Polya's Coloring Theorem: en.wikipedia.org/wiki/P%C3%B3lya_enumeration_theorem – Vladhagen Nov 11 '13 at 19:01
• I don´t think you need advanced mathematics to solve this one. How many ways can I choose 2 objects out of 6? That´s after applying the first color. To that I multiply the number of ways to choose 2 objects out of 4 and I am left with two uncoloured faces which I will colour with the third colour. – Adam Nov 11 '13 at 19:23
• You are missing (some of) the point, Adam. The cube has a geometric structure. That makes certain choices different from others. – Leen Droogendijk Nov 11 '13 at 19:36
• Except, that if you rotate the cube you get, according to my calculation, a different colouring and yet it is clear that it is the same cube. So you need to divide my answer by something - number of rotations? – Adam Nov 11 '13 at 19:37
• Yaeh, I am starting to realize it. – Adam Nov 11 '13 at 19:38

This one can be done with the Polya Enumeration Theorem, which requires the cycle index $Z(G)$ of the face permutation group $G$ of the cube. We now enumerate the permutations from this group by their cycle structure.
There is the identity, which contributes $$a_1^6.$$ There are rotations about diagonals connecting opposite vertices, which contribute $$4 \times 2 \times a_3^2.$$ There are the rotations about an axis passing through the centers of opposite faces, which contribute $$3\times (2 a_1^2 a_4 + a_1^2 a_2^2).$$ Finally there are rotations about an axis passing through the midpoints of opposite edges, which contribute $$6\times a_2^3.$$ It follows that the cycle index is $$Z(G) = \frac{1}{24} a_1^6 + \frac{1}{3} a_3^2 + \frac{1}{4} a_1^2 a_4 + \frac{1}{8} a_1^2 a_2^2 + \frac{1}{4} a_2^3.$$ Substituting the three colors red, green, and blue into this cycle index we get $$Z(G)(R+G+B) = 1/24\, \left( R+G+B \right) ^{6}+1/4\, \left( R+G+B \right) ^{2} \left( {R}^{4} +{G}^{4}+{B}^{4} \right)\\ +1/8\, \left( R+G+B \right) ^{2} \left( {R}^{2}+{G}^{2 }+{B}^{2} \right) ^{2}+1/3\, \left( {R}^{3}+{G}^{3}+{B}^{3} \right) ^{2}+1/4\, \left( {R}^{2}+{G}^{2}+{B}^{2} \right) ^{3}.$$ Expanding this cycle index we obtain $${B}^{6}+{B}^{5}G+{B}^{5}R+2\,{B}^{4}{G}^{2}+2\,{B}^{4}GR+2\,{B}^{4}{R}^{2}+2\,{ B}^{3}{G}^{3}+3\,{B}^{3}{G}^{2}R+3\,{B}^{3}G{R}^{2}\\+2\,{B}^{3}{R}^{3}+2\,{B}^{2 }{G}^{4}+3\,{B}^{2}{G}^{3}R+6\,{B}^{2}{G}^{2}{R}^{2}+3\,{B}^{2}G{R}^{3}+2\,{B}^ {2}{R}^{4}\\+B{G}^{5}+2\,B{G}^{4}R+3\,B{G}^{3}{R}^{2}+3\,B{G}^{2}{R}^{3}+2\,BG{R} ^{4}+B{R}^{5}+{G}^{6}+{G}^{5}R\\+2\,{G}^{4}{R}^{2}+2\,{G}^{3}{R}^{3}+2\,{G}^{2}{R }^{4}+G{R}^{5}+{R}^{6},$$ which finally gives $$[R^2G^2B^2] Z(R+G+B) = 6.$$ This generating function includes all distributions of three or fewer colors,e.g. the coefficient of $GR^5$ is one because there is only one way to paint the cube using one color five times and a second one for the remaining face. Note that we had rotations about face pairs, edge pairs and vertex pairs, which is a standard feature in the symmetry groups of regular polyhedra. The reader is invited to compute the cycle index of the symmetry group of the faces of a tetrahedron.


text:
# gr.pygr.mlab Reference¶

This module offers a simple, matlab-style API built on top of the gr package.

## Output Functions¶

### Line Plots¶

mlab.plot(*args, **kwargs)

Draws one or more line plots.

This function can receive one or more of the following:

• x values and y values, or
• x values and a callable to determine y values, or
• y values only, with their indices as x values
Parameters: args – the data to plot

Usage examples:

>>> # Create example data
>>> x = np.linspace(-2, 2, 40)
>>> y = 0.2*x+0.4
>>> # Plot x and y
>>> mlab.plot(x, y)
>>> # Plot x and a callable
>>> mlab.plot(x, lambda x: 0.2*x + 0.4)
>>> # Plot y, using its indices for the x values
>>> mlab.plot(y)

mlab.oplot(*args, **kwargs)

Draws one or more line plots over another plot.

This function can receive one or more of the following:

• x values and y values, or
• x values and a callable to determine y values, or
• y values only, with their indices as x values
Parameters: args – the data to plot

Usage examples:

>>> # Create example data
>>> x = np.linspace(-2, 2, 40)
>>> y = 0.2*x+0.4
>>> # Draw the first plot
>>> mlab.plot(x, y)
>>> # Plot graph over it
>>> mlab.oplot(x, lambda x: 0.1*x**2 + 0.4*x)

mlab.plot3(*args, **kwargs)

Draws one or more three-dimensional line plots.

Parameters: x – the x coordinates to plot y – the y coordinates to plot z – the z coordinates to plot

Usage examples:

>>> # Create example data
>>> x = np.random.uniform(-1, 1, 100)
>>> y = np.random.uniform(-1, 1, 100)
>>> z = np.random.uniform(-1, 1, 100)
>>> # Plot the points
>>> mlab.plot3(x, y, z)

mlab.polar(*args, **kwargs)

Draws one or more polar plots.

This function can receive one or more of the following:

• angle values and radius values, or
• angle values and a callable to determine radius values
Parameters: args – the data to plot

Usage examples:

>>> # Create example data
>>> angles = np.linspace(0, 2*math.pi, 40)
>>> radii = np.linspace(0, 2, 40)
>>> # Plot angles and radii
>>> # Plot angles and a callable

### Scatter Plots¶

mlab.scatter(*args, **kwargs)

Draws one or more scatter plots.

This function can receive one or more of the following:

• x values and y values, or
• x values and a callable to determine y values, or
• y values only, with their indices as x values

Additional to x and y values, you can provide values for the markers’ size and color. Size values will determine the marker size in percent of the regular size, and color values will be used in combination with the current colormap.

Parameters: args – the data to plot

Usage examples:

>>> # Create example data
>>> x = np.linspace(-2, 2, 40)
>>> y = 0.2*x+0.4
>>> # Plot x and y
>>> mlab.scatter(x, y)
>>> # Plot x and a callable
>>> mlab.scatter(x, lambda x: 0.2*x + 0.4)
>>> # Plot y, using its indices for the x values
>>> mlab.scatter(y)
>>> # Plot a diagonal with increasing size and color
>>> x = np.linspace(0, 1, 11)
>>> y = np.linspace(0, 1, 11)
>>> s = np.linspace(50, 400, 11)
>>> c = np.linspace(0, 255, 11)
>>> mlab.scatter(x, y, s, c)

mlab.scatter3(x, y, z, c=None, *args, **kwargs)

Draws one or more three-dimensional scatter plots.

Additional to x, y and z values, you can provide values for the markers’ color. Color values will be used in combination with the current colormap.

Parameters: x – the x coordinates to plot y – the y coordinates to plot z – the z coordinates to plot c – the optional color values to plot

Usage examples:

>>> # Create example data
>>> x = np.random.uniform(-1, 1, 100)
>>> y = np.random.uniform(-1, 1, 100)
>>> z = np.random.uniform(-1, 1, 100)
>>> c = np.random.uniform(1, 1000, 100)
>>> # Plot the points
>>> mlab.scatter3(x, y, z)
>>> # Plot the points with colors
>>> mlab.scatter3(x, y, z, c)

### Stem Plots¶

mlab.stem(*args, **kwargs)

Draws a stem plot.

This function can receive one or more of the following:

• x values and y values, or
• x values and a callable to determine y values, or
• y values only, with their indices as x values
Parameters: args – the data to plot

Usage examples:

>>> # Create example data
>>> x = np.linspace(-2, 2, 40)
>>> y = 0.2*x+0.4
>>> # Plot x and y
>>> mlab.stem(x, y)
>>> # Plot x and a callable
>>> mlab.stem(x, lambda x: 0.2*x + 0.4)
>>> # Plot y, using its indices for the x values
>>> mlab.stem(y)

### Histograms¶

mlab.histogram(x, num_bins=None, **kwargs)

Draws a histogram.

If num_bins is None or 0, this function computes the number of bins as $$\text{round}(3.3\cdot\log_{10}(n))+1$$ with n as the number of elements in x, otherwise the given number of bins is used for the histogram.

Parameters: x – the values to draw as histogram num_bins – the number of bins in the histogram

Usage examples:

>>> # Create example data
>>> x = np.random.uniform(-1, 1, 100)
>>> # Draw the histogram
>>> mlab.histogram(x)
>>> # Draw the histogram with 19 bins
>>> mlab.histogram(x, num_bins=19)

mlab.hexbin(*args, **kwargs)

Draws a hexagon binning plot.

This function uses hexagonal binning and the the current colormap to display a series of points. It can receive one or more of the following:

• x values and y values, or
• x values and a callable to determine y values, or
• y values only, with their indices as x values
Parameters: args – the data to plot

Usage examples:

>>> # Create example data
>>> x = np.random.normal(0, 1, 100000)
>>> y = np.random.normal(0, 1, 100000)
>>> # Draw the hexbin plot
>>> mlab.hexbin(x, y)

### Contour Plots¶

mlab.contour(*args, **kwargs)

Draws a contour plot.

This function uses the current colormap to display a either a series of points or a two-dimensional array as a contour plot. It can receive one or more of the following:

• x values, y values and z values, or
• N x values, M y values and z values on a NxM grid, or
• N x values, M y values and a callable to determine z values

If a series of points is passed to this function, their values will be interpolated on a grid. For grid points outside the convex hull of the provided points, a value of 0 will be used.

Parameters: args – the data to plot

Usage examples:

>>> # Create example point data
>>> x = np.random.uniform(-4, 4, 100)
>>> y = np.random.uniform(-4, 4, 100)
>>> z = np.sin(x) + np.cos(y)
>>> # Draw the contour plot
>>> mlab.contour(x, y, z)
>>> # Create example grid data
>>> x = np.linspace(-2, 2, 40)
>>> y = np.linspace(0, np.pi, 20)
>>> z = np.sin(x[:, np.newaxis]) + np.cos(y[np.newaxis, :])
>>> # Draw the contour plot
>>> mlab.contour(x, y, z)
>>> # Draw the contour plot using a callable
>>> mlab.contour(x, y, lambda x, y: np.sin(x) + np.cos(y))

mlab.contourf(*args, **kwargs)

Draws a filled contour plot.

This function uses the current colormap to display a either a series of points or a two-dimensional array as a filled contour plot. It can receive one or more of the following:

• x values, y values and z values, or
• N x values, M y values and z values on a NxM grid, or
• N x values, M y values and a callable to determine z values

If a series of points is passed to this function, their values will be interpolated on a grid. For grid points outside the convex hull of the provided points, a value of 0 will be used.

Parameters: args – the data to plot

Usage examples:

>>> # Create example point data
>>> x = np.random.uniform(-4, 4, 100)
>>> y = np.random.uniform(-4, 4, 100)
>>> z = np.sin(x) + np.cos(y)
>>> # Draw the filled contour plot
>>> mlab.contourf(x, y, z)
>>> # Create example grid data
>>> x = np.linspace(-2, 2, 40)
>>> y = np.linspace(0, np.pi, 20)
>>> z = np.sin(x[:, np.newaxis]) + np.cos(y[np.newaxis, :])
>>> # Draw the filled contour plot
>>> mlab.contourf(x, y, z)
>>> # Draw the filled contour plot using a callable
>>> mlab.contourf(x, y, lambda x, y: np.sin(x) + np.cos(y))

mlab.tricont(x, y, z, *args, **kwargs)

Draws a triangular contour plot.

This function uses the current colormap to display a series of points as a triangular contour plot. It will use a Delaunay triangulation to interpolate the z values between x and y values. If the series of points is concave, this can lead to interpolation artifacts on the edges of the plot, as the interpolation may occur in very acute triangles.

Parameters: x – the x coordinates to plot y – the y coordinates to plot z – the z coordinates to plot

Usage examples:

>>> # Create example point data
>>> x = np.random.uniform(-4, 4, 100)
>>> y = np.random.uniform(-4, 4, 100)
>>> z = np.sin(x) + np.cos(y)
>>> # Draw the triangular contour plot
>>> mlab.tricont(x, y, z)

### Surface Plots¶

mlab.surface(*args, **kwargs)

Draws a three-dimensional surface plot.

This function uses the current colormap to display a either a series of points or a two-dimensional array as a surface plot. It can receive one or more of the following:

• x values, y values and z values, or
• N x values, M y values and z values on a NxM grid, or
• N x values, M y values and a callable to determine z values

If a series of points is passed to this function, their values will be interpolated on a grid. For grid points outside the convex hull of the provided points, a value of 0 will be used.

Parameters: args – the data to plot

Usage examples:

>>> # Create example point data
>>> x = np.random.uniform(-4, 4, 100)
>>> y = np.random.uniform(-4, 4, 100)
>>> z = np.sin(x) + np.cos(y)
>>> # Draw the surface plot
>>> mlab.surface(x, y, z)
>>> # Create example grid data
>>> x = np.linspace(-2, 2, 40)
>>> y = np.linspace(0, np.pi, 20)
>>> z = np.sin(x[:, np.newaxis]) + np.cos(y[np.newaxis, :])
>>> # Draw the surface plot
>>> mlab.surface(x, y, z)
>>> # Draw the surface plot using a callable
>>> mlab.surface(x, y, lambda x, y: np.sin(x) + np.cos(y))

mlab.trisurf(*args, **kwargs)

Draws a triangular surface plot.

This function uses the current colormap to display a series of points as a triangular surface plot. It will use a Delaunay triangulation to interpolate the z values between x and y values. If the series of points is concave, this can lead to interpolation artifacts on the edges of the plot, as the interpolation may occur in very acute triangles.

Parameters: x – the x coordinates to plot y – the y coordinates to plot z – the z coordinates to plot

Usage examples:

>>> # Create example point data
>>> x = np.random.uniform(-4, 4, 100)
>>> y = np.random.uniform(-4, 4, 100)
>>> z = np.sin(x) + np.cos(y)
>>> # Draw the triangular surface plot
>>> mlab.trisurf(x, y, z)

mlab.wireframe(*args, **kwargs)

Draws a three-dimensional wireframe plot.

This function uses the current colormap to display a either a series of points or a two-dimensional array as a wireframe plot. It can receive one or more of the following:

• x values, y values and z values, or
• N x values, M y values and z values on a NxM grid, or
• N x values, M y values and a callable to determine z values

If a series of points is passed to this function, their values will be interpolated on a grid. For grid points outside the convex hull of the provided points, a value of 0 will be used.

Parameters: args – the data to plot

Usage examples:

>>> # Create example point data
>>> x = np.random.uniform(-4, 4, 100)
>>> y = np.random.uniform(-4, 4, 100)
>>> z = np.sin(x) + np.cos(y)
>>> # Draw the wireframe plot
>>> mlab.wireframe(x, y, z)
>>> # Create example grid data
>>> x = np.linspace(-2, 2, 40)
>>> y = np.linspace(0, np.pi, 20)
>>> z = np.sin(x[:, np.newaxis]) + np.cos(y[np.newaxis, :])
>>> # Draw the wireframe plot
>>> mlab.wireframe(x, y, z)
>>> # Draw the wireframe plot using a callable
>>> mlab.wireframe(x, y, lambda x, y: np.sin(x) + np.cos(y))

### Heatmaps¶

mlab.heatmap(data, **kwargs)

Draws a heatmap.

This function uses the current colormap to display a two-dimensional array as a heatmap. The array is drawn with its first value in the upper left corner, so in some cases it may be neccessary to flip the columns (see the example below).

By default the function will use the row and column indices for the x- and y-axes, so setting the axis limits is recommended. Also note that the values in the array must lie within the current z-axis limits so it may be neccessary to adjust these limits or clip the range of array values.

Parameters: data – the heatmap data

Usage examples:

>>> # Create example data
>>> x = np.linspace(-2, 2, 40)
>>> y = np.linspace(0, np.pi, 20)
>>> z = np.sin(x[np.newaxis, :]) + np.cos(y[:, np.newaxis])
>>> # Draw the heatmap
>>> mlab.heatmap(z[::-1, :], xlim=(-2, 2), ylim=(0, np.pi))

### Images¶

mlab.imshow(image, **kwargs)

Draws an image.

This function can draw an image either from reading a file or using a two-dimensional array and the current colormap.

Parameters: image – an image file name or two-dimensional array

Usage examples:

>>> # Create example data
>>> x = np.linspace(-2, 2, 40)
>>> y = np.linspace(0, np.pi, 20)
>>> z = np.sin(x[np.newaxis, :]) + np.cos(y[:, np.newaxis])
>>> # Draw an image from a 2d array
>>> mlab.imshow(z)
>>> # Draw an image from a file
>>> mlab.imshow("example.png")

### Isosurfaces¶

mlab.isosurface(v, **kwargs)

Draws an isosurface.

This function can draw an image either from reading a file or using a two-dimensional array and the current colormap. Values greater than the isovalue will be seen as outside the isosurface, while values less than the isovalue will be seen as inside the isosurface.

Parameters: v – the volume data isovalue – the isovalue

Usage examples:

>>> # Create example data
>>> x = np.linspace(-1, 1, 40)[:, np.newaxis, np.newaxis]
>>> y = np.linspace(-1, 1, 40)[np.newaxis, :, np.newaxis]
>>> z = np.linspace(-1, 1, 40)[np.newaxis, np.newaxis, :]
>>> v = 1-(x**2 + y**2 + z**2)**0.5
>>> # Draw an image from a 2d array
>>> mlab.isosurface(v, isovalue=0.2)

## Attribute Functions¶

mlab.title(title='')

Sets the plot title.

The plot title is drawn using the extended text function gr.textext(). You can use a subset of LaTeX math syntax, but will need to escape certain characters, e.g. parentheses. For more information see the documentation of gr.textext().

Parameters: title – the plot title

Usage examples:

>>> # Set the plot title to "Example Plot"
>>> mlab.title("Example Plot")
>>> # Clear the plot title
>>> mlab.title()

mlab.legend(*labels, **kwargs)

Sets the labels and location for the legend of the current plot.

The labels for the legend are drawn using the extended text function gr.textext(). You can use a subset of LaTeX math syntax, but will need to escape certain characters, e.g. parentheses. For more information see the documentation of gr.textext().

Parameters: labels – the labels for each graph in the current plot location – the location of the legend (from 1 to 10)

Usage examples:

>>> # Set the labels for the two graphs "f(x)" and "g(x)"
>>> mlab.legend("f$$x$$", "g$$x$$")
>>> # Set the labels and draws the legend in the lower right corner
>>> mlab.legend("f$$x$$", "g$$x$$", location=4)
>>> # Resets the legend
>>> mlab.legend()

mlab.xlabel(x_label='')

Sets the x-axis label.

The axis labels are drawn using the extended text function gr.textext(). You can use a subset of LaTeX math syntax, but will need to escape certain characters, e.g. parentheses. For more information see the documentation of gr.textext().

Parameters: x_label – the x-axis label

Usage examples:

>>> # Set the x-axis label to "x"
>>> mlab.xlabel("x")
>>> # Clear the x-axis label
>>> mlab.xlabel()

mlab.ylabel(y_label='')

Sets the y-axis label.

The axis labels are drawn using the extended text function gr.textext(). You can use a subset of LaTeX math syntax, but will need to escape certain characters, e.g. parentheses. For more information see the documentation of gr.textext().

Parameters: y_label – the y-axis label

Usage examples:

>>> # Set the y-axis label to "y$$x$$"
>>> mlab.ylabel("y$$x$$")
>>> # Clear the y-axis label
>>> mlab.ylabel()

mlab.zlabel(z_label='')

Sets the z-axis label.

The axis labels are drawn using the extended text function gr.textext(). You can use a subset of LaTeX math syntax, but will need to escape certain characters, e.g. parentheses. For more information see the documentation of gr.textext().

Parameters: z_label – the z-axis label

Usage examples:

>>> # Set the z-axis label to "z(x, y)"
>>> mlab.zlabel("z$$x, y$$")
>>> # Clear the z-axis label
>>> mlab.zlabel()

mlab.xlim(x_min=None, x_max=None)

Sets the limits for the x-axis.

The x-axis limits can either be passed as individual arguments or as a tuple of (x_min, x_max). Setting either limit to None will cause it to be automatically determined based on the data, which is the default behavior.

Parameters: x_min – the x-axis lower limit, or None to use an automatic lower limit, or a tuple of both x-axis limits x_max – the x-axis upper limit, or None to use an automatic upper limit, or None if both x-axis limits were passed as first argument

Usage examples:

>>> # Set the x-axis limits to -1 and 1
>>> mlab.xlim(-1, 1)
>>> # Set the x-axis limits to -1 and 1 using a tuple
>>> mlab.xlim((-1, 1))
>>> # Reset the x-axis limits to be determined automatically
>>> mlab.xlim()
>>> # Reset the x-axis upper limit and set the lower limit to 0
>>> mlab.xlim(0, None)
>>> # Reset the x-axis lower limit and set the upper limit to 1
>>> mlab.xlim(None, 1)

mlab.ylim(y_min=None, y_max=None)

Sets the limits for the y-axis and updates the current plot.

The y-axis limits can either be passed as individual arguments or as a tuple of (y_min, y_max). Setting either limit to None will cause it to be automatically determined based on the data, which is the default behavior.

Parameters: y_min – the y-axis lower limit, or None to use an automatic lower limit, or a tuple of both y-axis limits y_max – the y-axis upper limit, or None to use an automatic upper limit, or None if both y-axis limits were passed as first argument

Usage examples:

>>> # Set the y-axis limits to -1 and 1
>>> mlab.ylim(-1, 1)
>>> # Set the y-axis limits to -1 and 1 using a tuple
>>> mlab.ylim((-1, 1))
>>> # Reset the y-axis limits to be determined automatically
>>> mlab.ylim()
>>> # Reset the y-axis upper limit and set the lower limit to 0
>>> mlab.ylim(0, None)
>>> # Reset the y-axis lower limit and set the upper limit to 1
>>> mlab.ylim(None, 1)

mlab.zlim(z_min=None, z_max=None)

Sets the limits for the z-axis and updates the current plot.

The z-axis limits can either be passed as individual arguments or as a tuple of (z_min, z_max). Setting either limit to None will cause it to be automatically determined based on the data, which is the default behavior.

Parameters: z_min – the z-axis lower limit, or None to use an automatic lower limit, or a tuple of both z-axis limits z_max – the z-axis upper limit, or None to use an automatic upper limit, or None if both z-axis limits were passed as first argument

Usage examples:

>>> # Set the z-axis limits to -1 and 1
>>> mlab.zlim(-1, 1)
>>> # Set the z-axis limits to -1 and 1 using a tuple
>>> mlab.zlim((-1, 1))
>>> # Reset the z-axis limits to be determined automatically
>>> mlab.zlim()
>>> # Reset the z-axis upper limit and set the lower limit to 0
>>> mlab.zlim(0, None)
>>> # Reset the z-axis lower limit and set the upper limit to 1
>>> mlab.zlim(None, 1)

mlab.xlog(xlog=True)

Enables or disables a logarithmic scale for the x-axis.

Parameters: xlog – whether or not the x-axis should be logarithmic

Usage examples:

>>> # Enable a logarithic x-axis
>>> mlab.xlog()
>>> # Disable it again
>>> mlab.xlog(False)

mlab.ylog(ylog=True)

Enables or disables a logarithmic scale for the y-axis.

Parameters: ylog – whether or not the y-axis should be logarithmic

Usage examples:

>>> # Enable a logarithic y-axis
>>> mlab.ylog()
>>> # Disable it again
>>> mlab.ylog(False)

mlab.zlog(zlog=True)

Enables or disables a logarithmic scale for the z-axis.

Parameters: zlog – whether or not the z-axis should be logarithmic

Usage examples:

>>> # Enable a logarithic z-axis
>>> mlab.zlog()
>>> # Disable it again
>>> mlab.zlog(False)

mlab.xflip(xflip=True)

Enables or disables x-axis flipping/reversal.

Parameters: xflip – whether or not the x-axis should be flipped

Usage examples:

>>> # Flips/Reverses the x-axis
>>> mlab.xlog()
>>> # Restores the x-axis
>>> mlab.xlog(False)

mlab.yflip(yflip=True)

Enables or disables y-axis flipping/reversal.

Parameters: yflip – whether or not the y-axis should be flipped

Usage examples:

>>> # Flips/Reverses the y-axis
>>> mlab.ylog()
>>> # Restores the y-axis
>>> mlab.ylog(False)

mlab.zflip(zflip=True)

Enables or disables z-axis flipping/reversal.

Parameters: zflip – whether or not the z-axis should be flipped

Usage examples:

>>> # Flips/Reverses the z-axis
>>> mlab.zlog()
>>> # Restores the z-axis
>>> mlab.zlog(False)

mlab.rotation(rotation)

Sets the 3d axis rotation of the current plot.

The rotation can be any value between 0 and 90, and controls the angle between the viewer projected onto the X-Y-plane and the x-axis.

Parameters: rotation – the 3d axis rotation

Usage examples:

>>> # Create example data
>>> x = np.random.uniform(0, 1, 100)
>>> y = np.random.uniform(0, 1, 100)
>>> z = np.random.uniform(0, 1, 100)
>>> # Set the rotation and draw an example plot
>>> mlab.rotation(45)
>>> mlab.plot3(x, y, z)

mlab.tilt(tilt)

Sets the 3d axis tilt of the current plot.

The tilt can be any value between 0 and 90, and controls the angle between the viewer and the X-Y-plane.

Parameters: tilt – the 3d axis tilt

Usage examples:

>>> # Create example data
>>> x = np.random.uniform(0, 1, 100)
>>> y = np.random.uniform(0, 1, 100)
>>> z = np.random.uniform(0, 1, 100)
>>> # Set the tilt and draw an example plot
>>> mlab.tilt(45)
>>> mlab.plot3(x, y, z)

mlab.colormap(colormap)

Sets the colormap for the current plot or enables manual colormap control.

Parameters: colormap – The name of a gr colormap One of the gr colormap constants (gr.COLORMAP_…) None, if the colormap should use the current colors set by gr.setcolorrep()

Usage examples:

>>> # Use one of the built-in colormap names
>>> mlab.colormap('viridis')
>>> # Use one of the built-in colormap constants
>>> mlab.colormap(gr.COLORMAP_BWR)
>>> # Use a custom colormap
>>> for i in range(256):
...     gr.setcolorrep(1.0-i/255.0, 1.0, i/255.0)
...
>>> mlab.colormap(None)

## Control Functions¶

mlab.figure(**kwargs)

Creates a new figure with the given settings.

Settings like the current colormap, title or axis limits as stored in the current figure. This function creates a new figure, restores the default settings and applies any settings passed to the function as keyword arguments.

Usage examples:

>>> # Restore all default settings
>>> mlab.figure()
>>> # Restore all default settings and set the title
>>> mlab.figure(title="Example Figure")

mlab.subplot(num_rows, num_columns, subplot_indices)

Sets current subplot index.

By default, the current plot will cover the whole window. To display more than one plot, the window can be split into a number of rows and columns, with the current plot covering one or more cells in the resulting grid.

Subplot indices are one-based and start at the upper left corner, with a new row starting after every num_columns subplots.

Parameters: num_rows – the number of subplot rows num_columns – the number of subplot columns subplot_indices – the subplot index to be used by the current plot a pair of subplot indices, setting which subplots should be covered by the current plot

Usage examples:

>>> # Set the current plot to the second subplot in a 2x3 grid
>>> mlab.subplot(2, 3, 2)
>>> # Set the current plot to cover the first two rows of a 4x2 grid
>>> mlab.subplot(4, 2, (1, 4))
>>> # Use the full window for the current plot
>>> mlab.subplot(1, 1, 1)

mlab.savefig(filename)

Saves the current figure to a file.

This function draw the current figure using one of GR’s workstation types to create a file of the given name. Which file types are supported depends on the installed workstation types, but GR usually is built with support for .png, .jpg, .pdf, .ps, .gif and various other file formats.

Parameters: filename – the filename the figure should be saved to

Usage examples:

>>> # Create a simple plot
>>> mlab.plot(range(100), lambda x: 1/(x+1))
>>> # Save the figure to a file
>>> mlab.savefig("example.png")

mlab.hold(flag)

Sets the hold flag for combining multiple plots.

The hold flag prevents drawing of axes and clearing of previous plots, so that the next plot will be drawn on top of the previous one.

Parameters: flag – the value of the hold flag

Usage examples:

>>> # Create example data
>>> x = np.linspace(0, 1, 100)
>>> # Draw the first plot
>>> mlab.plot(x, lambda x: x**2)
>>> # Set the hold flag
>>> mlab.hold(True)

format: plain


text:
#### Disentangled Representation Learning for Astronomical Chemical Tagging

##### Damien de Mijolla, Melissa Ness, Serena Viti, Adam Wheeler

Modern astronomical surveys are observing spectral data for millions of stars. These spectra contain chemical information that can be used to trace the Galaxy's formation and chemical enrichment history. However, extracting the information from spectra, and making precise and accurate chemical abundance measurements are challenging. Here, we present a data-driven method for isolating the chemical factors of variation in stellar spectra from those of other parameters (i.e. \teff, \logg, \feh). This enables us to build a spectral projection for each star with these parameters removed. We do this with no ab initio knowledge of elemental abundances themselves, and hence bypass the uncertainties and systematics associated with modeling that rely on synthetic stellar spectra. To remove known non-chemical factors of variation, we develop and implement a neural network architecture that learns a disentangled spectral representation. We simulate our recovery of chemically identical stars using the disentangled spectra in a synthetic APOGEE-like dataset. We show that this recovery declines as a function of the signal to noise ratio, but that our neural network architecture outperforms simpler modeling choices. Our work demonstrates the feasibility of data-driven abundance-free chemical tagging.

arrow_drop_up


text:
• Award-winning private GMAT tutoring
Register now and save up to $200 Available with Beat the GMAT members only code • 5 Day FREE Trial Study Smarter, Not Harder Available with Beat the GMAT members only code • Most awarded test prep in the world Now free for 30 days Available with Beat the GMAT members only code • Free Practice Test & Review How would you score if you took the GMAT Available with Beat the GMAT members only code • Free Veritas GMAT Class Experience Lesson 1 Live Free Available with Beat the GMAT members only code • Magoosh Study with Magoosh GMAT prep Available with Beat the GMAT members only code • 5-Day Free Trial 5-day free, full-access trial TTP Quant Available with Beat the GMAT members only code • 1 Hour Free BEAT THE GMAT EXCLUSIVE Available with Beat the GMAT members only code • Get 300+ Practice Questions 25 Video lessons and 6 Webinars for FREE Available with Beat the GMAT members only code • Free Trial & Practice Exam BEAT THE GMAT EXCLUSIVE Available with Beat the GMAT members only code ## A study of ticket sales at a summer theater festival found This topic has 3 expert replies and 1 member reply RBBmba@2014 Legendary Member Joined 30 May 2012 Posted: 889 messages Followed by: 4 members Upvotes: 8 #### A study of ticket sales at a summer theater festival found Thu Jun 23, 2016 5:34 am A study of ticket sales at a summer theater festival found that people who bought tickets to individual plays had a no-show rate of less than 1 percent, while those who paid in advance for all ten plays being performed that summer had a no-show rate of nearly 30 percent. This may be at least in part because the greater the awareness customers retain about the cost of an item, the more likely they are to use it. Which of the following would, if true, best serve as an alternative explanation of the results of the study? (A) The price per ticket was slightly cheaper for those who bought all ten tickets in advance. (B) Many people who attended the theater festival believed strongly that they should support it financially. (C) Those who attended all ten plays became eligible for a partial refund. (D) Usually, people who bought tickets to individual plays did so immediately prior to each performance that they attended. (E) People who arrived just before the performance began could not be assured of obtaining seats in a preferred location. OA: D Source: OG 2016,CR Qs.39 @Verbal Experts - although I got this one correct, but would like to know why EXACTLY A and C are wrong ? Please share your analysis on this CR. ### GMAT/MBA Expert DavidG@VeritasPrep Legendary Member Joined 14 Jan 2015 Posted: 2627 messages Followed by: 117 members Upvotes: 1153 GMAT Score: 770 Wed Jun 29, 2016 7:39 am Quote: Reason to eliminate C: This "partial refund" will come into play after attending the theater. So, before attending, people just may not know about the refund. So, in that way C simply doesn't stand as an alternative explanation. Well, I don't think we can make the assumption that this is a surprise refund that ticket-buyers will only find out about after they attend. Think of it this way. If they know about the refund, they're be more motivated to attend, not less. If they don't know about the refund, it's irrelevant, as far as incentives go. Either way, it can't possibly be the correct answer. _________________ Veritas Prep | GMAT Instructor Veritas Prep Reviews Save$100 off any live Veritas Prep GMAT Course

Enroll in a Veritas Prep GMAT class completely for FREE. Wondering if a GMAT course is right for you? Attend the first class session of an actual GMAT course, either in-person or live online, and see for yourself why so many students choose to work with Veritas Prep. Find a class now!

### GMAT/MBA Expert

DavidG@VeritasPrep Legendary Member
Joined
14 Jan 2015
Posted:
2627 messages
Followed by:
117 members
1153
GMAT Score:
770
Wed Jun 29, 2016 7:36 am
Quote:
Reason to eliminate A: In any way, people will end up paying more than they pay for a single ticket. So, if they're really cost-aware then they seem to be more likely to go to those shows for which they made advance payment.
Sounds valid to me. (And I'd add that the modifier "slightly" suggests that the price difference, whatever it is, is basically irrelevant.)

_________________
Veritas Prep | GMAT Instructor

Veritas Prep Reviews
Save $100 off any live Veritas Prep GMAT Course Last edited by DavidG@VeritasPrep on Mon Jul 04, 2016 10:41 am; edited 1 time in total Enroll in a Veritas Prep GMAT class completely for FREE. Wondering if a GMAT course is right for you? Attend the first class session of an actual GMAT course, either in-person or live online, and see for yourself why so many students choose to work with Veritas Prep. Find a class now! ### GMAT/MBA Expert DavidG@VeritasPrep Legendary Member Joined 14 Jan 2015 Posted: 2627 messages Followed by: 117 members Upvotes: 1153 GMAT Score: 770 Sat Jun 25, 2016 7:20 am RBBmba@2014 wrote: A study of ticket sales at a summer theater festival found that people who bought tickets to individual plays had a no-show rate of less than 1 percent, while those who paid in advance for all ten plays being performed that summer had a no-show rate of nearly 30 percent. This may be at least in part because the greater the awareness customers retain about the cost of an item, the more likely they are to use it. Which of the following would, if true, best serve as an alternative explanation of the results of the study? (A) The price per ticket was slightly cheaper for those who bought all ten tickets in advance. (B) Many people who attended the theater festival believed strongly that they should support it financially. (C) Those who attended all ten plays became eligible for a partial refund. (D) Usually, people who bought tickets to individual plays did so immediately prior to each performance that they attended. (E) People who arrived just before the performance began could not be assured of obtaining seats in a preferred location. OA: D Source: OG 2016,CR Qs.39 @Verbal Experts - although I got this one correct, but would like to know why EXACTLY A and C are wrong ? Please share your analysis on this CR. Imagine a simple real-world scenario. I bought the 10 play package. You bought a ticket for one play. You show up. I don't. We're trying to understand why. The initial argument is that if you remember more about the cost of an individual ticket, you're more likely to go. (It's a strange argument. How hard would it be to determine the price per ticket of a 10-ticket package?) We're looking for an alternative explanation for why you'd go and I wouldn't. 'A' doesn't shed any light on why you'd attend and I wouldn't. Say you bought your ticket for$30, and I bought a 10-ticket package for $280. The fact that I'm paying$28/show doesn't really explain why I'd be less likely to go than you would. Presumably, I was interested in seeing the show when I bought the tickets. I paid nearly as much as you did. So why am I not there?

'C' is even worse. If I get a refund for attending all the plays, I should be more motivated to attend, not less.

_________________
Veritas Prep | GMAT Instructor

Veritas Prep Reviews
Save \$100 off any live Veritas Prep GMAT Course

Enroll in a Veritas Prep GMAT class completely for FREE. Wondering if a GMAT course is right for you? Attend the first class session of an actual GMAT course, either in-person or live online, and see for yourself why so many students choose to work with Veritas Prep. Find a class now!
RBBmba@2014 Legendary Member
Joined
30 May 2012
Posted:
889 messages
Followed by:
4 members
8
Tue Jun 28, 2016 11:45 am
Hi DavidG@VeritasPrep,
Thanks for the reply. Got it; just would like to know whether A & C can be eliminated for the following reason as well (on top of what you already mentioned above) ?

Reason to eliminate A: In any way, people will end up paying more than they pay for a single ticket. So, if they're really cost-aware then they seem to be more likely to go to those shows for which they made advance payment.

Reason to eliminate C: This "partial refund" will come into play after attending the theater. So, before attending, people just may not know about the refund. So, in that way C simply doesn't stand as an alternative explanation.

Thoughts ?

### Best Conversation Starters

1 lheiannie07 108 topics
2 Roland2rule 63 topics
3 ardz24 63 topics
4 LUANDATO 52 topics
5 Vincen 50 topics
See More Top Beat The GMAT Members...

### Most Active Experts

1 GMATGuruNY

The Princeton Review Teacher

144 posts
2 Jeff@TargetTestPrep

Target Test Prep

115 posts
3 Rich.C@EMPOWERgma...

EMPOWERgmat

111 posts
4 Scott@TargetTestPrep

Target Test Prep

101 posts
5 Max@Math Revolution

Math Revolution

87 posts
See More Top Beat The GMAT Experts


text:
## Statistical Science

### Fractionally Differenced Gegenbauer Processes with Long Memory: A Review

#### Abstract

The main objective of this paper is to review and promote the usefulness of generalized fractionally differenced Gegenbauer processes in time series and econometric research endeavours. In particular, theoretical and computational aspects centered around fractionally differenced Gegenbauer processes with long memory together with a number of interesting and elegant extensions will be discussed. In-depth conceptual developments and large scale simulation study results are presented for clarity and completeness. This survey highlights a number of gaps in the existing literature of this subject area and becomes a valuable reference source for time series practitioners.

#### Article information

Source
Statist. Sci., Volume 33, Number 3 (2018), 413-426.

Dates
First available in Project Euclid: 13 August 2018

https://projecteuclid.org/euclid.ss/1534147230

Digital Object Identifier
doi:10.1214/18-STS649

Mathematical Reviews number (MathSciNet)
MR3843383

Zentralblatt MATH identifier
06991127

#### Citation

Dissanayake, G. S.; Peiris, M. S.; Proietti, T. Fractionally Differenced Gegenbauer Processes with Long Memory: A Review. Statist. Sci. 33 (2018), no. 3, 413--426. doi:10.1214/18-STS649. https://projecteuclid.org/euclid.ss/1534147230

#### References

• Abrahams, M. and Dempster, A. (1979). Research on seasonal analysis. Progress report on the asa/census project on seasonal adjustment. Technical report. Dept. Statistics, Harvard Univ., Boston, MA.
• Anděl, J. (1986). Long memory time series models. Kybernetika (Prague) 22 105–123.
• Anderson, B. D. O. and Moore, J. B. (1979). Optimal Filtering. Prentice-Hall, New York.
• Anh, V. V., Angulo, J. M. and Ruiz-Medina, M. D. (1999). Possible long-range dependence in fractional random fields. J. Statist. Plann. Inference 80 95–110.
• Anh, V. V., Lunney, K. and Peiris, S. (1997). Stochastic models for characterisation and prediction of time series with long-range dependence and fractality. Environ. Model. Softw. 12 67–73.
• Aoki, M. (1990). State Space Modeling of Time Series, 2nd ed. Springer, Berlin.
• Arteche, J. (2007). The analysis of seasonal long memory: The case of Spanish inflation. Oxf. Bull. Econ. Stat. 69 749–772.
• Arteche, J. (2012). Standard and seasonal long memory in volatility: An application to Spanish inflation. Empir. Econ. 42 693–712.
• Arteche, J. and Robinson, P. M. (2000). Semiparametric inference in seasonal and cyclical long memory processes. J. Time Series Anal. 21 1–25.
• Baillie, R. T. (1996). Long memory processes and fractional integration in econometrics. J. Econometrics 73 5–59.
• Baillie, R. T., Bollerslev, T. and Mikkelsen, H. O. (1996). Fractionally integrated generalized autoregressive conditional heteroskedasticity. J. Econometrics 74 3–30.
• Beaumont, P. and Ramachandran, R. (2001). Robust estimation of GARMA model parameters with an application to cointegration among interest rates of industrialized countries. Comput. Econ. 17 179–201.
• Beran, J. (1992). Statistical methods for data with long-range dependence. Statist. Sci. 7 404–416.
• Beran, J. (1993). Fitting long-memory models by generalized linear regression. Biometrika 80 817–822.
• Beran, J. (1994). Statistics for Long-Memory Processes. Monographs on Statistics and Applied Probability 61. Chapman & Hall, New York.
• Beran, J., Feng, Y., Ghosh, S. and Kulik, R. (2013). Long-Memory Processes: Probabilistic Properties and Statistical Methods. Springer, Heidelberg.
• Bisognin, C. and Lopes, S. R. C. (2009). Properties of seasonal long memory processes. Math. Comput. Modelling 49 1837–1851.
• Bollerslev, T. (1986). Generalized autoregressive conditional heteroskedasticity. J. Econometrics 31 307–327.
• Box, G. E. P. and Jenkins, G. M. (1970). Times Series Analysis. Forecasting and Control. Holden-Day, San Francisco, CA.
• Brockwell, P. J. and Davis, R. A. (1991). Time Series: Theory and Methods, 2nd ed. Springer, New York.
• Brockwell, P. J. and Davis, R. A. (1996). Introduction to Time Series and Forecasting. Springer, New York.
• Chan, N. H. and Palma, W. (1998). State space modeling of long-memory processes. Ann. Statist. 26 719–740.
• Chan, N. H. and Palma, W. (2006). Estimation of long-memory time series models: A survey of different likelihood-based methods. Adv. Econom. 20 89–121.
• Chung, C.-F. (1996). A generalized fractionally integrated autoregressive moving-average process. J. Time Series Anal. 17 111–140.
• Corsi, F. (2009). A simple approximate long-memory model of realized volatility. J. Financ. Econom. 7 174–196.
• Dissanayake, G. S. and Peiris, M. S. (2011). Generalized fractional processes with conditional heteroskedasticity. Sri Lankan J. Appl. Stat. 12 1–12.
• Dissanayake, G. S., Peiris, M. S. and Proietti, T. (2014). Estimation of generalized fractionally differenced processes with conditionally heteroskedastic errors. In International Work Conference on Time Series, Proceedings ITISE 2014 (I. R. Ruiz and G. R. Garcia, eds.). Copicentro Granada S L 871–890.
• Dissanayake, G. S., Peiris, M. S. and Proietti, T. (2015). State space modeling of seasonal Gegenbauer processes with long memory. Working Paper, School of Mathematics and Statistics, Univ. Sydney, Australia.
• Dissanayake, G. S., Peiris, M. S. and Proietti, T. (2016). State space modeling of Gegenbauer processes with long memory. Comput. Statist. Data Anal. 100 115–130.
• Dissanayake, G. S., Peiris, M. S., Proietti, T. and Wang, Q. (2015). Nearly efficient testing and asymptotics of a long memory $\operatorname{GARMA}(0,\delta,0)$ process, Working Paper, School of Mathematics and Statistics, Univ. Sydney, Australia.
• Dolado, J. J., Gonzalo, J. and Mayoral, L. (2002). A fractional Dickey–Fuller test for unit roots. Econometrica 70 1963–2006.
• Durbin, J. and Koopman, S. J. (2001). Time Series Analysis by State Space Methods. Oxford Statistical Science Series 24. Oxford Univ. Press, Oxford.
• Engle, R. F. (1982). Autoregressive conditional heteroscedasticity with estimates of the variance of United Kingdom inflation. Econometrica 50 987–1007.
• Erdelyi, A., Magnus, W., Oberhettinger, F. and Tricomi, F. G. (1953). Higher Transcendental Functions, Vol. II, Bateman Manuscript Project. McGraw-Hill. New York.
• Ferrara, L. and Guegan, D. (2001). Forecasting with k-factor Gegenbauer processes: Theory and applications. J. Forecast. 20 581–601.
• Ferrara, L., Guegan, D. and Lu, Z. (2010). Testing fractional order of long memory processes: A Monte Carlo study. Comm. Statist. Simulation Comput. 39 795–806.
• Giraitis, L., Hidalgo, J. and Robinson, P. M. (2001). Gaussian estimation of parametric spectral density with unknown pole. Ann. Statist. 29 987–1023.
• Giraitis, L., Koul, H. L. and Surgailis, D. (2012). Large Sample Inference for Long Memory Processes. Imperial College Press, London.
• Giraitis, L. and Leipus, R. (1995). A generalized fractionally differencing approach in long-memory modeling. Liet. Mat. Rink. 35 65–81.
• Gonçalves, E. (1987). Une généralisation des processus ARMA. Ann. Écon. Stat. 5 109–145.
• Gould, H. W. (1974). Coefficient identities for powers of Taylor and Dirichlet series. Amer. Math. Monthly 81 3–14.
• Gradshteyn, I. S. and Ryzhik, I. M. (1980). Tables of Integrals Series and Products. Academic Press, New York.
• Granger, C. W. J. and Joyeux, R. (1980). An introduction to long-memory time series models and fractional differencing. J. Time Series Anal. 1 15–29.
• Grassi, S. and Santucci de Magistris, P. (2014). When long memory meets the Kalman filter: A comparative study. Comput. Statist. Data Anal. 76 301–319.
• Gray, H. L., Zhang, N.-F. and Woodward, W. A. (1989). On generalized fractional processes. J. Time Series Anal. 10 233–257.
• Gray, H. L., Zhang, N.-F. and Woodward, W. A. (1994). A correction: “On generalized fractional processes” [J. Time Ser. Anal. 10 (1989), no. 3, 233–257; MR1028940 (90m:62208)]. J. Time Series Anal. 15 561–562.
• Guegan, D. (2000). A new model: The k-factor GIGARCH process. J. Signal Process. 4 265–271.
• Guégan, D. (2005). How can we define the concept of long memory? An econometric survey. Econometric Rev. 24 113–149.
• Harvey, A. C. (1989). Forecasting, Structural Time Series Models and the Kalman Filter. Cambridge Univ. Press, Cambridge.
• Harvey, A. C. and Proietti, T., eds. (2005). Readings in Unobserved Components Models. Oxford Univ. Press, Oxford.
• Hassler, U. (1994). (Mis)specification of long memory in seasonal time series. J. Time Series Anal. 15 19–30.
• Hassler, U. and Wolters, J. (1994). On the power of unit root tests against fractional alternatives. Econom. Lett. 45 1–5.
• Hassler, U. and Wolters, J. (1995). Long memory in inflation rates: International evidence. J. Bus. Econom. Statist. 13 37–45.
• Hosking, J. R. M. (1981). Fractional differencing. Biometrika 68 165–176.
• Hsu, N.-J. and Tsai, H. (2009). Semiparametric estimation for seasonal long-memory time series using generalized exponential models. J. Statist. Plann. Inference 139 1992–2009.
• Jansson, M. and Nielsen, M. Ø. (2012). Nearly efficient likelihood ratio tests of the unit root hypothesis. Econometrica 80 2321–2332.
• Kalman, R. E. (1961). A new approach to linear filtering and prediction problems. Trans. Am. Soc. Mech. Eng. 83D 35–45.
• Kalman, R. E. and Bucy, R. S. (1961). New results in linear filtering and prediction theory. Trans. Am. Soc. Mech. Eng. 83 95–108.
• Koopman, S. J., Ooms, M. and Carnero, M. A. (2007). Periodic seasonal Reg-ARFIMA-GARCH models for daily electricity spot prices. J. Amer. Statist. Assoc. 102 16–27.
• Lieberman, O. and Phillips, P. C. B. (2008). Refined inference on long memory in realized volatility. Econometric Rev. 27 254–267.
• Ling, S. and Li, W. K. (1997). On fractionally integrated autoregressive moving-average time series models with conditional heteroscedasticity. J. Amer. Statist. Assoc. 92 1184–1194.
• Lobato, I. N. and Savin, N. E. (1998). Real and spurious long-memory properties of stock-market data. J. Bus. Econom. Statist. 16 261–283.
• Lu, Z. and Guegan, D. (2011). Estimation of time-varying long memory parameter using wavelet method. Comm. Statist. Simulation Comput. 40 596–613.
• McAleer, M. and Medeiros, M. C. (2008). A multiple regime smooth transition heterogeneous autoregressive model for long memory and asymmetries. J. Econometrics 147 104–119.
• Montanari, A., Rosso, R. and Taqqu, M. S. (2000). A seasonal fractional ARIMA modelapplied to Nile river monthly flows at Aswan. Water Resour. Res. 36 1249–1259.
• Ohanissian, A., Russell, J. R. and Tsay, R. S. (2008). True or spurious long memory? A new test. J. Bus. Econom. Statist. 26 161–175.
• Ooms, M. (1995). Flexible seasonal long memory and economic time series. Technical Report EI-9515/A. Econometric Institute, Erasmus Univ., Rotterdam.
• Oppenheim, G. and Viano, M.-C. (2004). Aggregation of random parameters Ornstein–Uhlenbeck or AR processes: Some convergence results. J. Time Series Anal. 25 335–350.
• Palma, W. (2007). Long-Memory Time Series: Theory and Methods. Wiley-Interscience, Hoboken, NJ.
• Palma, W. and Chan, N. H. (2005). Efficient estimation of seasonal long-range-dependent processes. J. Time Series Anal. 26 863–892.
• Pearlman, J. G. (1980). An algorithm for the exact likelihood of a high-order autoregressive–moving average process. Biometrika 67 232–233.
• Peiris, M. S. (2003). Improving the quality of forecasting using generalized AR models: An application to statistical quality control. Stat. Methods 5 156–171.
• Peiris, S., Allen, D. and Peiris, U. (2005). Generalized autoregressive models with conditional heteroscedasticity: An application to financial time series modeling. In Proceedings of the Workshop on Research Methods: Statistics and Finance 75–83.
• Peiris, S. and Asai, M. (2016). Generalized fractional processes with long memory and time dependent volatility revisited. Econometrics 4 37.
• Peiris, S. and Thavaneswaran, A. (2007). An introduction to volatility models with indices. Appl. Math. Lett. 20 177–182.
• Phillips, P. C. B. and Xiao, Z. (1998). A primer on unit root testing. J. Econ. Surv. 12 423–470.
• Porter-Hudak, S. (1990). An application of the seasonal fractionally differenced model to the monetary aggregates. J. Amer. Statist. Assoc. 85 338–344.
• Rainville, E. D. (1960). Special Functions. The Macmillan Co., New York.
• Ray, B. K. (1993). Modeling long-memory processes for optimal long-range prediction. J. Time Series Anal. 14 511–525.
• Reisen, V. A., Rodrigues, A. L. and Palma, W. (2006). Estimation of seasonal fractionally integrated processes. Comput. Statist. Data Anal. 50 568–582.
• Robinson, P. M. (1991). Testing for strong serial correlation and dynamic conditional heteroskedasticity in multiple regression. J. Econometrics 47 67–84.
• Shephard, N. (1996). Statistical aspects of ARCH and stochastic volatility. In Time Series Models: In Econometrics, Finance and Other Fields (D. R. Cox, D. B. Hinkley, and O. E. Barndorff-Nielsen, eds.), Chapman & Hall, London.
• Shitan, M. and Peiris, S. (2008). Generalized autoregressive (GAR) model: A comparison of maximum likelihood and Whittle estimation procedures using a simulation study. Comm. Statist. Simulation Comput. 37 560–570.
• Shitan, M. and Peiris, S. (2009). On properties of the second order generalized autoregressive $\operatorname{GAR}(2)$ model with index. Math. Comput. Simulation 80 367–377.
• Shitan, M. and Peiris, S. (2013). Approximate asymptotic variance–covariance matrix for the Whittle estimators of $\operatorname{GAR}(1)$ parameters. Comm. Statist. Theory Methods 42 756–770.
• Slutsky, E. (1927). The summation of random causes as the source of cyclic processes. Econometrica 5 105–146.
• Spolia, S. K., Chandler, S. and O’Connor, K. M. (1980). An autocorrelation approach for parameter estimation of fractional order equal-root autoregressive models using hypergeometric functions. J. Hydrol. 47 1–18.
• Taylor, A. M. R. (2005). Fluctuation tests for a change in persistence. Oxf. Bull. Econ. Stat. 67 207–230.
• Velasco, C. and Robinson, P. M. (2000). Whittle pseudo-maximum likelihood estimation for nonstationary time series. J. Amer. Statist. Assoc. 95 1229–1243.
• Wang, Q., Lin, Y.-X. and Gulati, C. M. (2003). Asymptotics for general fractionally integrated processes with applications to unit root tests. Econometric Theory 19 143–164.
• Woodward, W. A., Cheng, Q. C. and Gray, H. L. (1998). A $k$-factor GARMA long-memory model. J. Time Series Anal. 19 485–504.
• Yule, G. U. (1926). Why do we sometimes get nonsense-correlations between time-series?—A study in sampling and the nature of time-series. J. Roy. Statist. Soc. 89 1–63.


text:
# The Physics Behind the American Death Triangle [closed]

I've heard a lot about the American Death Triangle and how it is awful for belaying. The Death Triangle is set up as such: you have two anchor points with a single rope or line running through both points. The rope then connects to a single harness at both ends.

The anchors don't act like a single fastening point, but instead a bit like pulleys in that they redirect the force. The lines do not stop on the anchors. As such, while the force is evenly distributed between the anchors, it is magnified because there is the force of the weight as well as the force of the tension between the anchors. The equation for each anchor is given by

$$F = \frac{W}{\cos\left(45 ^\circ + \frac{1}{4} \theta\right)}$$

Where $\theta$ is the angle of the bottom of the triangle. The equation came from Wikipedia, but what I don't understand is how they derived this equation. It has no sources nor explanation nor proof. Can walk me through the proof of this equation?

## closed as off-topic by CuriousOne, ACuriousMind♦, Kyle Kanos, Bill N, John RennieMar 23 '16 at 6:34

This question appears to be off-topic. The users who voted to close gave this specific reason:

• "Homework-like questions should ask about a specific physics concept and show some effort to work through the problem. We want our questions to be useful to the broader community, and to future users. See our meta site for more guidance on how to edit your question to make it better" – CuriousOne, ACuriousMind, Kyle Kanos, Bill N, John Rennie
If this question can be reworded to fit the rules in the help center, please edit the question.

This is a great example of elementary physics concepts, which perhaps due to my lack of skill bring in some rather inelegant mathematics. The whole concept can be explained with a free body diagram.

First, let's derive the first expression they give on the wikipedia page for a "V" formation. This is perhaps a classic freshman physics problem with free diagrams; because it is simple enough to do, but challenging enough for a freshman not to simply guess the answer. Below I have drawn the two situations on the same graphic. For the "V" formation, consider there is only rope where the blue lines are. Then for the death triangle, add rope across the orange line. The situation as described is an isosceles triangle, with two interior angles $\phi$ and $\theta$. The circles are the anchors (assumed massless), and the square is the load of mass $m$.

Now write out all the forces for each case, and solve the system of equations.

# "V" formation

On the anchor there are two forces: i) from the tension in the rope due to the object (pointing along the blue line), and ii) the rock it is wedged in providing the necessary force to hold the anchor in place. We wish to solve for the force the rock needs to apply to the anchor to hold it in place, i.e., the sum of the two forces is 0 (thus the force from the rock, $F_\textrm{rock}$, equivalent to $F_{Anchor}$ in wikipedia notation, points equal and opposite to the tension). We therefore just need to solve for the tension, $T$, which is most easily done from the free body diagram of the load.

The load has three forces acting on it:

• gravity,

• the tension from the left anchor,

• the tension from the right anchor.

Now this is a 2 dimensional problem, so let's break down the force equations by components. Looking at the $x$ component

$$\left( \sum_{i} \vec{F}_i \right)_x = -T_{\textrm{left}} \sin\left(\frac{\theta}{2}\right) + T_{\textrm{right}} \sin\left(\frac{\theta}{2}\right) = 0.$$

Therefore we see that $T_{\textrm{left}}=T_{\textrm{right}}$, which I will now just call $T$. This is what you would expect from the symmetry of the problem. Now the $y$ component says,

$$\left( \sum_{i} \vec{F}_i \right)_y = -mg + T \cos\left(\frac{\theta}{2}\right) + T \cos\left(\frac{\theta}{2}\right) = 0.$$

Thus we have arrived at $$T = \frac{mg}{2 \cos\left(\frac{\theta}{2}\right)}.$$

As already stated the magnitude of the force the rock exerts, is equal to the tension; therefore, this tension is the our answer for $F_\textrm{rock}$.

Note to make the math simpler in the next section that $\cos(x) = \sin(\pi/2 - x)$, and that $2\phi = \pi - \theta$, therefore $\cos(\theta/2) = \sin(\phi)$ (this is obvious if you split the triangle into two right triangles by bisecting $\theta$).

# Death Triangle

Now we include the orange bit of rope, such that it is all connected together. Similar to the "V" formation, we wish to solve for the force that the rock exerts on the anchor to keep it in place. Again this force will be equal and opposite of all other force, such that the net force sums to zero. However, this time the anchor feels three forces:

• tension from the rope attached to the load,

• tension from the rope attached to the other anchor,

• the keeping force of the rock. Note this time that the keeping force of the rock is not along the triangle, since it must balance out both (i) and (ii).

Since the anchors act like pulleys you know that they just redirect the force, without modification. Thus the tension the anchor feels from the other anchor is equal to the tension it feels from the object. Therefore we will call all tension forces simply $T$. An intuitive way of seeing this is a counter-example. Consider the two forces were not equal, then the side of the rope with the bigger force would pull the other rope towards it. We know that these ropes are at rest, thus we intuitively know these forces must be equal. With this in mind we write the $x$ component of the force equations as

$$\left( \sum_{i} \vec{F}_i \right)_x = T + T \cos\left(\phi\right) - F_x = 0.$$

Where $F_x = F_\textrm{rock} \cos(\phi')$, where $\phi'$ is the angle $\vec{F}_{rock}$ makes with the $x$-axis. I will not worry too much about it since we will use both equations to replace it with known variables. Therefore we move onto the $y$-component

$$\left( \sum_{i} \vec{F}_i \right)_y = T \sin\left(\phi\right) - F_y = 0.$$

Where again similarly $F_y = F_\textrm{rock} \sin(\phi')$. Thus setting these equations equal to each other and solving for $\phi'$ in terms of $\phi$

$$\phi' = \arctan\left( \frac{\sin(\phi)}{1+\cos(\phi)}\right).$$

Now we can solve for $F_{rock}$ by rewriting the $y$-equation as

$$F_\textrm{rock} = T \frac{\sin(\phi)}{\sin(\phi')}.$$

Now we know $T$ from doing the "V" formation, and recall at the end we noted how to rewrite it in terms of $\sin(\phi)$, which now cancel out giving us

$$F_\textrm{rock} = \frac{mg}{2\sin(\phi')}.$$

This is the exact same form of the equation as the "V" formation, just with $\phi$ and $\phi'$ switched! Now $\sin\left( \arctan\left( \frac{\sin(\phi)}{1+\cos(\phi)}\right) \right)$, is a slightly unsightly sight. But if you only consider, $0 \leq \theta \leq \pi$, as your range for $\theta$, which are limits of a triangle, then it simplifies to to $\sin\left(\frac{\phi}{2}\right)$. Now recalling that $2\phi = \pi - \theta$, then we can rewrite that as $\cos\left(\frac{\pi}{4} + \frac{\theta}{4}\right)$. Thus we have indeed arrived at

$$F_\textrm{rock} = \frac{mg}{2\cos\left(\frac{\pi}{4} + \frac{\theta}{4}\right)}.$$

I haven't spent much time trying to make the math elegant, but you can see the agreement, which leads us to believe we have included all the physics in which the wikipedia article has.

# Conclusion

As noted in the wikipedia, this formation is less effective at minimizing $F_\textrm{rock}$. The "V" formation, best case scenario of $\theta = 0$, halves weight; while for the death triangle you only get $\sqrt{2}/2$. Therefore, for safety reasons, where you want to put the smallest amount of weight on an anchor, it is advised to not use this method of anchoring (on top of apparently violating other tenants of climbing, e.g., redundancy).

• Just a small remark on the "V formation". It is plausible to assume that $T_\mathrm{left}=T_\mathrm{right}$ since your lower point has no friction. What your $x$ equation there actually proves is that $\theta=\theta'$: your forces are in an equilateral triangle. – Nick Jun 9 '16 at 6:56


text:
# Prediction Interval Calculator for a Regression Prediction

Instructions: Use this prediction interval calculator for the mean response of a regression prediction. Please input the data for the independent variable $$(X)$$ and the dependent variable ($$Y$$), the confidence level and the X-value for the prediction, in the form below:

Independent variable $$X$$ sample data (comma or space separated) =
Dependent variable $$Y$$ sample data (comma or space separated) =
Confidence Level (Ex: 0.95, 95, 99, 99%) =
X value for prediction $$X_0$$ =
Independent variable Name (optional) =
Dependent variable Name (optional) =

#### Prediction Interval for the Mean Response

The Prediction Interval for an individual predictione corresponds to the calculated confidence interval for the individual predicted response $$\hat{Y}_0$$ for a given value $$X = X_0$$. First, we need to know the mean squared error:

$\hat{\sigma}^2 = \displaystyle \frac{SSE}{n-2}$

Then, the $$1-\alpha)\times 100$$% confidence interval for the the individual prediction $$\hat{Y}_0$$ is

$CI = \displaystyle \left( \hat{Y}_0 - t_{\alpha/2; n-2} \sqrt{ \hat{\sigma}^2 \left(1 + \frac{1}{n} + \frac{\left(X_0 - \bar X\right)^2}{SS_{XX}}\right) },\hat{Y}_0 + t_{\alpha/2; n-2} \sqrt{ \hat{\sigma}^2 \left(1+ \frac{1}{n} + \frac{\left(X_0 - \bar X\right)^2}{SS_{XX}}\right) } \right)$

If you are interested rather in a confidence interval for the mean response, please use instead this confidence interval calculator for regression predictions.

In case you have any suggestion, or if you would like to report a broken solver/calculator, please do not hesitate to contact us.

Back to
log in