Message Boards Message Boards

Avoid subsequent calculations to cause lost of prior calculations in nb?

GROUPS:

It seems that the only way that I can calculate the attached notebook is by first going into "Evaluate" and then selecting "Quit Kernel" then selecting "Local" and finally press the "Enter" key on my number pad. If I later press the "Enter" key on my number pad, while in the notebook, I loose my evaluations and then need to through the "Evaluate" and then selecting "Quit Kernel" procedure again.

It appears that the first top down calculation works fine, but any additional calculations really seems to mess the notebook up. Additionally, I am getting a "Set::write: Tag Function in (0&)[0.000263158] is Protected" message as well.

Could someone please tell me what I am doing wrong.

Thanks,

Attachments:
POSTED BY: Mitchell Sandlin
Answer
6 days ago

Hi Mitchell,

a cursory analysis of the code suggests that you should write

VectorPlot[{1, Sin[2 t] }, {x, 0, 5}, {t, 0, 5}, VectorScale -> {.03, .03, None}, VectorPoints -> 20, VectorStyle -> {Thick, Red}, Frame -> True, Axes -> True, AxesLabel -> {"x", "t"}]

where you do the vector plot. Note that I change the

x''[t] = Sin[2 t]

to

Sin[2t]

the thing is that a single equal sign sets the left hand side to the value/function on the right hand side. Which - after solving the ODE - simply gives TRUE next time you run it. That should cause the error. The second error will be a consequence of that. I have no access to a computer at this point in time, so I might be wrong, but you might want to give it a try.

Cheers,

Marco

POSTED BY: Marco Thiel
Answer
5 days ago

Group Abstract Group Abstract