class IndexEquationSolver extends ExpressionEquationIndexifier
Seek an approximately stable distribution for equations given in terms of indices, hence solving the equations (approximately). Here stable distribution is under the iteration to solve equations viewing them as fixed points. A few quantitites related to the solutions, or the equations themselves, are also computed.
- Alphabetic
- By Inheritance
- IndexEquationSolver
- ExpressionEquationIndexifier
- AnyRef
- Any
- by any2stringadd
- by StringFormat
- by Ensuring
- by ArrowAssoc
- Hide All
- Show All
- Public
- Protected
Instance Constructors
- new IndexEquationSolver(initMap: Map[Expression, Double], equationVec: Vector[Equation], params: (Coeff[_]) => Option[Double], maxRatio: Double, resolution: Double, exponent: Double, decay: Double, maxTime: Option[Long], previousMap: Option[Map[Expression, Double]])
- initMap
initial values of some expressions
- params
values of coefficients in the equations
- maxRatio
bound on ratio of stabilization
- resolution
additive scale for stabilization and some auxiliary quantities
- exponent
the next step is stabilized using geometric means, weighted by the exponent
- decay
decay of the exponent, to allow steps to be damped progressively more
- maxTime
time in milliseconds for timing out stabilizations
- previousMap
an optional previous map to initialize
Value Members
- def bigRatio(v: Vector[Double], w: Vector[Double], bound: Double = maxRatio): Vector[((Double, Double), Int)]
- lazy val constantEquations: Set[Int]
- Definition Classes
- ExpressionEquationIndexifier
- def equalSupport(v: Vector[Double], w: Vector[Double]): Boolean
- def equationGradients(v: ParSeq[Double]): ParVector[ParVector[Double]]
- Definition Classes
- ExpressionEquationIndexifier
- val equationVec: Vector[Equation]
- Definition Classes
- ExpressionEquationIndexifier
- lazy val finalMap: Map[Expression, Double]
values of expressions in an approximately stable solution to the equation
values of expressions in an approximately stable solution to the equation
- returns
map of approximate solution values
- lazy val finalVec: ParVector[Double]
vector of values (at indices) in an approximately stable solution to the equation
vector of values (at indices) in an approximately stable solution to the equation
- returns
vector of approximate solution values
- def getProd(exp: Expression): ProductIndexExpression
- Definition Classes
- ExpressionEquationIndexifier
- def gradient(index: Int, decay: Double = 1.0, depth: Int): Vector[(Int, Double)]
- def gradientNextStep(predecessor: Vector[(Int, Double)]): Vector[(Int, Double)]
- def gradientStep(index: Int): Vector[(Int, Double)]
- val gradientTerms: Vector[ArrayBuffer[Vector[(Int, Double)]]]
- def gradientUptoMemo(j: Int, depth: Int): Vector[Vector[(Int, Double)]]
- lazy val indexMap: Map[Expression, Int]
- Definition Classes
- ExpressionEquationIndexifier
- lazy val initPar: ParMap[Expression, Double]
- Definition Classes
- ExpressionEquationIndexifier
- lazy val initTermIndices: Vector[Int]
- Definition Classes
- ExpressionEquationIndexifier
- lazy val initTypIndices: Vector[Int]
- Definition Classes
- ExpressionEquationIndexifier
- lazy val initVector: ParVector[Double]
- def mapToIndexMap[V](m: Map[Expression, V]): Map[Int, V]
- Definition Classes
- ExpressionEquationIndexifier
- def nextTraceSet(current: Set[Set[Int]], relativeTo: Set[Int]): Set[Set[Int]]
- Definition Classes
- ExpressionEquationIndexifier
- def nextTraceVector(current: Vector[Vector[Int]]): Vector[Vector[Int]]
- Definition Classes
- ExpressionEquationIndexifier
- def nextVec(v: ParVector[Double], exponent: Double): ParVector[Double]
- def normalizedBounded(v: Vector[Double], w: Vector[Double], report: Boolean = false): Boolean
- val numVars: Int
- Definition Classes
- ExpressionEquationIndexifier
- def orthonormalGradients(v: ParSeq[Double], cutoff: Double = 0.0): ParVector[ParVector[Double]]
- Definition Classes
- ExpressionEquationIndexifier
- def proofData(typ: Typ[Term]): Vector[(Int, Equation)]
- Definition Classes
- ExpressionEquationIndexifier
- lazy val randomVarIndices: ParVector[Vector[Int]]
- Definition Classes
- ExpressionEquationIndexifier
- def ratioBounded(v: Vector[Double], w: Vector[Double], bound: Double = maxRatio): Boolean
- final def recTraceSet(current: Set[Set[Int]], depth: Int, relativeTo: Set[Int], accum: Set[Set[Int]]): Set[Set[Int]]
- Definition Classes
- ExpressionEquationIndexifier
- Annotations
- @tailrec()
- def restrict(v: Vector[Double], indices: Vector[Int]): Vector[Double]
- lazy val rhsExprs: Vector[SumIndexExpression]
- Definition Classes
- ExpressionEquationIndexifier
- lazy val rhsExprsPar: ParVector[SumIndexExpression]
- Definition Classes
- ExpressionEquationIndexifier
- def rhsInvolves(js: Set[Int]): Set[Int]
- Definition Classes
- ExpressionEquationIndexifier
- def simpleNextVec(v: ParVector[Double]): ParVector[Double]
- def simplify(exp: Expression): SumIndexExpression
- Definition Classes
- ExpressionEquationIndexifier
- lazy val size: Int
- Definition Classes
- ExpressionEquationIndexifier
- final def stableSupportVec(initVec: ParVector[Double], maxTime: Option[Long], steps: Long): ParVector[Double]
- Annotations
- @tailrec()
- final def stableVec(initVec: ParVector[Double], exponent: Double = 0.5, decay: Double, maxTime: Option[Long], steps: Long): ParVector[Double]
- Annotations
- @tailrec()
- lazy val termIndexVec: Vector[(Term, Int)]
- Definition Classes
- ExpressionEquationIndexifier
- lazy val termIndices: Vector[Int]
- Definition Classes
- ExpressionEquationIndexifier
- lazy val thmPfIndices: Map[Int, Vector[Int]]
- Definition Classes
- ExpressionEquationIndexifier
- lazy val totalProbEquations: ParVector[ParVector[Double]]
- Definition Classes
- ExpressionEquationIndexifier
- def traceIndices(j: Int, depth: Int): Vector[Int]
- Definition Classes
- ExpressionEquationIndexifier
- def traceSet(elem: Expression, depth: Int, relativeTo: Set[Int]): Set[Set[Int]]
- Definition Classes
- ExpressionEquationIndexifier
- def track(exp: Expression): Option[(Int, Double, SumIndexExpression, Double, Vector[Double])]
- def trackOutput(exp: Expression): String
- lazy val typIndexVec: Vector[(Typ[Term], Int)]
- Definition Classes
- ExpressionEquationIndexifier
- lazy val typIndices: Vector[Int]
- Definition Classes
- ExpressionEquationIndexifier
- lazy val varVec: Vector[Expression]
- Definition Classes
- ExpressionEquationIndexifier