partial

package
v0.0.0-...-1420a53 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 29, 2022 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type State

type State struct {
	Dimension              int                      // The dimension of the ambient space.
	Lattice                *integervector.Parent    // The lattice ZZ^dimension.
	Vertices               []*integervector.Element // The vertices of the polytope, as a slice of integer vectors.
	Facets                 [][]int                  // The facets of the polytope, where facets[i] is the slice containing the indices of vertices in the i-th facet.
	Normals                []*integervector.Element // The outward pointing normals to the facets.
	NeighbouringFacets     []map[int]int            // NeighbouringFacets[fid] is a map recording the facets that are known to neighbour the facet F with index fid. neighbouringFacets[fid][vid] records the facet id of the facet adjacent to F along the ridge of F specified by the vertex with index vid.
	Basechanges            []matrix.Matrix          // Basechanges[fid] is the change of basis matrix that maps the vertices of the facet F to the standard basis elements.
	NeighbouringVertices   map[int]int              // This specifies the neighbouring vertices to the initial (standard) facet. FIX ME am not exactly sure how yet.
	NeighboursInHyperplane []*integer.Element       // FIX ME I think this specifies which hyperplanes the vertices adjacent to the standard facet are in.
	ResumeFromHeight       *integer.Element         // The height from which to resume the search for the next vertex. If this is nil, we resume at the maximum possible height.
	ResumeFrom             *integervector.Element   // The place to resume the search for the next vertex. If this is nil, we resume at the lower bound.
	HasClosed              bool                     // True if and only if we have successfully closed the vertices of this state to a smooth Fano polytope.
}

State describes the data associated with a partially constructed polytope.

func FromRecord

func FromRecord(r record.Record) (*State, error)

FromRecord returns the partial state data represented by the given record. The record must have key:value entries:

"encodedState": []byte	// Gob-encoded data describing the state
"hasClosed":    bool	// Does this close to give a polytope?

func Initial

func Initial(d int) (*State, error)

Initial returns the initial state for the search in dimension d.

func (*State) Copy

func (s *State) Copy() *State

Copy returns a copy of s.

func (*State) Delete

func (s *State) Delete()

Delete makes s available for future reuse. You must not modify s after calling Delete.

func (*State) Reset

func (s *State) Reset() *State

Reset resets s ready for reuse. Returns s.

func (*State) String

func (s *State) String() string

String returns a string description of the state.

func (*State) ToRecord

func (s *State) ToRecord() (record.Record, error)

ToRecord returns a record representing the partial state data. The returned record will have key:value entries:

"encodedState": []byte	// Gob-encoded data describing the state
"hasClosed":    bool	// Does this close to give a polytope?

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL