Neuron®
The Neuron® is the basis for the creation of open and secure federated networks for smart societies.
Loading...
Searching...
No Matches
Permil.cs
1using System;
6
8{
13 {
23 {
24 }
25
31 public override IElement Evaluate(double Operand)
32 {
33 return new DoubleNumber(Operand / 1000);
34 }
35
42 public ScriptNode Differentiate(string VariableName, Variables Variables)
43 {
44 if (this.op is IDifferentiable Differentiable)
45 {
46 return new Permil(
47 Differentiable.Differentiate(VariableName, Variables),
48 this.Start, this.Length, this.Expression);
49 }
50 else
51 throw new ScriptRuntimeException("Operand not differentiable.", this);
52 }
53 }
54}
Class managing a script expression.
Definition: Expression.cs:39
Base class for all nodes in a parsed script tree.
Definition: ScriptNode.cs:69
int Length
Length of expression covered by node.
Definition: ScriptNode.cs:101
int Start
Start position in script expression.
Definition: ScriptNode.cs:92
Base class for unary double operators.
ScriptNode Differentiate(string VariableName, Variables Variables)
Differentiates a script node, if possible.
Definition: Permil.cs:42
override IElement Evaluate(double Operand)
Evaluates the double operator.
Definition: Permil.cs:31
Permil(ScriptNode Operand, int Start, int Length, Expression Expression)
Permil operator.
Definition: Permil.cs:21
Collection of variables.
Definition: Variables.cs:25
Basic interface for all types of elements.
Definition: IElement.cs:20
Base interface for lambda expressions.