本文整理汇总了C#中IExpression.Simplify方法的典型用法代码示例。如果您正苦于以下问题:C# IExpression.Simplify方法的具体用法?C# IExpression.Simplify怎么用?C# IExpression.Simplify使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类IExpression
的用法示例。
在下文中一共展示了IExpression.Simplify方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: Init
protected void Init(
IExpression fx,
IExpression fy,
IExpression fz,
double uMin,
double uMax,
double vMin,
double vMax
)
{
_fx = fx.Simplify();
_fy = fy.Simplify();
_fz = fz.Simplify();
_fxDu = _fx.Differentiate("u").Simplify();
_fxDv = _fx.Differentiate("v").Simplify();
_fyDu = _fy.Differentiate("u").Simplify();
_fyDv = _fy.Differentiate("v").Simplify();
_fzDu = _fz.Differentiate("u").Simplify();
_fzDv = _fz.Differentiate("v").Simplify();
UMin = uMin;
UMax = uMax;
VMin = vMin;
VMax = vMax;
}
示例2: MemoryAppend
private void MemoryAppend(object sender, RoutedEventArgs args)
{
if (ComputeAnswer())
{
if (_lastAnswer is ConstantExpression)
{
if (_memory == null)
{
_memory = _lastAnswer;
}
else
{
_memory = new AddExpression(_memory, _lastAnswer);
_memory = _memory.Simplify();
}
ScreenBuffer += _memory.ToString() + "\n";
}
else
{
ScreenBuffer += "Cannot store this value in memory\n";
}
}
}