Branched

com.phasmidsoftware.number.algebra.core.Branched
trait Branched[T]

Trait representing something that can branch into multiple branches.

Type parameters

T

the type of the elements contained in the branches.

Attributes

Graph
Supertypes
class Object
trait Matchable
class Any
Known subtypes
trait Equation
trait Root
class AbstractRoot
class LinearRoot
Show all

Members list

Value members

Abstract methods

def branched(index: Int): T

Retrieves the branch at the specified index.

Retrieves the branch at the specified index.

Value parameters

index

the index of the branch to retrieve, where the index starts from 0.

Attributes

Returns

the element of type T at the specified branch index. If the index is out of range, the behavior is implementation-specific.

def branches: Int

Returns the number of branches in this.

Returns the number of branches in this.

branches corresponds to the number of possible solutions to some equation.

Attributes

Returns

the number of branches as an integer.