Community Tip - You can subscribe to a forum, label or individual post and receive email notifications when someone posts a new topic or reply. Learn more! X
for a range variable k an assignment variable cannot be set, Kindly help, see the attached worksheet please.
Kind regards
Solved! Go to Solution.
Reason is that you are using a range variable for something its not made for.
But you are not the first to confuse ranges with vectors - unfortunately, it is a matter that constantly causes misunderstandings and confusion.
Ranges are kind of implicit loops, not a data structure which holds a couple of values (like a vector).
Ranges should only be used for
1) plots as the variable placed at the abscissa axis
2) indexing vectors and matrices
3) loops in a program
For your purpose you should define variable "k" as a vector, not a range.
Simply replace the definition k:=0,0.2..1 by k:=vec(0,0.2,1) and all will work as you expected.
"vec" is a new function in Prime 11 and can be used to either define a vector (as just shown) or to convert a range into a vector. See the help for more information.
Reason is that you are using a range variable for something its not made for.
But you are not the first to confuse ranges with vectors - unfortunately, it is a matter that constantly causes misunderstandings and confusion.
Ranges are kind of implicit loops, not a data structure which holds a couple of values (like a vector).
Ranges should only be used for
1) plots as the variable placed at the abscissa axis
2) indexing vectors and matrices
3) loops in a program
For your purpose you should define variable "k" as a vector, not a range.
Simply replace the definition k:=0,0.2..1 by k:=vec(0,0.2,1) and all will work as you expected.
"vec" is a new function in Prime 11 and can be used to either define a vector (as just shown) or to convert a range into a vector. See the help for more information.
