|
|
|
![]() |
|
|||||||
|
||||||||
![]() |
|
|
Thread Tools | Rate Thread | Display Modes |
|
|
|
#1
|
|||
|
|||
|
Quadratic equation problem
I took data from a sensor and basically tried to use the quadratic equation on it. When I plug in a number for it it would work, but the problem is that the motor just won't run when I do it. I've attached the program I made for it. If anyone could guide me in the right direction that would be much appreciated.
|
|
#2
|
|||||
|
|||||
|
Re: Quadratic equation problem
Where are you putting the code you posted a picture of? What sensor are you reading?
What are you trying to do with this computation? |
|
#3
|
|||
|
|||
|
Re: Quadratic equation problem
The code is in the teleop.vi. It's being read from a sonar (after the conversions). I basically needed to run a motor at different speeds based on the distance, but it didn't work well linearly.
|
|
#4
|
||||
|
||||
|
Re: Quadratic equation problem
Quote:
Then it looks like you are computing y = -8.24x2 +12.3x -3.97 See attachment. Is that what you intended? Last edited by Ether : 21-02-2012 at 17:47. |
|
#5
|
|||
|
|||
|
Re: Quadratic equation problem
Yes that's exactly how I wanted it, but the motor just sits there and does nothing when I tried that.
|
|
#6
|
||||
|
||||
|
Re: Quadratic equation problem
Quote:
|
![]() |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|