Function
Static Public Summary | ||
public |
makeDirectEvaluators(web3: Web3, gateway: Gateway): NodeEvaluators Returns NodeEvaluators object for evaluating using |
|
public |
Returns NodeEvaluators object for evaluating using |
|
public |
makeRandomIDFunc(randomFunc: Function): Function Creates a random ID generator given a PRNG |
Static Public
public makeDirectEvaluators(web3: Web3, gateway: Gateway): NodeEvaluators source
import {makeDirectEvaluators} from 'fincontracts-lib/src/fincontract-evaluator.js'
Returns NodeEvaluators object for evaluating using direct
(See makeEstimationEvaluators) method.
Nodes are defined exactly as for estimate
method with exceptions of:
if
: selects the child interval based on the boolean value obtained from calling the gatewayscaleObs
: interval arithmetic scalar multiplication with scale obtained from calling the gateway
public makeEstimationEvaluators(): NodeEvaluators source
import {makeEstimationEvaluators} from 'fincontracts-lib/src/fincontract-evaluator.js'
Returns NodeEvaluators object for evaluating using estimate
method.
Nodes are defined as:
if
: interval arithmetic unionor
: interval arithmetic unionand
: interval arithmetic additiongive
: interval arithmetic negationscale
: interval arithmetic scalar mulitplication with scalescaleObs
: interval arithmetic multiplication with estimate scale intervaltimebound
: zero interval if fincontract's upper bound has passedone
: interval arithmetic 1zero
: interval arithmetic 0
public makeRandomIDFunc(randomFunc: Function): Function source
import {makeRandomIDFunc} from 'fincontracts-lib/src/fincontract-dot-generator.js'
Creates a random ID generator given a PRNG
Params:
Name | Type | Attribute | Description |
randomFunc | Function | a PRNG to be used as a source of randomness |