Random Vector with some ranges that also sums to 1 [closed]

asked 2013-02-26 09:39:18 -0500

MartinW gravatar image

Hello all,

I was wondering what is the best way to go about making a vector with certain ranges that also has a magnitude of 1. Basically I want my program to randomize different orientations of my end effector until it finds one that works. I have certain ranges for orientation that I would like to work with too, W:{0.5,0.7},X{-0.5,-0.7},Y{-0.3,0.3} with Z as a free variable to ensure the vector magnitude is 1.0. I've written some code that does something similar to this but it only has about 5% success rate of finding a good orientation. Are there better ways to find good orientations?

Kind Regards, Martin

edit retag flag offensive reopen merge delete

Closed for the following reason question is off-topic or not relevant. Please see http://wiki.ros.org/Support for more details. by tfoote
close date 2013-12-29 14:24:06