Point on Vector - Learn Maths Basics

  • Context: High School 
  • Thread starter Thread starter frogtag
  • Start date Start date
  • Tags Tags
    Point Vector
Click For Summary

Discussion Overview

The discussion revolves around determining whether a point lies on a vector, specifically in the context of mathematical equations and their application in programming for a computer AI. Participants explore the parametric equations of lines and how to isolate variables to check if a point falls within a defined range.

Discussion Character

  • Exploratory
  • Technical explanation
  • Mathematical reasoning
  • Homework-related

Main Points Raised

  • One participant seeks clarification on how to determine if a point lies on a vector, referencing the use of equations involving two points A and B.
  • Another participant suggests using the parametric equation of a line, stating that the equation should be x = txA + (1 - t)xB, where t varies between 0 and 1.
  • A participant expresses confusion about the equation, questioning the values of t at specific points and how to isolate t in the equation.
  • One participant proposes an application of the equation for a computer AI program to determine if another character crosses a line of sight defined by a vector.
  • Another participant questions whether the point x is stationary or a line, suggesting that if x is a line, a different parametric equation may be needed.
  • A participant revises their equation to x = xA + (xB - xA)t and seeks confirmation on its validity compared to the previously suggested equation.
  • Participants discuss the conditions under which a point lies on the vector, emphasizing the need for the t value to be consistent across dimensions.

Areas of Agreement / Disagreement

Participants express varying levels of understanding regarding the equations and their applications. While some agree on the validity of different forms of the equations, there is no consensus on the best approach to isolate t or the implications of the equations in the context of the AI program.

Contextual Notes

There are unresolved questions about the definitions of the variables involved, particularly regarding the nature of point x and its movement in relation to the vector. The discussion also highlights potential confusion over the parametric equations and their interpretations.

frogtag
Messages
17
Reaction score
0
Hi,
This may seem very basic, but it's been a few years since i did A-level maths!
I'm trying to remember how to work out if a point falls on a vector? I can't remember any of the terms so any info would be appreciated.

thanks
 
Physics news on Phys.org
Welcome to PF!

Hi frogtag! Welcome to PF! :smile:

Well, if you have the equation for a line, and you want to know whether (3,5,6) lies on it, just put 3 5 and 6 into the equation and see if it works.

(Or did you mean something else? … if so, give an example :wink:)
 
Thank you tiny-tim,

Taking the idea of an equation ... I reseached this:

Two points A & B, with a directional vector of AB.
Point ? is the potential bisecting point

x? = xA - (xB)t
y? = yA - (yB)t
z? = zA - (zB)t

The way I see it, (only using x for simplicity) xA is the initial point of the vector and xB is the terminal point. t is a value that holds the values 0 at xA and 1 at xB. Now if x? is on the vector then when you work out the maths then 0 =< t =< 1?

Can anyone clarify this for me please
 
Hi frogtag! :smile:

(try using the X2 tag just above the Reply box :wink:)
frogtag said:
… The way I see it, (only using x for simplicity) xA is the initial point of the vector and xB is the terminal point. t is a value that holds the values 0 at xA and 1 at xB. Now if x? is on the vector then when you work out the maths then 0 =< t =< 1?

Those equations aren't quite right …

you need x = txA + (1 - t)xB etc …

(this is the parametric equation of the line, with of course t as the parameter)

so at t = 0, x = xA, and at t = 1, x = xB :smile:
 
Too say I'm rusty is an understatement!

Using x = txA + (1 - t)xB

surely when t = 0, x = xB not x = xA?

at t = 0 ...

0 * xA = 0 and this is canceled out, but (1 - 0) = 1 and 1 * xB = xB, so x = xB?

at t = 1 ...

1 * xA = 1, but (1 - 1) = 0 and 0 * xB = 0, this part is canceled out leaving x = xA?

I'm guessing I'm not grasping this concept properly!

Also I'm thinking i have to solve the equation to separate t, ie (simple equation example)

