Skip to main content
1-Visitor
December 20, 2014
Solved

this value must be an integer

  • December 20, 2014
  • 7 replies
  • 9667 views

Hi

I need help,because I dont know what I do wrong. Please help.Thanks for help

Best answer by ptc-3682623

This is the correct answer.

7 replies

Werner_E
25-Diamond I
December 20, 2014

You misused the range i as index of y which for obvious reasons can't be allowed unless you use Mathcad's feature of implicit looping as you did in the definition of x two lines above.

Which value(s) and which data structure did you think that k[1 would have?

But even if you would have used k1[i:=... - what do you think a vector index is? Its a position number of a vector element.

So why did you use something like x[(i+0.5) or even y[(i+0.5*k1. Obviously a vector index must be an integer - there is no position 1.73 in a vector, just 1 or 2.

I would suggest you study the basics of vectors and ranges more thoroughly.

1-Visitor
December 20, 2014

If You would like solve this problem in xmcd I will be grateful You. I need solve differential equation metod of Rung-Kutta

Werner_E
25-Diamond I
December 20, 2014

I guess your question would have better been placed in Mathcad/Homework Help.

I understand that you think it would be easier for you if I would do your work, but I guess that the purpose of that assignment is to get you more familiar with Mathcad and the thus implemented mathematical algorithms.

So I suggest again that you do your homework and have a closer look at the basics of Mathcad. Then try again and if you get stuck come back here again.

Maybe, if you search this forum for "Runge Kutta", you may find some useful hints.