SMath Studio has several programming commands, so you can write procedures.
Besides what is below, there are also
Tutorials on programming in SMath Studio: pdf | zip These are
if,
for,
while and
line.
EditExamples
Take care that some complicated programming structures are not implemented.
EditThe Need for Speed!
If your loops are running too slowly use eval to speed them up. I've got one program that is 500 times faster using eval.
You can often gain a speedup by setting the Optimization mode to Numeric as follows:
1. Let's start with nothing selected:
2. Left-click anywhere on the loop in question. The loop will be surrounded by a selection box:
3. Right-click anywhere on the loop. The context menu will now have a setting for Optimization. Set this to "Numeric." The Optimization setting automatically applies to all operations within the selection box.
4. When you left-click outside the loop, SMath Studio will recalculate the page (if you have main-menu option
Calculation > Auto calculation turned on). The calculation will typically be faster than it was with Optimization set to Symbolic.