Finding purpendicular vector

Started by
8 comments, last by LilBudyWizer 17 years, 9 months ago
Hey guys if i have two vectors A and B where A = (1,1,-3) B = (5,-2,-1) how can i find a third vector that is purpendicular to both A and B. Using the dot product rule C is the third vector a.c/(|a||b|) = b.c/(|b||c|) But i cant seem to solve the problem, is there always just one vector which satisfies this question? If i simplify i get (x + y -3z)_/-30 ------------------- = 0 (5x - 2y -z)_/-11 Where _/- signifies square root. Does that at the top mean i can just insert a random value for x and y and then solve for z or what? Remember the dot rule a.b = |a||b|Cos(A0B) // Where 0 is the origin or (0,0,0) ----------------- YES THIS IS HOME WORK, but piss off i am asking how to do it not for you to do it. I have another 15 to do or so, so i would really appreciate the method more than the solution.
----------------------------

http://djoubert.co.uk
Advertisement
The problem really is too simple for any tips. What you need is basically to look at the 'cross product' or 'vector product' chapter in your book, or here for instance.
[s]--------------------------------------------------------[/s]chromecode.com - software with source code
Solution 1) Both the dot products a.c and b.c should be 0. Write down the equations and you'll have a system of two linear equations in three variables. Solve it.

Solution 2) Compute the cross product of a and b.
Quote:Original post by Enselic
The problem really is too simple for any tips. What you need is basically to look at the 'cross product' or 'vector product' chapter in your book, or here for instance.


mm the Cross product is not in my high school curriculum so i need to be able to solve it without the cross product but thanks ill look into using the cross product.

I have to go with solution 1 then and this is my result...
x+y-3z = 5x-2y-2z
4x -3y +z = 0

So how do i find x y and z???

OR is the vector c simple (4,-3,1) ????

EDIT:
---------
Okay i used your cute cross product and now i have an answer for the question
C = (-7,14,-7) BUT the book says (1,2,1) now if you ignore the sign then

k(7,14,7) = (1,2,1) but the sign is a problem.

COULD it be that they are using the left hand rule while i the right hand rule?
----------------------------

http://djoubert.co.uk
Quote:Original post by dawidjoubert
Quote:Original post by Enselic
The problem really is too simple for any tips. What you need is basically to look at the 'cross product' or 'vector product' chapter in your book, or here for instance.


mm the Cross product is not in my high school curriculum so i need to be able to solve it without the cross product but thanks ill look into using the cross product.

I have to go with solution 1 then and this is my result...
x+y-3z = 5x-2y-2z
4x -3y +z = 0

So how do i find x y and z???

OR is the vector c simple (4,-3,1) ????


Since you have two equations and three unknowns, the answer will be dependant on one variable. This variable will be the "scaling variable" of the answer vector (i.e. there are infinitely many answer-vectors, however, they all point in the same or opposite direction.) You solve by preferably using Guass elimination.
[s]--------------------------------------------------------[/s]chromecode.com - software with source code
Quote:Original post by Enselic
Quote:Original post by dawidjoubert
Quote:Original post by Enselic
The problem really is too simple for any tips. What you need is basically to look at the 'cross product' or 'vector product' chapter in your book, or here for instance.


mm the Cross product is not in my high school curriculum so i need to be able to solve it without the cross product but thanks ill look into using the cross product.

I have to go with solution 1 then and this is my result...
x+y-3z = 5x-2y-2z
4x -3y +z = 0

So how do i find x y and z???

OR is the vector c simple (4,-3,1) ????


Since you have two equations and three unknowns, the answer will be dependant on one variable. This variable will be the "scaling variable" of the answer vector (i.e. there are infinitely many answer-vectors, however, they all point in the same or opposite direction.) You solve by preferably using Guass elimination.


How old do you think i am, what is Guass elimination? .. tsk ill check it up

----EDIT----

Yeah gaussian would work if i had 3 equations and i only have 2.
So using substitution i get

