RelativeEquilibriumOrbitKS

Overview

class orbithunter.RelativeEquilibriumOrbitKS(state=None, basis=None, parameters=None, discretization=None, constraints=None, frame='comoving', **kwargs)[source]

Methods

Note

See also Orbit, OrbitKS and RelativeOrbitKS.

Initialization

RelativeEquilibriumOrbitKS.__init__([state, …])

Same as OrbitKS except for setting the ‘frame’ attribute.

RelativeEquilibriumOrbitKS.populate([attr])

Randomly initialize parameters which are currently zero.

RelativeEquilibriumOrbitKS._populate_state(…)

Initialize a set of random spatiotemporal Fourier modes

RelativeEquilibriumOrbitKS._populate_parameters(…)

Should only be accessed through Orbit.populate()

Special Methods

“Special” methods also known as “magic” or “dunder” (double underscore) methods account for most basic Math operations and other operations pertaining to NumPy arrays.

Note

See Orbit for all definitions.

Properties

RelativeEquilibriumOrbitKS.shape

Current state array’s shape

RelativeEquilibriumOrbitKS.size

Current state array’s dimensionality

RelativeEquilibriumOrbitKS.ndim

Current state array’s number of dimensions

Discretization and Dimensions

RelativeEquilibriumOrbitKS.shapes()

State array shapes in different bases.

RelativeEquilibriumOrbitKS.dimensions()

Tile dimensions.

RelativeEquilibriumOrbitKS.glue_dimensions(…)

Strategy for combining tile dimensions in gluing; default is arithmetic averaging.

RelativeEquilibriumOrbitKS.dimension_based_discretization(…)

Subclassed method for equilibria.

RelativeEquilibriumOrbitKS.plotting_dimensions()

Dimensions according to plot labels; used in clipping.

Math Functions

RelativeEquilibriumOrbitKS.orbit_vector()

Vector representation of Orbit instance; constants all variables required to define the Orbit instance.

RelativeEquilibriumOrbitKS.abs()

Orbit instance with absolute value of state.

RelativeEquilibriumOrbitKS.dot(other)

Return the L_2 inner product of two orbits

RelativeEquilibriumOrbitKS.norm([order])

Norm of spatiotemporal state via numpy.linalg.norm

RelativeEquilibriumOrbitKS.dx(**kwargs)

Spatial derivative of the current state.

RelativeEquilibriumOrbitKS.dt([order, array])

A time derivative of the current state.

RelativeEquilibriumOrbitKS.eqn(**kwargs)

Instance whose state is the Kuramoto-Sivashinsky equation evaluated at the current state

RelativeEquilibriumOrbitKS.matvec(other, …)

Extension of parent class method

RelativeEquilibriumOrbitKS.rmatvec(other, …)

Matrix-vector product with the adjoint of the Jacobian

RelativeEquilibriumOrbitKS.precondition(**kwargs)

Rescale a vector with the inverse (absolute value) of linear spatial terms

RelativeEquilibriumOrbitKS.jacobian(**kwargs)

Jacobian matrix evaluated at the current state.

RelativeEquilibriumOrbitKS.calculate_spatial_shift(…)

Calculate the phase difference between the spatial modes at t=0 and t=T

Visualization

RelativeEquilibriumOrbitKS.plot([show, …])

Plot the velocity field as a 2-d density plot using matplotlib’s imshow

RelativeEquilibriumOrbitKS.mode_plot([show, …])

Plot the spatiotemporal Fourier spectrum as a 2-d density plot using matplotlib’s imshow

State Transformations

RelativeEquilibriumOrbitKS.transform([to, …])

Transform current state to a different basis.

RelativeEquilibriumOrbitKS.resize(…)

Rediscretize the current state typically via zero padding or interpolation.

RelativeEquilibriumOrbitKS.reflection([…])

Reflect the velocity field about the spatial midpoint

RelativeEquilibriumOrbitKS.roll(shift[, axis])

Apply numpy roll along specified axis.

RelativeEquilibriumOrbitKS.cell_shift(n_cell)

Rotate by fraction of the period in either axis; nearest discrete approximate is taken.

RelativeEquilibriumOrbitKS.rotate(distance)

Rotate the velocity field in either space or time.

RelativeEquilibriumOrbitKS.shift_reflection()

Return a OrbitKS with shift-reflected velocity field

RelativeEquilibriumOrbitKS.to_fundamental_domain()

Placeholder/signature for possible symmetry subclasses.

RelativeEquilibriumOrbitKS.from_fundamental_domain()

For compatibility purposes with plotting and other utilities

RelativeEquilibriumOrbitKS.change_reference_frame(frame)

Transform to (or from) the co-moving frame depending on the current reference frame

RelativeEquilibriumOrbitKS._pad(size[, axis])

Overwrite of parent method

RelativeEquilibriumOrbitKS._truncate(size[, …])

Subclassed method to handle RelativeEquilibriumOrbitKS mode’s shape.

Static

RelativeEquilibriumOrbitKS.bases_labels()

Labels of the different bases produced by transforms.

RelativeEquilibriumOrbitKS.minimal_shape()

The smallest possible compatible discretization

RelativeEquilibriumOrbitKS.minimal_shape_increments()

The smallest valid increment to change the discretization by.

RelativeEquilibriumOrbitKS.discretization_labels()

Strings to use to label dimensions/periods

RelativeEquilibriumOrbitKS.parameter_labels()

Labels of all parameters

RelativeEquilibriumOrbitKS.dimension_labels()

Strings to use to label dimensions/periods.

RelativeEquilibriumOrbitKS.positive_indexing()

Indicates whether numpy indexing corresponds to increasing or decreasing values configuration space variable

Other

RelativeEquilibriumOrbitKS.periodic_dimensions() is not ‘static’, unlike its parent; this is due to unavoidable symmetry specific considerations. For this reason, the staticmethod decorator was not used.

RelativeEquilibriumOrbitKS.copy()

Return an instance with copies of copy-able attributes.

RelativeEquilibriumOrbitKS.mask(masking_array)

Return an Orbit instance with a numpy masked array state

RelativeEquilibriumOrbitKS.constrain(*labels)

Set self constraints based on labels provided.

RelativeEquilibriumOrbitKS.preprocess()

Check whether the orbit converged to an equilibrium or close-to-zero solution

RelativeEquilibriumOrbitKS.periodic_dimensions()

Bools indicating whether or not dimension is periodic for persistent homology calculations.

Defaults

RelativeEquilibriumOrbitKS.defaults()

Dict of default values for constraints, parameter ranges, sizes, etc.

RelativeEquilibriumOrbitKS._default_shape()

The default array shape when dimensions are not specified.

RelativeEquilibriumOrbitKS._default_parameter_ranges()

Default parameter ranges.

RelativeEquilibriumOrbitKS._default_constraints()

Defaults for whether or not parameters are constrained.

Reading and Writing Data

RelativeEquilibriumOrbitKS.filename([…])

Method for convenience and consistent/conventional file naming.

RelativeEquilibriumOrbitKS.to_h5([filename, …])

Export current state information to HDF5 file.