Community Tip - Want the oppurtunity to discuss enhancements to PTC products? Join a working group! X
Hello,
Please see attached file. How can i get a constant value for (EI) to be multiplied by the results of the curvature y"(x)?
Thanks,
Sam
Solved! Go to Solution.
But then your range variable "x" must consist of integers only.
Which makes your approach VERY limited, especially given that an additional constraint is that the range variable must start with ORIGIN as the first value!
Also it seems that @SFares wanted to define a function, not just a vector of values.
For more flexibility you could use something like
but again M is not a function but just a vector of values.
You may also note that it was necessary to use the (IMHO silly and wrong) alternate way of accessing vector elements by using the vector as if it would be a function, x(i) instead of x[i.
If we use the correct vector index here, Prime throws an error which seems to be related to the bug I mentioned in my previous reply.
Or compare this
Sure a bug.
Ranges should only be used in three cases:
1) To index the elements of a matrix or vector
2) To define the abscissa values for a plot
3) To create a for-loop in a program
You defined x as being a range but used it for other purposes.
You should define x as being a vector rather than a range!
While playing with your sheet I found what i consider to be a bug in Prime. A derivative using the prime operator throws an error when used vectorized -> Bug in Prime with vectorization and prime operator..
See attached P11 file for further informations
Hello.
My best guess is to try and use subscript "x" in the definition of "M". But then your range variable "x" must consist of integers only.
See attached mathcad.
Best regards,
Sergey
But then your range variable "x" must consist of integers only.
Which makes your approach VERY limited, especially given that an additional constraint is that the range variable must start with ORIGIN as the first value!
Also it seems that @SFares wanted to define a function, not just a vector of values.
For more flexibility you could use something like
but again M is not a function but just a vector of values.
You may also note that it was necessary to use the (IMHO silly and wrong) alternate way of accessing vector elements by using the vector as if it would be a function, x(i) instead of x[i.
If we use the correct vector index here, Prime throws an error which seems to be related to the bug I mentioned in my previous reply.
Or compare this
Sure a bug.
Thank you, Werner!
So what made you use x(i) knowing x[i does not work, as if x(i) is a function? As you said, It is strange that mathcad accepts x(i) and not x[i
Regards,
Sam
Hello @ttokoro,
Are you saying i need to do a symbolic evaluation to get the answer, and not "="?
Regards,
Sam
You should show that x is a range in the first two rows.
Furthermore it would be helpful if you would show the result when you try to assign the calculations a variable and later in a separate region only numerically evaluate that variable.
Like:
It looks that unless PTC fixes the bug, only symbolical evaluation may help a little bit. Can't check as I am limited to Express.
I would guess it even may go worse once units are added (which @SFares sure should do so as its one of the strengths of Mathcad and still also Prime.
BTW, the literal derivative operator seems not to suffer from that bug
Thank you Werner for all your efforts!
Thank you, ttokoro!