Originals
--------
5x = 2y + 2z
x + y - 3z = 0
Derived
--------
7y - 13z = 0
7y/13 = 7x/8
y = 13z/7
x = 8z/7

I cant seem to solve it without the 3rd equation...

-- EDIT ---
Oh i see what you mean, mmm this is quite a load of simplifying and manipulating of equations. Quite annoying

I think i will teach myself the CROSS product even if it isn't in my curric
----------------------------

http://djoubert.co.uk
Original post by dawidjoubert
.........
.....
.
.
.


Thanks I can solve them now, it is actually really easy.
What i do is, say a = (1,2,3) b = (4,5,6) then c = (1,y,z) since c only has to be purpendicular there is an infinte vectors that are purp, so as you said i can use 1 axis as the scaling axis.

Then i can use the CROSS product to make sure my answer is right. :-)

A Quick question, was the cross product derived from the dot product by manipulating algebra or does it have its own proof?

IS ax+by+cz = d called linear because a,b,c,d are constants and so there is no x*y or x*x present?
----------------------------

http://djoubert.co.uk
I can't resist! I must solve this for you!!

Solution

Alright, so we have

A = (1, 1, -3)
B = (5, -2, -1).

We now want to find a vector C = (x, y, z) which is perpendicular to both A and B, so we solve the equations

A · C = 0
B · C = 0

(since the dot product of two perpendicular vectors are 0).

We expand the equations above as

x + y - 3z = 0
5x - 2y - z = 0.

Multiply the first one with 2 and add with the second one (Gauss elimination) and we get

x + y - 3z = 0
7x - 7z = 0.

We're stuck here since we have no more equations unless we introduce a dependant variable t. We do that and get

x + y - 3z = 0
7x - 7z = 0
z = t.

Inserting the equations into each other gives you

x = t
y = 2t
z = t.

Answer: C = (t, 2t, t) where t ∈ R

*Relief*
[s]--------------------------------------------------------[/s]chromecode.com - software with source code
Quote:Original post by Enselic
I can't resist! I must solve this for you!!

Solution

Alright, so we have

A = (1, 1, -3)
B = (5, -2, -1).

We now want to find a vector C = (x, y, z) which is perpendicular to both A and B, so we solve the equations

A · C = 0
B · C = 0

(since the dot product of two perpendicular vectors are 0).

We expand the equations above as

x + y - 3z = 0
5x - 2y - z = 0.

Multiply the first one with 2 and add with the second one (Gauss elimination) and we get

x + y - 3z = 0
7x - 7z = 0.

We're stuck here since we have no more equations unless we introduce a dependant variable t. We do that and get

x + y - 3z = 0
7x - 7z = 0
z = t.

Inserting the equations into each other gives you

x = t
y = 2t
z = t.

Answer: C = (t, 2t, t) where t ∈ R

*Relief*


Wow that is a very neat way of doing it as you will always end up with integer values for c unlike my way of always making c.x = 1

Nice :-)
----------------------------

http://djoubert.co.uk
Not really. That equation is less constrained than the original problem. You start with a.c=0 and b.c=0. The solution to a.c=0 and b.c=0 is a line in 3d. The solution to a.c=b.c is a plane in 3d. The plane that is the solution to a.c=b.c contains the line that is the solution to a.c=0 and b.c=0, but also contains an infinite number of points that is not a solution to the original problem. If you solve a.c=b.c for x then you get a solution in the form of x=f(y,z). You can't stop there. You have to substitute f(y,z) for x in one of the original equations. If you then solve that for y you get a solution in the form y=g(z). So x=f(g(z),z) and y=g(z) is the solution. That's a general solution and substituting a specific value for z gives a specific solution. One of the specific solutions is (0,0,0) called the trivial solution since it is a generally useless solution. So you don't want to substitute zero for z.
Keys to success: Ability, ambition and opportunity.

This topic is closed to new replies.

Advertisement