Basically, i am trying to calculate deflection of a beam by using Mathcad.
But I cant define my range variable with units (mm).
I believe using range variable are not allowed as input for the multiple user defined as in the photo.
Is there any way to input value using range values with units into a multiple user defined function and then plot the graph?
I have found over time the following little function extremely useful.
1) You sure can define a range with units! The error message tells you exactly whats wrong and how you can correct it:
But even if you supply the second value (and its a good habit to apply the unit to 0, too) your calculation would not work because you should not use a range for this task. You get the error that you can't compare a range to a scalar:
You should use a vector instead of a range. You could use Terrys utility function to create that vector or use a dirty, undocumented trick to turn a range into a function - you simply type an equal sign after the 100m to evaluate the range and bingo, its turned into a vector. The calculation still would not work as you can't compare a vector (x) to a scalar (L.2), too. So its a good idea to turn your calculation into a function and call that function vectorized:
You should provide an otherwise statement as what you had typed missed the cases x<=0 and x=L.2.