5 = t*9

5 / 9 = t

t = 0.5 reocc.

Like this but with the equation you sent?
 
Last edited:
frogtag said:
when t = 0, x = xB not x = xA?

yes, i wrote it the wrong way round! :redface:
Also I'm thinking i have to solve the equation to separate t, ie (simple equation example)

5 = t*9

5 / 9 = t

t = 0.5 reocc.

Like this but with the equation you sent?

I'm not sure what you're trying to solve, but whatever it is, yes, you solve by getting all the t on one side. :smile:
 
This equation will be for a computer AI program. The idea I have is that the vector represents a characters line of sight. Point A in the person. Point B is where they can see to. Now I want to be able to test to see if another person crosses the vector/the line of sight. Now using the equation:

x = txA + (1 - t)xB

xA is the person.
xB is the furthest point of sight.
x is the person crossing the vector.

The only variable I have left is t, so what i need to do is isolate t so that i can test its value to see if it's within the ranges of 0 to 1 and thus within the person line of sight.

Just having difficulty with the equation. More than willing to do the hard work if you could point me in the right direction?

This is what I've got so far...

1 - ( x - (txA) / xB ) = t

not great ... and probably not right?!
 
Last edited:
frogtag said:
This equation will be for a computer AI program. The idea I have is that the vector represents a characters line of sight. Point A in the person. Point B is where they can see to. Now I want to be able to test to see if another person crosses the vector/the line of sight …

I don't get it. :confused:

Is x stationary, or is x a line?

(and do these characters only see dead-ahead of themselves?)

If x is a line, it will need another parametric equation (with a parameter u, say, instead of t), and then you can ask whether the two lines cross.
 
Is x stationary, or is x a line?

Because its a computer program I have to use timed intervals to check on the position of x to see where it is. It's like taking a film of a ball moving and checking each frame to see where the ball is. So x will be considered a staionary point.

(and do these characters only see dead-ahead of themselves?)

For the moment yes. The process I'm taking is to develop the visual parameters bit by bit. For this moment, version 1.0, my basic visual parameter is a single line of sight from the person to a set point directly ahead of them. The next versions will see detection of a point within a fan. Then expanding to peripheral vision, so several fans, etc... I think its better to crawl before I walk!

I looked at my old equation and saw I made a mistake. It should have read:

x = xA + (xB-xA)t

will this work instead of

x = txA + (1 - t)xB

because I don't understand the concept of your equation. Mine seems more simple, and with it there is only one t and I'm able to isolating it, as such:

x - xA
------- = t
xB - xA

then, the way I see it, if the t value is the same for x, y and z equations, then point [x,y,z] will sit on the vector/line?
 
  • #10
frogtag said:
I looked at my old equation and saw I made a mistake. It should have read:

x = xA + (xB-xA)t

will this work instead of

x = txA + (1 - t)xB

Yes, they're the same. :smile:
x - xA
------- = t
xB - xA

then, the way I see it, if the t value is the same for x, y and z equations, then point [x,y,z] will sit on the vector/line?

oh i see what you mean …

yes, if (x - xA)/(xB - xA) = (y - yA)/(yB - yA) = (z - zA)/(zB - zA),

and if that value is between 0 and 1,

then (x,y,z) lies between A and B :smile:
 
  • #11
Marvellous. Thank you kindly for your help Tiny-Tim, you're a star! :biggrin:
 

Similar threads

  • · Replies 19 ·
Replies
19
Views
4K
  • · Replies 3 ·
Replies
3
Views
2K
  • · Replies 2 ·
Replies
2
Views
2K
  • · Replies 8 ·
Replies
8
Views
3K
  • · Replies 1 ·
Replies
1
Views
2K
  • · Replies 13 ·
Replies
13
Views
3K
Replies
3
Views
2K
  • · Replies 12 ·
Replies
12
Views
877
  • · Replies 7 ·
Replies
7
Views
1K
  • · Replies 16 ·
Replies
16
Views
5K