Skip to main content
1-Visitor
December 22, 2014
Solved

Could you give me a method to restrick vector's values?

  • December 22, 2014
  • 11 replies
  • 3484 views

35.PNG

I want "omega" to restrict 12.1rpm.

So I tried such as a upper picture.

But I got error. I can't understand why I got error.

could you help me?

Best answer by Werner_E

You may use a small auxiliary function whch you then call vectorized:

1.png

11 replies

Werner_E
Werner_E25-Diamond IAnswer
25-Diamond I
December 22, 2014

You may use a small auxiliary function whch you then call vectorized:

1.png

jlee-21-VisitorAuthor
1-Visitor
December 22, 2014

Oh Thank you very much.

But I wonder why I got error when I tried

Werner_E
25-Diamond I
December 22, 2014

You can't compare a vector to a scalar. In fact - you can, but the result will be a vector consisting of zeros and ones which is invalid as condition in the if function.

1.png