class NewtonInterpolation extends Tracing
Implements Newtons interpolation algorithm. All calculations will be carried out by finite field algebra.
- Alphabetic
- By Inheritance
- NewtonInterpolation
- Tracing
- AnyRef
- Any
- Hide All
- Show All
- Public
- Protected
Instance Constructors
- new NewtonInterpolation(supportingPoints: IndexedSeq[(BigInt, BigInt)], prime: BigInt)
Creates a new NewtonInterpolation by applying some supporting points and a prime number.
Creates a new NewtonInterpolation by applying some supporting points and a prime number.
- supportingPoints
some pairwise different supporting points
- prime
a prime number
Value Members
- final def !=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def ##: Int
- Definition Classes
- AnyRef → Any
- final def ==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def asInstanceOf[T0]: T0
- Definition Classes
- Any
- def clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.CloneNotSupportedException]) @native() @IntrinsicCandidate()
- def computeCoefficients(): IndexedSeq[BigInt]
Supporting points := (x(0), y(0)), ..., (x(n), y(n)).
Supporting points := (x(0), y(0)), ..., (x(n), y(n)).
Computes the newton coefficients c(n)...c(0) by dynamic programming.
y(n) - c(0) - c(1)*(x(n) - x(0)) - ... - c(n-1)*((x(n) - x(0))*...*(x(n) - x(n-2)) c(n) := ---------------------------------------------------------------------------------- (mod prime) (x(n) - x(0))* ... *(x(n) - x(n-1)) y(1) - c(0) c(1) := ----------- (mod prime) x(1) - x(0) c(0) := y(0) (mod prime)Following applies: (n + 1) == number of supporting points. This gives a polynom of degree n with (n + 1) Newton coefficients.
- returns
the calculated newton coefficients
- val degree: Int
n supporting points give a polynom of degree n - 1
- final def eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- def equals(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef → Any
- final def getClass(): Class[_ <: AnyRef]
- Definition Classes
- AnyRef → Any
- Annotations
- @native() @IntrinsicCandidate()
- def getCurrentTracer(): AbstractTracer
Returns the present tracer for this object.
Returns the present tracer for this object.
- returns
the current tracer, by default the NullTracer
- Definition Classes
- NewtonInterpolation → Tracing
- def hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native() @IntrinsicCandidate()
- final def isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- def multiplyDifferences(i: Int, j: Int, xs: IndexedSeq[BigInt]): BigInt
Computes below expression.
Computes below expression.
(x(i) - x(0))*(x(i) - x(1))* ... *(x(i) - x(j)), i > j
Expressions of this form need to be evaluated during the calculation of the Newton coefficients.
- i
references the x-ccordinate of a supporting point (always in minuend position)
- j
denotes the upper index of the x-coordinates in subtrahend position
- returns
the value of the term (mod prime)
- final def ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- lazy val newtonPolynomial: NewtonPolynomial
Creates lazily the NewtonPolynomial by computing the Newton Coefficients.
Creates lazily the NewtonPolynomial by computing the Newton Coefficients. For the definition of a NewtonPolynomial with degree n - 1 we need only n - 1 x values projected from the supporting points whereas n of them are needed for the computation of the coefficients.
- final def notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native() @IntrinsicCandidate()
- final def notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native() @IntrinsicCandidate()
- def pairWiseDifferent(points: IndexedSeq[(BigInt, BigInt)]): Boolean
- val prime: BigInt
- val supportingPoints: IndexedSeq[(BigInt, BigInt)]
- final def synchronized[T0](arg0: => T0): T0
- Definition Classes
- AnyRef
- def toString(): String
- Definition Classes
- NewtonInterpolation → AnyRef → Any
- final def wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException]) @native()
- final def wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- def withTracer[T](resultType: String, callee: AnyRef, method: String)(block: => T): T
Custom control structure for tracing of embraced code blocks.
Custom control structure for tracing of embraced code blocks.
- T
the actual type of the embraced code block
- resultType
denotes the return type
- callee
the call site
- method
denotes the method signature
- block
the embraced code block
- returns
returns whatever block returns
- Definition Classes
- Tracing
Deprecated Value Members
- def finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.Throwable]) @Deprecated
- Deprecated