Author |
Message |
Chris Bailey (c_bailey)
New member Username: c_bailey
Post Number: 1 Registered: 01-2010
| Posted on Monday, February 01, 2010 - 09:11 am: | |
I am writing this (in a 1D problem) to get a history of P at 11 points along "length": history(P) repeat i = 0 to 10 at (i*length/10) endrepeat But I get an error saying "Parser expects ACUMESH" with my "at" highlighted. If I write out "... at (0.0*length) at (0.1*length)" et cetera, it works. What am I doing wrong? Thanks! |
Marek Nelson (mgnelson)
Moderator Username: mgnelson
Post Number: 177 Registered: 07-2007
| Posted on Monday, February 01, 2010 - 03:16 pm: | |
There are several forms that HISTORY will accept for multiple points: HISTORY(P) AT (p1) AT (p2) AT (p3)... HISTORY(P) AT (p1), (p2), (p3),... HISTORY(P) AT (p1) (p2) (p3)... To use REPEAT, you need place the AT before the REPEAT statement, i.e. HISTORY(P) AT REPEAT i = 0 to 10 (i*length/10) ENDREPEAT This is equivelant to the form HISTORY(P) AT (p1) (p2) (p3)... The AT needs to be before the REPEAT so that the statement is grammatically unambiguous, since the HISTORY statement could be complete without the AT clause. |
Chris Bailey (c_bailey)
New member Username: c_bailey
Post Number: 2 Registered: 01-2010
| Posted on Monday, February 01, 2010 - 03:55 pm: | |
That fixed me! "at" is outside now! Thanks! |
|