This is my first post in here. Maybe my tittle is not the best. Anyway, I'll try to be as more precise as possible describing my problem which you might help me with...
I'm a programmer, and I'm creating a game. In this game a particle has to move from one point A to a point B in a 2D space. In principle I want this particle to be intelligent and move in a kind of wave (sinusoidal). I don't care anything about the phase at the beginning nor at the end. I just want the particle to go from A to B.
However, my particle also has an intelligence coefficient, which makes it go straight forming a sinusoidal (if intelligent) to the end point or if the coefficient is really low it just takes totally random values.
My original idea was to have the intelligence coefficient between 0 and 1, in such a way that to calculate the next point P it is => P = sinPoint.intelligence + randomPoint.(1-intelligence). However, after thinking about it, I think it is my worst idea ever.... Yes it could work for very intelligent and very stupid particles, but for middle cases it just makes it so messed up....
So when I realized it I was so confused I decided to go into a mathematical forum to ask for some kind of hint or idea about what could I make.
And the final details...I have a piece of code that is going to recalculate the position and plot it constantly, about every 0.005 seconds. So my piece of code doesn't depend on time, although I could fix this, and the real problem is that for the middle cases I get lost on how to recover the sinusoidal trajectory after adding half of the new position randomly.
Thanks for the help.