Skip to main content
23-Emerald V
September 21, 2016
Solved

symbolic for (each) loop error

  • September 21, 2016
  • 2 replies
  • 3144 views

Using the for programming expression in "for each" mode is a useful mode when iterating over an array and the index of an element is not a concern.  The mode works under the numeric processor when used in a free-standing program and inside a function.

However, when using the symbolic processor, the mode only works in a free-standing program and not in a function (where it is much more useful).

This is a long standing error in Mathcad.  Has it been fixed in Prime?  Can it be fixed in the next Mathcad 15 update?

Stuart

Best answer by Werner_E

It doesn't even work if the matrix is freshly defined inside the program

And, no - the bug wasn't fixed in Prime, at least not in Prime 3.0

Obviously a for-loop is interpreted/implemented differently in the symbolics and insist on a sequence like first value, (optional second. value) and end value.

Did the symbolic eval work in MC11 with Maple?

Werner

2 replies

Werner_E25-Diamond IAnswer
25-Diamond I
September 21, 2016

It doesn't even work if the matrix is freshly defined inside the program

And, no - the bug wasn't fixed in Prime, at least not in Prime 3.0

Obviously a for-loop is interpreted/implemented differently in the symbolics and insist on a sequence like first value, (optional second. value) and end value.

Did the symbolic eval work in MC11 with Maple?

Werner

25-Diamond I
September 21, 2016

Now I am further puzzled:

Mathcad 15 M030:

Prime 3.0

Prime was set to "English" using "/culture:en-US" but the error message still is in German. Something like "Object reference not set to an object instance".


Werner

12-Amethyst
September 21, 2016

Hi Stuart.

Following example let's me think that the bug it is related with the procedence of the argument as a global variable.

Best regards.

Alvaro.

Flat.gif