Skip to content

Commit

Permalink
.
Browse files Browse the repository at this point in the history
  • Loading branch information
sys27 committed Aug 25, 2020
1 parent 7d007b4 commit 6da9fed
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion xFunc.Benchmark/Benchmarks/DifferentiatorBenchmark.cs
Original file line number Diff line number Diff line change
Expand Up @@ -23,13 +23,15 @@ namespace xFunc.Benchmark.Benchmarks
public class DifferentiatorBenchmark
{
private Differentiator differentiator;
private DifferentiatorContext context;

private IExpression complexExp;

[GlobalSetup]
public void Setup()
{
differentiator = new Differentiator();
context = DifferentiatorContext.Default();

// (abs(sin(cos(tan(ctg(x ^ 2))))) - ln(x ^ 2)) + arcsin(arccos(arctan(arcctg(x ^ 10))))
complexExp = new Add(
Expand Down Expand Up @@ -64,6 +66,6 @@ public void Setup()

[Benchmark]
public IExpression ComplexExpression()
=> complexExp.Analyze(differentiator, DifferentiatorContext.Default());
=> complexExp.Analyze(differentiator, context);
}
}

0 comments on commit 6da9fed

Please sign in to comment.