The latest versions of FX Draw and FX Equation have added an IF command. This represents a major increase in the power of the parameters system and allows authors to create significantly more powerful MultiDocs.
An example If command might look like this…
{if($d=0,”Cannot divide by zero”,$n/$d)}
If you included this command in a question, the inline calculator will look:
- Look at the value of the $d parameter
- If $d is zero, the command will add the words “Cannot divide by zero” to your equation.
- If $d is not zero, the command will divide the value of the $n parameter by $d and output the answer.
In addition to the new IF command, we have added a number of other Boolean commands that make it easy to write conditions for IF commands. These include:
- And
- Or
- Xor
- Nor
- Not
- IsEven
- IsOdd
- IsInteger
- IsComposite
- IsPrime
- IsFactor
- IsNatural
- IsCube
- IsSquare
The new IF command is available for use now but we anticipate that its power will allow us to add a variety of new features. Keep an eye out!