Friday, July 31, 2009

Newtons law help?

11. One Newton is the amount of force required to give a 1-kg mass an acceleration of:


A. 1 m/s/s


B. 2 m/s/s


C. 10 m/s/s


D. 1/2 m/s/s


12. A 50 kg rock rests on the earth. If you take this rock to the moon, its mass will be:


A. 0 kg


B. 50 kg


C. 100 kg


D. 500 kg


13. A 50 kg rock rests on the earth's surface. Its weight on earth is about:


A. 50 N


B. 100 N


C. 200 N


D. 500 N


14. The weight of an object is the force of _________ acting upon that object.


A. tension


B. mass


C. friction


D. gravity


15. A force is a quantity which is measured using a standard metric unit known as the :


A. meter


B. Newton


C. meter/second/second


D. kilogram


16. How many forces act on a book that is resting on a table?


A. 1


B. 2


C. 3


D. 4


17. A force is:


A. a push or a pull


B. an interaction between teo objects


C. vector qunatity


D. all of these


18. An object has a 400 N force pulling upward on it, while a 150 N force acts on it to pull it down. What is th net force acting on the object?


A. 400 N upward


B. 250 N upward


C. 150 downward


D. 250 downward


19. An example of a contact force is:


A. an electrical force


B. a magnetic force


C. a frictional force


D. a gravitational force


20. What is the net force acting on a 25 kg brick while it is at rest on a table?


A. 0 N


B. 12.5 N


C. 25 N


D. 250 N

Newtons law help?
11. A


12. B


13. D


14. D


15. B


16. B


17. D


18. B


19. C


20. A
Reply:11. a


12. b


13. d


14. d


15. b


16. d


17. d


18. b


19. c


20. a

song downloads

Help vectors due tomorrow!!!!?

---%26gt; ---%26gt;


OAB is a triangle with OA=a and OB=b. P and Q are the mid-points of OA and AB, respectively.





DIAGRAM---%26gt;http://i210.photobucket.com/albums/bb154...





---%26gt; ----%26gt; -----%26gt; ----%26gt;


a)PA b)AB c)AQ d)PQ

Help vectors due tomorrow!!!!?
Part a)


PA = (1/2) a





Part b)


a + AB = b


AB = b - a





Part c)


AQ = a + (b - a) - (1/2) b


AQ = (1/2) b





Part d)


(1/2) a + PQ = (1/2) b


PQ = (1/2) b - (1/2) a
Reply:where's ur Qn?
Reply:Where's the question?


Resultant Vectors and Forces (Physics)?

3.


A 5kg block slides with constant velocity down a 37ยบ inclined plane.





Draw the force diagram and write out the equations for the sum of the forces.





a. What is the weight of the box?





b. What is the normal force?





c. What is the frictional force?





d. What is the coefficient of kinetic friction?








*I know that the weight is 5 X 9.8 = 49N


*Also that Acceleration = 0


But when I try to find the Normal Force this is what I come up with.


Fn – Fg = ma


Fn – (9.8 x 5) = (5)(0)


Fn – 49 = 0


+49


Fn = 49N








That’s how I am solving the problem, but my worksheet says that the normal force is 39.1N…. so I’m totally lost.

Resultant Vectors and Forces (Physics)?
Let:


m be the mass of the block,


g be the acceleration due to gravity,


R be the normal reaction of the plane on the block,


F be the friction acting upward parallel to the plane,


a be the inclination of the plane,


u be the coefficient of kinetic friction.





Your force diagram for the block should show:


R perpendicular to and away from the plane;


F parallel to and up the plane;


mg vertically downward.





Resolving parallel to the plane:


mg sin(a) = F ...(1)





Resolving perpendicular to the plane:


mg cos(a) = R ...(2)





F / R = u ...(3)





(a)


The weight is mg = 49N, as you have found.





(b)


From (2):


F = 49cos(37) = 39.1N.





(c)


From (1):


F = 49sin(37) = 29.5N.





(d)


From (3):


u = tan(37) = 0.75.


Vectors! scalars! HELP!!?

write c in the form ra+sb, where r and s are scalars.





a=3i+2j


b+8i+5j


c+7i+9j

Vectors! scalars! HELP!!?
Assume question SHOULD read as:-


a = 3i + 2j


b = 8i + 5j


c = 7i + 9j





ra = 3r i + 2r j


sb = 8s i + 5s j





ra + sb = (3r + 8s) i + (2r + 5s) j


c = 7 i + 9 j


If c = ra + sb:-


3r + 8s = 7


2r + 5s = 9





-6r - 16s = - 14


6r + 15s = 27------ADD


-s = 13


s = - 13





2r = 74


r = 37





c = 37a - 13b
Reply:Thank you for your vote. Report It

Reply:7i+9j=r(3i+2j)+s(8i+5j)


so 3r+8s=7 and 2r+5s=9





now it's easy...


you solve the system


you find


r=37 and s= -13


Vectors on a Plane?

Given a=2i+3j, b=3i+5j and c=8i+11j express c in the form ra+sb where r and s are scalars.





THANKS!!!

Vectors on a Plane?
ra + sb = r(2i+3j) + s(3i+5j)





distribute and regroup i's and j's, we get





i(2r+3s) + j(3r+5s)





Since c = ra+sb,





2r + 3s = 8


3r + 5s = 11





Solving these, we get r=47/2 and s=-13, so





c = (47/2) a - 13 b

sending flowers

Vectors?!?!?

Given: a − b = c and c = h54, 36i.


Which of the following expressions is NOT


meaningful?


1. (c · a) − |b|


2. a · (b · c)


3. (c · a)b


4. c · (a + b)


5. 20(c · a)b





Thanks for looking. I am not exactly sure what is meant by "meaningless" any help would be appreciated.

Vectors?!?!?
Meaningless means that the operation is not defined in a vector space.





1. c*a = the dot product of two vectors is a number; the magnitude of a vector is also a number, so 1 is defined.


2. The dot product only exist between vector...you cannot take a dot product of a vector and a number...meets the meaningless criteria.


3. The scalar multiplication exist...product is defined.


4. dot product of the vector c and the vector resulting from the sum of a+b is defined.


5. And, from all of the above, 5 is a defined quality.





Your job know is to make the appropriate substitutions and solve. Good luck.
Reply:a, b, and c are all vectors.





2. a · (b · c) is not meaningful.


(b . c) is a scalar. So you can't take the dot product of a vector a and a scalar. A dot product is between two vectors.


Physics Question help?

Vector b vector has magnitude 13.6 and direction 22° below the +x-axis. Vector c vector has x-component Cx = -1.2 and y-component Cy = -5.2.


(a) What are the x- and y-components of b vector?


Bx =___


By =___





(b) What is the magnitude and direction of c vector?


Magnitude ___


Direction ___° clockwise from the +x-axis





(c) What is the magnitude and direction of c vector + b vector?


Magnitude ___


Direction ___° clockwise from the +x-axis





(d) What are the magnitude and direction of c vector - b vector?


Magnitude ___


Direction ___° clockwise from the +x-axis





(e) What are the x- and y-components of c vector - b vector?


( - )x =


( + )y =








Our prof gave us these questions to study for our midterm and I was hoping you guys could give me some help as to how to go about solving


thanks a bunch

Physics Question help?
*


***


******


********


***********


************************************


Instructions :


All vectors must start at the origin: (x,y) = (0,0).


The vectors must be fairly short,


the vectors are constrained to:








( -10 %26lt; x %26lt; +10 ) and


( -10 %26lt; y %26lt; +10 )





Create two vectors then press the "A + B" button.





Create vectors by moving the cursor to the origin,


then press and hold the mouse button while dragging


the mouse away from the origin and release the mouse


button when you have the desired vector.





Vectors will "snap" to the nearest grid line ( an integer value ).











That was simple, wasn't it ?


Would you like to be less restricted ? Ok.





The first vector can be a little longer:








( -15 %26lt; x %26lt; +15 ) and


( -15 %26lt; y %26lt; +15 )





The second vector will be restricted, bound by a lightly drawn


yellow rectangle, and the constraints may or may not seem


reasonable, but there is a reason, which may become apparent.





The constraints on the second vector depend on the first vector.





Making the first vector relatively long will result in having


the constraints be drawn more tightly on the second vector.








After you create two vectors, you may use any of the buttons labeled:








"A + B", "B + A",


"A - B", "B - A"








You can press any of these buttons,


and any combination of the buttons.





When multiple vector operations are requested, they will drawn together


( the previous resultant vectors are not erased ).





The graph may move when you first press one of the vector addition


or subtractions keys.





I guarantee that no resultant vector will ever


run off the edge of the grid ( it may go right to the edge ).





Let me know if you can create vector that does go beyond the edge ...





( But I know that you can't. )





When a vector subtraction operation takes place the negation of sutracted


vector will be drawn in orange, this vector is added to the other vector


to create the resultant vector.





There is a "hints" line at the bottom of the right panel which flashes


simple, friendly hints and an "out of bounds" warning at approriate times.








I've often wondered if people actually read the instructions ....


Vector Question?

Consider two vectors with the following coordinates (x, y, z):


C= (1.2, -5.6, 2.7)*m


D= (-1.2, 5.6, -2.7)*m


What is the length of the following vector?


C+D

Vector Question?
if you are adding vectors, you break them up into their x,y, and z components and simply add like normal numbers. since these are already in the x,y, and z-component forms... just add ;)





1.2 + (-1.2) = 0


-5.6+5.6 = 0


2.7 + (-2.7) = 0





so you get C+D = (0,0,0)*m or the zero vector.


Question about vector?

Let a and b be the position vectors of the poiints of A and B.Let C diveides AB internally in the ratio p:q, then the position vector c of C is c= (qb+pa)/p+q

Question about vector?
............
Reply:find what?

send flowers

Physics vector help pls?

suppose that u have three vectors. A=3i+4j, B=2i-2j+4k, and C= -i+5j - 3k. show that the sum of these three vectors can alternatively be computed by first summing vector A and B and then summing the resultant with vector C or by first summing vector B and C and then summing the resultant with vector A.

Physics vector help pls?
A + B = (3+2)i +(4-2)j + (0+4)k


= 5i + 2j + 4k





A+B+C = (5-1)i +(2+5)j + (4-3)k


= 4i + 7j +1k
Reply:I hope you know what vectors actually are?? If not, you'd better start from the beginning, and this time READ through the text, don't just look at the examples!


Say your vector A=3i+4j.. Technically, it is a point in a cartesian frame which is 3 units on the x-axis and 4 units on the y-axis (and zero on the z-axis, but forget that for now), measured from the origin, i.e., the point of concurrence of the three mutually perpendicular axes. So just imagine an arrow pointing in a direction like that, the way you've done graphs in lower classes. Now when you're adding two vectors, what you get is a resultant vector, hence it should have magnitude and direction. In this case, it's pretty easy, since you have the COMPONENTS of each vector along the reference axes, so you can directly add them, without having to worry about "vector addition". Just read the book a bit, you'll get it.
Reply:In order to find the resultant vector of A and B just add the two vectors. Standard dimension wise addition of vectors. Then add C in the same manner to the result of A and B.


For B and C, just add them to find their resultant and then add A. The result will be the same.
Reply:Since you already have the COMPONENTS of the three vectors (i.e., the i, j, and k components), it is easy to see that you can add together the i's, j's, and k's for A and B, and then add those for C,


-O R-


you add together the i's, j's, and k's for B and C, and then add those for A.
Reply:http://www.upscale.utoronto.ca/GeneralIn...


This should help. I learned vectors first graphically, so that might help you move into a numerical way of dealing with vectors, but this is hard because its a new type of math, unlike the scalar math that they teach in everyother math.


Vector Cross Product and Torque II?

1. The cross product of two vectors is... another vector, a scalar, neither?


2. The dot product of two vectors is... another vector, a scalar, neither?


3. The cross product of two parallel vectors is... zero, one,


some other number?


4. For the product C = A x B, the direction of C is.... parallel to A, parallel to B, perpendicular to the plane defined by A and B?


5. The direction of the vector C in the previous question can be found using... the right-hand rule, the left-had rule, the golden rule?

Vector Cross Product and Torque II?
1) cross product of two vectors is a vector, by definition


2) dot product of two vectors is a scalar


3) cross product of two vectors is proportional to the sine of the included angle; for two parallel vectors, the included angle is 0, and the sine of 0 is 0; therefore, the cross product of two parallel vectors is 0


4) the direction of the product of a cross product is perpendicluar to the plane of the other two vectors, by definition


5) the direction of the product of a cross product is given by the right hand rule


Vector magnitude?

Two vectors A and B are given by A = 4i + 8j and B = 6i – 2j. The scalar product of A and a third vector C is –16. The scalar product of B and C is +18. The z component of C is 0. What is the magnitude of C?

Vector magnitude?
Let C = ai + bj + ck. As stated in the problem, c = 0; therefore, C = ai + bj.





A • C = 4a + 8b = −16


B • C = 6a − 2b = 18





Solving this system, a = 2, b = −3.





| C | = √ (2² + 3²) = √13.





Check:


A • C = (4i + 8j) • (2i − 3j) = 4 × 2 + 8 × -3 = −16.


B • C = (6i − 2j) • (2i − 3j) = 6 × 2 + -2 × -3 = 18.


Vector Help please?

Knowing vector A = 98 grams @ 141 degrees,


vector B = (76.2) x unit vectors + (-61.7) y unit vectors, and


vector c = (-150) x unit vector + (-110) y unit vector...


C is also measured in grams for its magnitude.





What is the x-component of the Equilibrant of A+B+C?? in grams

Vector Help please?
x component of (A+B+C)


is (x component of A)+(x component of B)+(x component of C)


= 98g*cos(114)+76.2g-150g=-113g

quince

Magnitude of a vector?

A vector has a magnitude of 188 units and points 30.0deg north of west. Vector B points 50deg east of north. Vector C points 20deg west of south. These three vectors add to give a resultant vector that is zero. Using components, find the magnitude of vector B and vector C

Magnitude of a vector?
It will help if you draw out the vector to know what direction they are pointing at, so that you can determine whether the components are postive or negative.





Let's b and c denote the magnitude of Vector B and vector C:





Components of Vector A: (-188 cos 30) i + (188 sin 30) j





Components of Vector B: (b sin 50) i + (b cos 50) j





Components of Vector C: (- c cos 20) i + (- c sin 20) j





Since the resultant vector is a zero vector, it implies the summation of i component and j component of Vector A, B, C are zero.





i component:





0 = -188 cos 30 + b sin 50 - c cos 20





j component:





0 = 188 sin 30 + b cos 50 - c sin 20








Solve the two equations simultaneously:





you will get:





b = -95.45





c = 95.45


Vector perpendiculars. explanation please!?!?

i still do not quite understand how to find the perpendicular of a vector.


for example given vector B =i hat 3 + j hat 4


find the vector perpendicular to vector B





also.....how do you find angles of vectors?


ex. given C= i hat 12 - j hat 5


find the angles vector C makes with the positive and negaitve axes?.

Vector perpendiculars. explanation please!?!?
Perpendicular vectors have a dot product of zero.





So if V=a*i+b*j and U=c*i+d*j are perpendicular, then





V dot U = 0


or


a*c + b*d = 0.





So if B=3*i+4*j, then to find a vector perpendicular to that,


A=x*i+y*j, we just set up the equation.


B dot A = 0


or


3x + 4y =0.





Notice that all we have to do is switch the components and make exactly one of them negative.





x=-4, y=3 works just fine.





There are an infinite number of possible answers, though, not just one. This is because saying it's perpendicular only specifies the line it's on. It doesn't say which way it points along that line or how long it is.





The angle is, as I posted earlier, given as follows:


if C=x*i+y*j, then


ฮธ=arctan(y/x) if x%26gt;0.


ฮธ=arctan(y/x)+pi if x%26lt;0.





If you're doing it in degrees, change pi to 180 degrees in the second question.





So if C=12i-5j, then


ฮธ=arctan(-5/12) = -.3948 radians or -22.62 degrees.


Science question?

forces can be indicated on graph paper by the use of a)empirical rules b) variables c)vectors d)interaction coefficients

Science question?
vectors. Those are the lines with arrows.


Science questions?

forces can be indicated on graph paper by the use of a)empirical rules b)variables c)vectors d) interaction coefficients

Science questions?
C. Vectors

garden centre

Can anyone help?

differentiate resultant (R) and equilibrant (E) graphical method in the following:


a. addition b. subtraction c. vectors acting @ perpendicular direction, and d. vectors acting @ different angle.

Can anyone help?
The best I can tell you is that the equilibrant is equal in magnitude to the resultant, but opposite in direction. To find the equilibrant force of two or more concurrent forces, first find the resultant force then add 180 degrees to the direction of the resultant (negative of a vector).
Reply:On this site? You nuts?


Vector problem using scalar (dot) and vector (cross) product??

Let vectors A = (2, -1, 1), B = (3, 0, 5), and C = (1, 4, -2), where (x, y, z) are the components of the vectors along x [hat], y [hat], and z [hat] respectively. Calculate:





A * (B x C).


That is, vector A times the cross product between vector B and vector C.





I already know that the cross product between vector B and vector C is |B| * |C| * sin (theta) = 26... I know that I can't just multiply 26 by the magnitude of vector A because when I submitted it, it was wrong. Help please? Thanks in advance!

Vector problem using scalar (dot) and vector (cross) product??
The cross product BxC is a vector. 26 is it's magnitude, but you must also figure out what direction it has.


Then, take your previous answer and multiply it by the cosine of the angle between the vectors A and BxC.





Alternate method:





First, get the actual coordinates of the cross product BxC:


x-component = By*Cz - Bz*Cy


y-component = Bz*Cx - Bx*Cz


z-component = Bx*Cy - By*Cx





If we call this vector "D", then the dot product will be


A.(BxC) = A.D = Ax*Dx + Ay*Dy + Az*Dz


where Dx = x-component calculated above


= By*Cz - Bz*Cy,


and similarly for Dy and Dz.





Hope this helps.
Reply:A*(B x C) is the triple product. You forgot something in


B x C = |B||C| sin(theta). It's


B x C = a[hat]|B||C| sin(theta), where a is a unit vector perpendicular to B and C.


However, that is not the best way of doing this problem. The cross product of B and C can be calculated by finding the determinate of the matrix:


| x[hat] j[hat] k[hat]|


|3 0 5|


|1 4 -2|


where x[hat] = (1,0,0), y[hat] = (0,1,0), z[hat] = (0,0,1)


But since this is a triple product you don't need to do that either (but it's important for you to know).


Just find the determinant of the above, but instead of i, j, k use the components of A; that is, just place the vectors on top of each other to form a matrix.


| 2 -1 1 |


|3 0 5 |


|1 4 -2|


..and find the determinant, which gives you a number, a scaler, which is the triple product.


OK, maybe your matrix stuff is a little rusty. Just in case it is, it goes like this: The triple product A*(B x C) is


2(0*-2 - 5*4) - -1(3*-2 - 5*1) + 1(3*4 - 0*1) =


2*(-20) + (-11) + 12 = -40 + -11 + 12 = -39


But don't take my word for it, check it. I do make mistakes.


Physics help plz...?

Multiplying or dividing vectors by scalars results in








A vectors.


B scalars.


C vectors if multiplied or scalars if divided.


D scalars if multiplied or vectors if divided.

Physics help plz...?
A


Help! Question Below..?

The route followed by a hiker consists of three displacement vectors A, B and C. Vector A is along a measured trail and is 3400 m in a direction 24.1° north of east. Vector B is not along a measured trail, but the hiker uses a compass and knows that the direction is 40.6° east of south. Similarly, the direction of vector C is 33.7° north of west. The hiker ends up back where she started, so the resultant displacement is zero, or A + B + C = 0. Calculate the magnitude of vector B.

Help! Question Below..?
________________________________________





Taking west to east as x- axis and south to north as y - axis





Resolving,vectors A(of magnitude 3400),B and C into components and equating the components along positive x - axis and negative x - axis





B*sin40.6=C* cos33.7-3400*cos24.1





B*0.65077 =C*0.83195 - 3400*0.91283





Dividing by 0.65077 onboth sides,





B =C*1.27841 - 4769.1535..............(1)





Equating the components along positive y - axis and negative y - axis





B*cos40.6 = 3400*sin24.1 + C *sin 33.7





B0.7593 = 3400*0.40833 + C*0.55484..........(2)





Substituting B from equation(1) in equation (2)





(C*1.27841 - 4769.1535)0.7593 = 1388.322 + C*0.55484





C*0.9707 - 3621.2183 = 1388.322 + C*0.55484





C*0.4159 =5009.5403





C = 12045.06 m





substituting for C in eq (1),





B =12045.06 *1.27841 - 4769.1535





B = 15398.525 - 4769.1535





B = 10629.37165 m


__________________________


Magnitudes of vectors A,B and C are given below





A = 3400 m





B = 10629.37165 m





C = 12045.06 m


_____________________________

flower show

Physics hw question?

The route followed by a hiker consists of three displacement vectors A,B, and C. Vector A is along a measured trail and is 1550 m in a direction 28.0° north of east. Vector B is not along a measured trail, but the hiker uses a compass and knows that the direction is 41.0° east of south. Similarly, the direction of vector C is 39.0° north of west. The hiker ends up back where she started, so the resultant displacement is zero, or A+B+C = 0. Find the magnitudes of vector B and C.

Physics hw question?
This is a very simple problem:





All x-component vectors and y-component vectors need to add up to ZERO.





X: Acos(28°) - Bsin(41°) - Ccos(39°) = 0 [1]





Y: Asin(28°) - Bcos(41°) + Csin(39°) = 0 [2]





A = 1550 m





Now we have 2 equations and 2 unknowns, so we solve for B and C:





Equation [1] becomes





C = [Acos(28°) - Bsin(41°)] / cos(39°)





Substitute C into equation [2]





Asin(28°) - Bcos(41°) + ([Acos(28°) - Bsin(41°)] / cos(39°)) sin(39°) = 0





Asin(28°) + Acos(28°) tan(39°) = Bcos(41°) + Bsin(41°) tan(39°)





A(sin(28°)+cos(28°)tan(39°)) = B(cos(41°)+sin(41°)tan(39°))





Therefore,





B = A(sin(28°)+cos(28°)tan(39°)) / (cos(41°)+sin(41°)tan(39°))





= 1427.65 m





C = 555.81 m


How would I find a unit vector perpendicular to plane ABC where points are A(3,-1,2), B(1,-1,-3) and C(4,-3,1)

thanks for help

How would I find a unit vector perpendicular to plane ABC where points are A(3,-1,2), B(1,-1,-3) and C(4,-3,1)
Form two vectors from the three points and then take the cross product.





Given A(3,-1,2), B(1,-1,-3) and C(4,-3,1)





u = AB = %26lt;1-3,-1+1,-3-2%26gt; = %26lt;-2,0,-5%26gt;


v = AC = %26lt;4-3,-3+1,1-2%26gt; = %26lt;1,-2,-1%26gt;





n = u X v = -10i - 7j + 4k = %26lt;-10,-7,4%26gt;





Now we will make it a unit vector by dividing it by its magnitude.





| n | = √(10² + (-7)² + 4²) = √(100 + 49 + 16) = √165





Unit n = %26lt;-10,-7,4%26gt;/√165
Reply:The vector from A to B is in the plane.


The vector from A to C is in the plane.





The vector cross product of the two is perpendicular to both of them and therefore is perpendicular to the plane.





So take (B - A) x (C - A) (vector cross product) and divide it by its length to get a unit vector.





Dan


Anybody good at physics?

Here's the problem:


The route followed by a hiker consists of three displacement vectors, A, B, and C. Vector A is along a measured trail and is 1550 m in a direction of 25 degrees north of east. Vector B is not along a measured trail but the hiker uses a compass and knows that the direction is 41 degrees east of south. Similarly, the direction of Vector C is 35 degrees north of west. The hiker ends up where she started so the displacement is 0 or A+B+C=0. Find the magnitudes of Vector B and C.

Anybody good at physics?
B = 5548.65 m, C = 6158.83m


first, determine how far north, and how far east hiker travels in first 1550m. ie:1550*sin(25)=y1; 1550*cos(25)=x1


now you know that sin(41)=x2/B; cos(41)=y2/B


similarly, sin(35)=y3/C; cos(35)=x3/C


then use the fact that y1+y3=y2, and x1+x2=x3


this is all that is needed for this problem


Any one who knows how to proof the distributive law. please help me?

hay guys i have a big problem with proofing the distributive law.


i dont know how to proof it in a easy way , the main formula is:





vector a X( vector b+ vector c )= vector a X vector b+ vector a X vector c.


i just have to proof that.





big X is not the sign of multiplaction, its just in vectors. i hope you guys know what i mean.

Any one who knows how to proof the distributive law. please help me?
Apply the law to the individual coordinates. Now, use the distributive law of scalars. Q.E.D.





Does that do it?

phone cards

Give an example for which dot product of vector A and vector B = dot product of B and A but A isn't equal to C

A dot B = (magA)(magB)cos(angle)


B dot A = (magB)(magA)cos(angle)





(magA)(magB)cos(angle) =(magB)(magA)cos(angle)





Therefore


A dot B = B dot A


Find the vector equation of the plane that contains the points A(2,5,6) B(-7,1,4) and C(6,-2,-9).?

Does it contain the line with equation


[x,y,z] = [-3,-6,-11]+k[22,1,-11]? varify.

Find the vector equation of the plane that contains the points A(2,5,6) B(-7,1,4) and C(6,-2,-9).?
Given points A(2,5,6); B(-7,1,4); and C(6,-2,-9), find the vector equation of the plane containing them.





Let's create two vectors, u and v, from the points.





u = AB = %26lt;-7-2, 1-5, 4-6%26gt; = %26lt;-9, -4, -2%26gt;


v = AC = %26lt;6-2, -2-5, -9-6%26gt; = %26lt;4, -7, -15%26gt;





The vector equation of the plane P is:





P = A + su + tv = %26lt;2, 5, 6%26gt; + s%26lt;-9, -4, -2%26gt; + t%26lt;4, -7, -15%26gt;


P = %26lt;2 - 9s + 4t, 5 - 4s - 7t, 6 - 2s - 15t%26gt;


where s and t are scalars ranging over the real numbers.


___________________________





Does the plane P contain the line L with the equation





r = %26lt;-3,-6,-11%26gt; + k%26lt;22,1,-11%26gt;


where k is a scalar ranging over the real numbers?





If the given point Q(-3, -6, -11) is in the plane and the vector %26lt;22,1,-11%26gt; lies in the plane, then the line is in the plane.





First let's check the point.





P = %26lt;2 - 9s + 4t, 5 - 4s - 7t, 6 - 2s - 15t%26gt;


Q(-3, -6, -11)





Set each variable of the plane equal to the corresponding value for the point.





x: 2 - 9s + 4t = -3


y: 5 - 4s - 7t = -6


z: 6 - 2s - 15t = -11





y - 2z: -7 + 23t = 16


23t = 23


t = 1





Plug back into z to solve for s.


z: 6 - 2s - 15t = -11


6 - 2s - 15*1 = -11


-2s = -11 - 6 + 15 = -2


s = 1





Now plug into x to check for consistency.


x: 2 - 9s + 4t = -3


x: 2 - 9 + 4 = -3


-3 = -3





This is true so the point Q(-3, -6, -11) lies in the plane.





Now let's check the vector.





P = %26lt;2 - 9s + 4t, 5 - 4s - 7t, 6 - 2s - 15t%26gt;


Q(-3, -6, -11)





We have three equations in three unknowns. Notice we are only setting the components of the vectors equal.





x: - 9s + 4t = 22k


y: - 4s - 7t = 1k


z: - 2s - 15t = -11k





y - 2z: 23t = 23k


t = k





Plug back into z to solve for s.





z: - 2s - 15t = -11k


z: - 2s - 15k = -11k


-2s = 4k


s = -2k





Plug into x for consistency check.





x: - 9s + 4t = 22k


x: - 9(-2k) + 4k = 22k


22k = 22k





The vector also lies in the plane.





The point and vector both lie in the plane so the line lies in the plane.


Graph the image of triangle CAT with vertices C(1, -4), A(5, 6), and T(6, 2) under translation vector p= <-3,

http://i40.photobucket.com/albums/e215/x...

Graph the image of triangle CAT with vertices C(1, -4), A(5, 6), and T(6, 2) under translation vector p= %26lt;-3,
hey they help only for math and they provide 1 free session http://messenger.providesupport.com/mess... and if u want math help they can sure help you just click o this and fill ur name and in question write i want free demo of math as kanpresays


Does anyone know how to write the prigram for this it will C++?

7. File Reading 1 (Points: 30)


1This question has a bonus part (c) worth 10 points.


Consider an input file "data.dat" of the following format (one string and one int number). The data is meant to represent a person and his/her age.


Bob 20


Joe 30


Mary 10


.....





a) (10 points) Determine a data type that is suitable to hold this information in memory. Select a data type that does not require any knowledge about the number of lines in the file. You might want to create a base type (a class) to store the name and the age and a sequential container type (a vector) whose elements are of the type of this class.








b) (20 points) Write a complete program that handles the reading of this file. Structure the program so that a main function defines the necessary data and data types.


The actual reading is done by a function that takes the data structure as a parameter that will be changed in the function. The function opens the file, reads its content and stores the read data in e

Does anyone know how to write the prigram for this it will C++?
Yes, I know how to write the program for this.

orange

Consider a vector z defined by the equation z= (z1)(z2), where z1 =a +jb, z2 = c +jd?

a) show that hte length of z is the product of the lengths of z1 and z2.





b) show that the angle between z and the x axis is the sum of the angles made by z1 and z2 separately.

Consider a vector z defined by the equation z= (z1)(z2), where z1 =a +jb, z2 = c +jd?
hmmm... the vector multiplication is undefined here...





there are 3 kinds of multiplications involving vectors (sometimes with scalars) ...





A. scalar multiplication... an operation between a scalar and a vector...k(a + jb) = ka + jkb





B. dot multiplication or inner product ... a binary operation between two vectors whose result is a scalar number...





C. cross multiplication or cross product... a binary operation between two 3 dimensional vectors whose result is another vector...








Unless you mean a complex number...














§


F=(ycosx,sinx)f=y(1+4x^2)^.5pa... from c: A=(0,0) to B=(1,1) along y=x^2scalar line integral fds =?

Consider the field F: (x,y)=(ycosx,sinx)


and the scalar field f: f(x,y)=y(1+4x^2)^.5


and consider the path from c: A=(0,0) to B=(1,1) along y=x^2


--Determine the scalar line integral of fds


--Determine the vector line integral of Fds





Q: is F a gradient field?

F=(ycosx,sinx)f=y(1+4x^2)^.5pa... from c: A=(0,0) to B=(1,1) along y=x^2scalar line integral fds =?
Parametrise the path A to B by





r(t) = (t, t^2) for t = 0 to 1,





so that





r'(t) = (1, 2t).





The scalar line integral of f along the path is given by





∫ f.ds ∫ f.|r'(t)|.dt = ∫ t^2.(1 + 4t^2)^(1/2).(1 + 4t^2)^(1/2).dt





= ∫ t^2 + 4t^4.dt,





where the integral is taken from t = 0 to 1. Evaluate this to get your answer.





For the vector line integral, first observe that u(x, y) = y.sin x has F as its gradient (it is indeed a gradient field). Then, along our parmetrised line,





d[u(r(t))]/dt = Grad(u(r(t))•r'(t) = F(u(t))•r'(t),








and so the vector line integral of F is given by





∫ F•dr = ∫ F(u(t))•r'(t).dt = ∫ [d[u(r(t))]/dt ].dt = ∫ d[u(r(t))] = u(r(1)) - u(r(0))





= (1^2).sin 1 - (0^2).sin0 = sin 1.


Can someone explain how to create an overloaded assignment operator in C++?

I need an overloaded assignment operator, and a copy constructor. Can't seem to figure it out. The .h file is pasted below.


//Hand.h


//header file


#ifndef HAND_H


#define HAND_H


#include "Card.h"





class Hand


{


public:


Hand();





//overloaded assignement opereator


Hand%26amp; Hand::operator=(Hand%26amp; c);





virtual ~Hand();





//copy constructor


Hand(Hand%26amp; c);





//adds a card to the hand


void Add(Card* pCard);





//clears hand of all cards


void Clear();





//gets hand total value, intelligently treats aces as 1 or 11


int GetTotal() const;





protected:


vector%26lt;Card*%26gt; m_Cards;


};


#endif


//Card.h


//Header File





#ifndef CARD_H


#define CARD_H





class Card


{


public:


enum rank {ACE = 1, TWO, ..};


enum suit {CLUBS, DIAMONDS, ..};





friend ostream%26amp; operator%26lt;%26lt;(ostream%26amp; os, const Card%26amp; aCard);





Card(rank r = ACE, suit s = SPADES, bool ifu = true);





//returns the value of a card, 1 - 11


int GetValue() const;


//flips a card


void Flip();


private:


rank m_Rank;


suit m_Suit;


bool m_IsFaceUp;


}

Can someone explain how to create an overloaded assignment operator in C++?
The purpose of both those methods is to create an instance of the class that is identical in behavior to an existing instance.





If you don't declare them yourselves, the compiler will do it for you if required and if it's possible for it to do so. So unless you have something specific to do in the copy, one normally let the compiler take care of generating them. The compiler will produce a version which simply copy each of the variable from one instance to the other.





If you do require to perform something different (which is normally the case if any of your members are pointers, you then redefine them.





Hand%26amp; Hand::operator=(const Hand%26amp; c);


Hand(const Hand%26amp; c);





Here your only member is a vector of card*. So both method would consist of inserting each card from the existing instance vector, and inserting them in the new instance vector. BUT you have to decide if the second instance will insert the exact same card in it's vector, or an identical copy of it. If you insert the same cards, they can't be deleted or modified by any of those hand without affecting the other and this is a big problem, and unless you have a card manager that is responsible for that this solution is very dangerous. So you're better to insert identical copy of the cards in the second vector. Which will require a copy constructor and assignment operator on the card too.. Or at least a clone method, which will allow you to create a copy of each card found in the first hand, and insert them into the second hand vector.





This being said, you will need a copy constructor and assignment operator for the class hand. But that class is quite simple, and the compiler will normally be able to produce them for you, since it only contains plain values.


Puggy, Whats the smallest prime factor of 100! + 1?

Hi everyone,





If c (vector b)- (vector a) = -3/4d (vector a) + 1/4d (vector b) , where


c and d are constant unknowns , can you conclude that





d=4/3 and c=1/3 through direct comparison of the coefficients of vector


a on the right hand side and the coefficients of





vector a on the left hand side to find d and then do the same for the


coefficients of vector b?





Is there any rule for using direct comparison? I feel that the vectors


must intersect before you can use direct comparison





because if you use the i, j , k in column form to replace vectors b and


a, they must intersect in order for all three levels of the





right and left hand side to have the same c and d. I'm getting confused


so anyone has any explanation?





I usually move all vector b to one side and all vector a to one side and


use the rule that if (c-1/4d)(vector b)= (1-3/4d)(vector





a), since vector a and vector b are not parallel, for vector b to be


equal to vector c, c-1/4d=0 and 1-3/4d=0.

Puggy, Whats the smallest prime factor of 100! + 1?
I hope you don't mind, I am just interested in the initial question. The answer is 101. If you work mod 101, then 100 = -1 So to prove that 100! +1 = 0, you need to prove that 99! = 1. For that it is enough to show that the numbers between 2 and 99 can be put in 49 pairs (p,q) such that pq=1. But Z/101Z is a field and this reduces to showing that no number is such that p^2=1. This can be checked easily because 102,203, 304 up to 2425 are not squares and that's it.
Reply:I only can tell that it is greater than 97 because the given number is not divided by any prime factor minor or equal to 97


a) As you write that vectors a and b are not paralel


the last equations you wrote are true becaus if they are NOT zero that means that both vector are paralel

flash cards

A Vector class is what among the following a)is public,b)is final,c)implements java.util.ArrayList?

a) is Public

A Vector class is what among the following a)is public,b)is final,c)implements java.util.ArrayList?
a


What does line integral with respect to arc-length on the cuve C mean?

We're studying some basic vector calculus in my class right now. I can't seem to grasp this.





The first question is just that -


S.c ds (S.c = integral over curve c), where c is a line segment from (0,0) to (0,1). It is obvious that it will be 1. But I don't _really_ understand the concept.

What does line integral with respect to arc-length on the cuve C mean?
♠ indeed example of yours is not much illustrative for peculiarities of linear integration! To feel what is linear integration about you should consider a typical problem from Physics like this one:


♣ let vector F=F(x,y) be a force field of a set of electric charges, acting on a charge q being moved along the path C=C(x,y) from point A=C(x1,y1) to point B=C(x2,y2); Question: what is work done on the charge?


♦ Solution: work =∫(ds·F) from A to B, where (F·ds) is dot product of elementary vector ds along curve C(x,y) by vector F(x,y);


♥ in your example F=1*i, ds=i*dx; A=(0,0), B=(0,1); work=1;
Reply:Perhaps an example may help you. Assume you have a two variable function f(x,y) that takes real values, i.e. at each point (x,y) in the plane the function takes a scalar real value f(x,y). The line integral along a curve or path C in the plane represents the sum of all the values of f(x,y) for all points *on* the curve C, scaled by the arc length along C. This is the limit process of a summation of values of f(x,y) at a finite sequence of points in C scaled by the distance between each successive pairs of points.





A visual image is very good in my experience. Imagine the projection of the C curve onto the surface f(x,y). You will have a curve on f(x,y). Color all the z coordinates of points on this curve. Then you will get a curved 2D surface. The line integral along C is the area of this 2D surface scaled by arc length of the segment of C that you are using in your integral.





So, concerning your example with the curve C being the line between (0,0) and (0,1) that takes a constant value 1 (you only have ds inside the path integral).





Then f(x,y) = 1 is the flat plane at z = 1 spanning all directions in 3D space. C is the segment of line y = 1 between (0,0) and (0,1). This line projects onto the plane z=1 as I mentioned before. All points on this line segment have z value 1, i.e. f(x,y) is 1. Moreover the length in the xy plane has length 1. The area of the square that forms is 1x1, i.e. 1, and this is the value of the line integral.

flower girl

In C++, how do I use the STL sort command to sort a vector of template class objects?

Here is what I have in mind. It compiles, but will it work? Can't run the program yet.





Key is one of the private elements in the class, it's either an int or a string.





sort(imaVector.begin(Key), imaVector.end(Key))

In C++, how do I use the STL sort command to sort a vector of template class objects?
// Opless.cpp


// compile with: /EHsc


// Illustrates the defining the %26lt; operator to sort vectors


//


// Functions:


//


// operator%26lt; - Vector comparison operator.


//


// vector::begin - Returns an iterator to start traversal of the vector.


//


// vector::end - Returns an iterator for the last element of the vector.


//


// vector::iterator - Traverses the vector.


//


// vector::push_back - Appends (inserts) an element to the end of a


// vector, allocating memory for it if necessary.


//


// sort algorithm - Sorts the vector.


//


//////////////////////////////////////...





// The debugger can't handle symbols more than 255 characters long.


// STL often creates symbols longer than that.


// When symbols are longer than 255 characters, the warning is disabled.


#pragma warning(disable:4786)





#include %26lt;iostream%26gt;


#include %26lt;vector%26gt;


#include %26lt;string%26gt;


#include %26lt;algorithm%26gt;





using namespace std ;





// The ID class is used for team scoring. It holds each player's name


// and score.


class ID


{


public:


string Name;


int Score;


ID() : Name(""), Score(0) {}


ID(string NewName, int NewScore) : Name(NewName), Score(NewScore) {}


};





// In this example, an ID is equivalent only if both name and score match.


bool operator==(const ID%26amp; x, const ID%26amp; y)


{


return (x.Name == y.Name) %26amp;%26amp; (x.Score == y.Score);


}





// IDs will be sorted by Score, not by Name.


bool operator%26lt;(const ID%26amp; x, const ID%26amp; y)


{


return x.Score %26lt; y.Score;


}





// Define a template class for a vector of IDs.


typedef vector%26lt;ID%26gt; NAMEVECTOR;





int main()


{


// Declare a dynamically allocated vector of IDs.


NAMEVECTOR theVector;





// Iterator is used to loop through the vector.


NAMEVECTOR::iterator theIterator;





// Create a pseudo-random vector of players and scores.


theVector.push_back(ID("Karen Palmer", 2));


theVector.push_back(ID("Ada Campbell", 1));


theVector.push_back(ID("John Woloschuk", 3));


theVector.push_back(ID("Grady Leno", 2));





cout %26lt;%26lt; "Players and scores:" %26lt;%26lt; endl;


for (theIterator = theVector.begin(); theIterator != theVector.end();


theIterator++)


cout %26lt;%26lt; theIterator-%26gt;Score %26lt;%26lt; " "


%26lt;%26lt; theIterator-%26gt;Name %26lt;%26lt; endl;


cout %26lt;%26lt; endl;





// Sort the vector of players by score.


sort(theVector.begin(), theVector.end());





// Output the contents of the vector in its new, sorted order.


cout %26lt;%26lt; "Players ranked by score:" %26lt;%26lt; endl;


for (theIterator = theVector.begin(); theIterator != theVector.end();


theIterator++)


cout %26lt;%26lt; theIterator-%26gt;Score %26lt;%26lt; " "


%26lt;%26lt; theIterator-%26gt;Name %26lt;%26lt; endl;


}


Output


Players and scores:


2 Karen Palmer


1 Ada Campbell


3 John Woloschuk


2 Grady Leno





Players ranked by score:


1 Ada Campbell


2 Karen Palmer


2 Grady Leno


3 John Woloschuk


At time t=0, a boat is travelling due east at a speed of 3ms.The vectors i and j are directed east and north.?

a)Write down the initial velocity of the boat in vector form?





b)The boat has a constant acceleration of (0.1i + 0.2j)ms =. Find an expression for the velocity of the boat at time, t seconds?





c)When t=T, the boat is travelling north east. Form an equation that T must satisfy, and solve it to show that T = 30?





d) Find the distance of the boat from its initial position when t = 20?

At time t=0, a boat is travelling due east at a speed of 3ms.The vectors i and j are directed east and north.?
a) (3,0) or 3i








b) (3,0) + (0.1t + 0.2t) = (3+0.1t,0.2t)





c) Northeast means that speed in direction i is same as speed in direction j:


3+0.1T = 0.2T -%26gt; 3 = 0.1T -%26gt; T = 30





d) x = v_init * t + acc * t²


(x,y) = (3,0) * t + (0.1,0.2) t² = (60,0) + (40,80) = (100,80)


So position at time t = (100,80)


Distance to (0,0) is sqrt(100² + 80²) = 128 m
Reply:What is a speed of three milliseconds?





Here it is in vector form:


%26lt;-------





I can't be bothered to answer the rest of your homework. Do it yourself f'r chrissakes.


Sieve of Erathosthenes Algorithm in C++ Language (Finding all prime numbers)?

I need Eratosthenes Algorithm in C++ language (to find out prime numbers). I can write it in a few other ways, but I need to do it using a a vector container for the integers, and an array of bool initially set to true to keep track of the crossed off numbers. also by Changing the entry to false for integers that are crossed off the list.


I will appreciate any help. Partial code, if not all. Thank you very much.

Sieve of Erathosthenes Algorithm in C++ Language (Finding all prime numbers)?
I ran this a long time ago:





http://gd.tuwien.ac.at/perf/benchmark/ab...


Write a function that creates a vector of user-given size M using new operator in c++?

Assuming you need an int vector:





vector%26lt;int%26gt; createVector(int size)


{


vector%26lt;int%26gt; *vect;


for(int i = 0; i %26lt; size; ++i)


{


vect = new vector%26lt;int%26gt;();


}


return *vect;


}





Don't forget to delete it when finished.

curse of the golden flower

Another C++ input question; cin and strings.?

K so if someone has a compiler on them they may be able to tell me or if you know anyway;





Suppose I declare an array of 5 strings.





vector%26lt;string%26gt; word(5);





The I use cin to input values saying;





cin%26gt;%26gt;word(0)%26gt;%26gt;word(1)%26gt;%26gt;word(2)%26gt;%26gt;word(3...





When the program runs and I am prompted for input I write.





" apples bear lemon party "





With all these spaces in there, will C pick out the words and store them in their respective string variables?





Are the vals:





word(0) is "apples"


word(1) is "bear"


word(2) is "lemon"


word(3) is "party"





-What is word(4), is it " " ie a single space, is is a number of spaces, or is it some weird thing without a value or a random value?


Can I use a simple if statement to check for such blanks?





if(word.at(4) == ' ') %26lt; does this actually tell me if it's blank?

Another C++ input question; cin and strings.?
word(4) will be whatever the default value for a vector is. You can't accept whitespace in cin, for that you need to use getline. However comparing word(4) == "" will tell if it is an empty string.





Also be careful with strings and characters:


" - for strings


' - for characters


Operator overloading in c++?

How do I overload the [] operator in c++? I have a card deck class where I want to access cards by deck[1], instead of deck.getCard(1).





Note: I have a private vector where I am storing the cards.

Operator overloading in c++?
int operator [] (int ndx)


{


// put anything you want here to accesss


// element "ndx". Just return the value


// of that element as the return value of


// this function.


return value_of_ndx_element_of_your_vector;


}
Reply:Lost me with vectors, but I do a web search for c++ tutorials and most allow you to search their sites for specific answers.


DEV-C++(How to create a 2d-array)?

I need to create a 2 dimension array .whats the code to create a 5 rows and 10 columns vector of any numbers then finding the maximum ,minimum and average value.I am using DEV - C++.Help please!

DEV-C++(How to create a 2d-array)?
I hope you have a rough idea of what you're doing, cause I'm going to just psuedocode this really quick. Without you giving me a head start, it will take me forever. Question though, are you making an array? or a vector? they're different you know, vectors dont need to be a set size initially for example. Below is an array.





int row = 4;


int column = 9;


int number; //inputted number


int min=0; //for comparing for min


int max = 0; //comparing for max


int avg;


int array[row][column]; //here is your array - i might have gotten them switched





for(int i=0; i%26lt;5; i++) //loop to go thru row


{


for(int j = 0; j%26lt;10; j++) //nested loop to go thru column


cin %26lt;%26lt; number;


}





for (i=0; i %26lt; 5; i++) //loop again for finding max min avg


{


for (int j=0; j%26lt;10; j++)


{if number %26gt; max


max = number


//compute stuff for min, and average here


}


}





ok lost my train of thought, you can do the rest.... =)
Reply:double[5][10] vector; //definition





for(int i=0; i%26lt;5; i++)


for(int j=0; j%26lt;10; j++)


cin%26gt;%26gt;vector[i][j]; //reads element from row i and column j





double maximum = vector[0][0];


posR = 0;


posC = 0;





for(int i=0; i%26lt;5, i++)


for(int j=0; j%26lt;10; j++)


if (maximum%26lt;vector[i][j])


{


maximum = vector[i][j];


pozR = i;


pozC = j;


}





maximum - the value of the max element.


pozR+1 - the row maximum is found on


pozC+1 - the column maximum is found on





If more than one element has the value of maximum, the first occurrence is taken into account.





minimum goes the same way, the only difference is that you check whether minimum%26gt;vector[i][j].





sum = 0;


for(int i=0; i%26lt;5; i++)


for(int j=0; j%26lt;10; j++)


sum+=vector[i][j];





double average = sum/50;





The total number of element is 5*10 = 50 (no of rows multiplied by no of columns).





P.S. you can calculate all 3: max, min and avg during one single parsing of the vector. Lessens time.


How do I overload the ">>" function to take vectors?

In C++ how can this be done? I've been trying this literally all day... So far I have this:


istream%26amp; operator%26gt;%26gt; (istream%26amp; stream, vector%26lt; int %26gt;%26amp; a )


{


stream%26gt;%26gt;a;





return stream;


}








and it exits after I put in one input from the main function?


What should I do?

How do I overload the "%26gt;%26gt;" function to take vectors?
Hello,





You are misusing the contents of the overload operator, you cannot simply do stream %26gt;%26gt; a; You have to actually use the stream operator to do some stuff to the input. Since your using a vector, you need to add items inside the vector.





For example, you would need to treat the operator %26gt;%26gt; to what the stream operator will act. To make that work say we are going to use a cin as a stream input. For cin, if we are doing stream %26gt;%26gt; input, input must be a string for it to work, you cannot directly input it to a Vector. Since the vector contains Integer Values, you must input an integer value...





---


// Input string variable


string input;


// I am assuming I am doing cin %26gt;%26gt; myVector


// So %26gt;%26gt; in reality is a String


stream %26gt;%26gt; input;


// We must convert string to int to place into vector


// Using the #include %26lt;sstream %26gt; to stream it into an int


stringstream tempStream(input);


int tempInt;


tempStream %26gt;%26gt; tempInt;


// Push that int to the Vector


a.push_back( tempInt );


return stream;


---





Using the above example as the overloaded operator method, it will add the number inputed by cin stream to that vector. I could do the following to make it work. It will print out 3 as the size of the vector.





----





vector%26lt;int%26gt; a;


cout %26lt;%26lt; "Enter a number";


cin %26gt;%26gt; a;


cout %26lt;%26lt; "Enter a number";


cin %26gt;%26gt; a;


cout %26lt;%26lt; "Enter a number";


cin %26gt;%26gt; a;


cout %26lt;%26lt; "Size of Vector: " %26lt;%26lt; a.size() %26lt;%26lt; endl;


----





I will show you a simple way to add items to the vector in a loop, using the cin %26gt;%26gt; myVector. So I am going to overload the Vector with the cin stream so that I can always add items into the vector without stopping until I say CTRL+Z. You can look at the final result C++ class nicely formatted here: http://mohamed.mansour.pastebin.com/f4c0...








The main program will look like the following:


--------------------------------------...


int main()


{


// The vector


vector%26lt;int%26gt; a;





// Lets input values to that vector


// Overolading


cin %26gt;%26gt; a;





// Print the size of the vector


cout %26lt;%26lt; "Size of Vector: " %26lt;%26lt; a.size() %26lt;%26lt; endl;


return 0;


}


--------------------------------------...








The program output will look like the following:


--------------------------------------...


Enter your Input: Ctrl-Z to quit


1


Enter another Input: Ctrl-Z to quit


2


Enter another Input: Ctrl-Z to quit


3


Enter another Input: Ctrl-Z to quit


^Z


Size of Vector: 3


Press any key to continue . . .


--------------------------------------...





As you notice, I overloaded the Vector for the stream which is cin. And the output was nice and cool. You cannot say stream %26gt;%26gt;, because you have to somehow deal with that stream. I am using it with getline. You could expand this overload to decide what Stream object is going in, by just checking what type it is. For this problem, it is a cin stream.


--------------------------------------...


//overloaded input operator


istream%26amp; operator%26gt;%26gt; (istream%26amp; stream, vector%26lt; int %26gt;%26amp; a )





{


string input;


cout %26lt;%26lt; "Enter your Input: Ctrl-Z to quit" %26lt;%26lt; endl;


while(getline(stream,input))


{


// Convert from string to int


stringstream tempStream(input);


int tempInt;


tempStream %26gt;%26gt; tempInt;





// Push it to the Vector


a.push_back( tempInt );


cout %26lt;%26lt; "Enter another Input: Ctrl-Z to quit" %26lt;%26lt; endl;


}


return stream;


}


--------------------------------------...





AS you notice, it worked great, I treated the input stream and overloaded its operator. I hope that will help you do whatever you need accomplished.





Good Luck
Reply:%26lt;Chuck Norris%26gt;%26lt;ROBIN WILLIAMS%26gt;%26lt;BLAH%26gt;

apricot

Find the coordinates of the image of triangle CAT with vertices C(-2, 3), A(-5, 7), and T(0, 5) under translat

Find the coordinates of the image of triangle CAT with vertices C(-2, 3), A(-5, 7), and T(0, 5) under translation vector p= %26lt;-4, 1%26gt; and vector q= %26lt;6, -3%26gt;. Help, I cant figure these problems out!!

Find the coordinates of the image of triangle CAT with vertices C(-2, 3), A(-5, 7), and T(0, 5) under translat
C(-2, 3), A(-5, 7), and T(0, 5)


Translate by %26lt;-4, 1%26gt;


C1(-6, 4), A1(-9, 8), and T1(-4, 6)





C(-2, 3), A(-5, 7), and T(0, 5)


Translate by %26lt;6, -3%26gt;


C(4, 0), A(1, 4), and T(6, 2)


Given the flow with V=(C/r)e(r), where e(r) is the unit vector in polar coordinates directed along the radial?

direction. What are the u (x) and v(y) components of this flow?

Given the flow with V=(C/r)e(r), where e(r) is the unit vector in polar coordinates directed along the radial?
The u component: C/r [e(r) ∙ e(x)];


the v component: C/r [e(r) ∙ e(y)];


where e(x), e(y) are unit vectors in the x, y directions, respectively, otherwise known as unit vectors i, j. The dot indicates inner (dot) product between vectors.


Can someone help me solve this problem about vectors?

a quarterback throws a football with a speed of 48 feet per second at an angle of 45 degrees upward from the ground. the vector that describles the motion of the football is





a 34i + 34j


b 68i + 68j


c 30i + 30j


d 34i - 34j

Can someone help me solve this problem about vectors?
the angle is 45 degrees





construct a triangle that has hypotenuse of 48


by pythagorean theorem


a^2+b^2=c^2





a and b are the same for a 45 degree triangle


thus





2a^2=48^2


2a^2=2304


a^2=2304/2


a=48/sqrt2 which is approx 34





so 34i +34j is correct because the ball is going up initially





34i-34j is throwing the ball down


68i+68j is multiplying by sqrt2 , not dividing
Reply:None of the above.





If you *throw* a football at an angle of 45 degrees upward, the football doesn't *travel* at an angle of 45 degrees. It goes in an arc, and eventually hits the ground.
Reply:the answer is A
Reply:The magnitude of the vector is 48 fps, and its direction is 45 deg from the x-axis.


The x-component of the vector is 48cos45 = 48(0.707) = 34


The y component of the vector is 48Sin45 = 48(0.707) = 34


Therefore, the vector is 34 i + 34 j; answer a)
Reply:what's your vector Victor?
Reply:My brain hurts.


Physics question about electric field and vectors.?

Two equal charges of 5 C are located in the xy-plane, one at (0m, 57.9) and the other at (75.9m, 0m).


a) find the magnitude of the electric field at the origin to these two charges.


b) find the angle between the vector for the electric field and the origin and a vector in the minus x-direction. Answer in degrees.





I found the answer to part a) to be - 1.8179E-5 by using coulombs law and then the Pythagorean theorem.





i tried -tan for the angle and got 30 degrees but thats incorrect.





please if u know how to do this problem explain it to me.. i need to this hw by tonight and i cant find it anywhere else.





thanks in advance

Physics question about electric field and vectors.?
let coordinates of point charges be (x,0) %26amp; (0,y), and let unit vectors along (+x,+y)) be (+i, +j)


------------------------


placing a +ve charge (qo) at origin.


--------------------


(x,0) charge will tend to repel test charge along -x direction with force (Fx) linked to electric vector component (Ex) by


-----------------------------


Fx = qo Ex = 9*10^9 *5qo/x^2


-------------------------


(0,y) charge will tend to repel test charge along -y direction with force (Fy) linked to electric vector component (Ey) by


Fy = qo Ey = 9*10^9 *5qo/y^2


--------------------------


net electric field vector


E = Ex (-i) + Ey (-j)


E = - 9*10^9 *5 [ i /x^2 + j /y^2]


put values of x, y


E = - 9*10^9 *5 [ i /75.9^2 + j /57.9^2]


E = - 10^6[ 45000 i /5760.81 + 45000 j /3352.41]


E = 10^6[ - 7.81 i - 13.42 j] %26gt;%26gt;%26gt;%26gt;%26gt;%26gt;


magnitude of (E)


|E| = 10^6[7.81^2 + 13.42^2]^1/2 = 15.53*10^6 N/C


direction


tan (p) = Ey/Ex = - 13.42*10^6/ - 7.81*10^6 = 1.7183


p = angle made by (E) vector with (-x) axis measued anticlockwise = tan^-1[1.7183] = 59.8 degree

song words

Thursday, July 30, 2009

Force and Vectors?

Two horizontal forces act on a 3.5 kg chopping block that can slide over a frictionless kitchen counter, which lies in an xy plane. One force is F1 = (3.1 N)i + (7.8 N)j. Find the acceleration of the chopping block in unit-vector notation when the other force is (a) F2 = (-3.1 N)i + (-7.8 N)j, F(b) 2 = (-3.1 N)i + (7.8 N)j, and (c) F2 = (3.1 N)i + (-7.8 N)j.

Force and Vectors?
I'llshow you how to do part a. You can do the others - homework is good for the soul %26amp; it teaches you how to do things yourself :%26gt;)





a. Net force = Fn = F1 + F2 (everything is a vector)





accleration a = Fn/m = (F1 + F2)/m (m is mass, a scalar)





a =[3.1 i + 7.8 j + (-3.1) i + (-7.8) j]/3.5 m/s^2





a = (0 i + 0 j)/3.5 m/s^2 = 0 i + 0 j m/s^2 no accleration the forces cancel.


Let R be the rectangle with vertices (0,0), (3,0), (0,9), (3,9), and let C be the boundary of R traversed?

Let R be the rectangle with vertices (0,0), (3,0), (0,9), (3,9), and let C be the boundary of R traversed counterclockwise. For the vector field F(x,y) = 3yI+xJ,





find the integral:








⌡C (F·dX)





Where C is the lower bound.

Let R be the rectangle with vertices (0,0), (3,0), (0,9), (3,9), and let C be the boundary of R traversed?
since the integral is taken over x the whole boundary can be dividad into two domains


1) (0,3) whr y = 9


2) (3,0) whr y = 0


now its just simple integration
Reply:Let C1 be the part of C from (0,0) to (3,0). Along C1, y has the constant value of 0, and dX = (dx)I. So along C1,





F·dX = (3y evaluated at y=0) = 0 So





∫ F·dX = 0


C1





Let C2 be the part of C from (3,0) to (3,9). Along C2, x has the constant value of 3, and dX = (dy)J So along C2,





F·dX = (x evaluated at x=3) = 3 So





∫ F·dX =


C2





9


∫ 3 dy = 27


0





Let C3 be the part of C from (3,9) to (0,9). Along C3, y has the constant value of 9, and dX = (dx)I So along C3,





F·dX = (3y evaluated at y=9) = 27 So





∫ F·dX =


C3





0


∫ 27 dx= -81


3





I'll let you do C4. You will find that the integral over C4 is zero.





So





∫ F·dX = 0 + 27 - 81 + 0 = -54


C





You could also do this problem using Green's Theorem, which says this line integral is equal to





∫∫ (∂(x)/∂x - ∂(3y)/∂y) dx dy


A





where A is the region enclosed by C. Since





(∂(x)/∂x - ∂(3y)/∂y = -2, the integral is equal to -2 * area enclosed by C





= -2*9*3 = -54


Are people still teaching that mass increases as speed approaches c?

An interesting phenomenon around here... LOTS of people answering relativity questions referring to the increase of mass as speed approaches c.





This is an obsolete interpretation. In modern physics literature, the word "mass" always refers to rest mass. The variable M always refers to mass, which always refers to rest mass.





It's obsolete for very good reasons: you can't correctly calculate effects of gravity using "relativistic mass;" relativistic mass is not invarient, but rest mass is. Even if you're using it to illustrate changes of inertia, it's different in different directions: you'd have to give a particle a different mass for each of x,y, and z motions. Scalar, invarient mass becomes a noninvarient vector. Messy.





When you explain that bodies cannot travel at c by explaining that they get more and more massive, it easily misleads the asker into thinking that if they were to travel at c they would become fatter and fatter in their own reference frame, which is clearly untrue.

Are people still teaching that mass increases as speed approaches c?
In Einstein's equation, E = mc^2, m is not the rest mass, but rather the mass of the particle in motion.
Reply:The word rest mass means that its sitting on a rest frame that is absolute. Hence since there is according to Relativity no such thing. Hence rest masses dont exist since all masses in the Universe are continually moving. Report It

Reply:I've never used the term mass in this context without putting the word "apparent" in front of it.





That is, the apparent mass of an object increases asymptotically as its speed approaches that of light.





Being, at best, an arm chair physicist, I may well be mangling things. Would you consider my usage correct?


Physics Question about vectors!?

The velocity vector V1 has a magnitude of 3m/s and is directed along the +x-axis. The velocity vector V2 has a magnitude of 2m/s. The sum of the two is V3, so that V3 = V1+V2


(For each statement select T-True, or F-False; If the first is True and the rest F, enter TFFFFF).





A) The magnitude of V3 can be 0


B) The magnitude of V3 can be 2m/s


C) The magnitude of V3 can be -2m/s


D) The magnitude of V3 can be 6m/s


E) The x-component of V3 can be 0m/s


F) The magnitude of V3 can be 5m/s

Physics Question about vectors!?
The largest that V3 can be is 5 m/s, if V2 is also in the positive x direction. The smallest it can be is 1 m/s, if V2 is in the negative x direction. Its magnitude can also have any value between 1 m/s and 5 m/s (if V2 makes some angle with the x axis).





A. False.


B. True.


C. False.


D. False.


E. False.


F. True.

song titles

PHYSICS HELP - velocity & vectors?

.


PLEASE EXPLAIN BRIEFLY AND LABEL ANSWERS!


.


A helium balloon rises upward at rate of 7.0 metres/second, to a height of 20 m before it pops. A steady breeze od 1.5 m/s due east blows against the balloon.





A) What is the velocity of the balloon relative to the ground?





B) How long does it rise before popping?





C) How far from its starting point has it flown (final displacement)?





- - -





A firefighter climbs up 10.0 m ladder leaning against a vertical wall. The ladder makes an angle of 20 degrees with the wall. The firefighter reaches the roof in 15.0 s.





A) What is the height of the wall?





B) How far is the base of the ladder from the wall?





C) What is the firefighter's average vertical velocity?





- - -





Suzanne is skiing with a velocity of 18.0 m/s [N30.0 degrees W]. What is the [N] component of her velocity vector?





- - -





Tim is running cross-country at 6.4 m/s [S] when he completes a wide turn and continues at 5.8 m/s [W]. What is his change in velocity?

PHYSICS HELP - velocity %26amp; vectors?
So many questions for one post...





1A)- Upward at 7.0m/s, east at 1.5m/s. That's a right triangle, and the velocity will be the hypotenuse, which will be





SQRT(a^2 + b^2) =


SQRT(7.0^2 + 1.5^2) =


SQRT(49 + 2.25) =


SQRT (51.25) =~7.159m/s speed, relative to the ground. As for the angle it makes with the ground, remember that definition of tangent is the opposite/adjacent, so the tangent of the angle with the ground is 7/1.5 = 4.666... so the angle itself is the arctan of that number, or 77.9 degrees. So the velocity is





7.159m/s, eastward, 77.9 degrees up





1B) - Simply 20m/7m/s = 20s/7 =~2.857s





1C) - 7.159m/s * 2.857s =~ 20.454m


PHYSICS HELP - velocity & vectors?

.


PLEASE EXPLAIN BRIEFLY AND LABEL ANSWERS!


.


A helium balloon rises upward at rate of 7.0 metres/second, to a height of 20 m before it pops. A steady breeze of 1.5 m/s due east blows against the balloon.





A) What is the velocity of the balloon relative to the ground?





B) How long does it rise before popping?





C) How far from its starting point has it flown (final displacement)?





- - -





A firefighter climbs up 10.0 m ladder leaning against a vertical wall. The ladder makes an angle of 20 degrees with the wall. The firefighter reaches the roof in 15.0 s.





A) What is the height of the wall?





B) How far is the base of the ladder from the wall?





C) What is the firefighter's average vertical velocity?





- - -





Suzanne is skiing with a velocity of 18.0 m/s [N30.0 degrees W]. What is the [N] component of her velocity vector?





- - -





Tim is running cross-country at 6.4 m/s [S] when he completes a wide turn and continues at 5.8 m/s [W]. What is his change in velocity?

PHYSICS HELP - velocity %26amp; vectors?
Balloon


A) The balloon's horizontal component of velocity quickly matches the wind speed. So you need to add perpendicular vectors. Add the 7.0 metres/second vertical and the 1.5 m/s due east. The magnitude of the resultant velocity is the hypotenuse of a right triangle with the 2 perpedicular sides being 7 versus 1.5. I hope you can handle the vector math if you're getting problems like this.





B) Supposedly it starts from the ground with a vertical velocity of 7 m/s right from the start -- no acceleration. So use


v = y/t


where v is 7 m/s and y is 20 m.





C) Use


v = y/t


where v is the magnitude of the resultant found for part A and t is from B.





Firefighter


A) Hmm, it doesn't say, do you think the ladder reached the top of the wall? It could be that the ladder only reaches halfway up the wall. But I don't see a way to calculate wall height without assuming it reaches the top. The 10 m ladder is the hypotenuse.


cos20 = y / 10 m should do it





B) sin20 = x / 10 m





C) Vv = y / t


where y is from A and t = 15 s.





Skiing


These are really just trig. Her velocity has a northward component and a westward component. Her 18.0 m/s velocity is the hypotenuse. Try cos.





X-country


I'm not sure how they mean that. Perhaps you could say the change is -0.6 m/s and 90 degrees to the right.


Vectors? I hate these things...just confusing, haha?

Vector B is in the third quadrant, therefore its x and y components are negative. If B's direction is 246 (counter-clockwise from the positive x-axis) then which expression best describes B's x-component?





a)B cos(246)


b)B sin (66)


c)B sin (246)


d)B cos (66)


e)B tan (66)


f) B tan (246)

Vectors? I hate these things...just confusing, haha?
the x component of a vector is always calculated by it's size multiplied by the cosine of the angle between the positive x-axis and the vector (counter clockwise....)


so (a) is the right answer.





note that cos(246) is a negitive quantity so we don't have to worry about plus or minus sign...
Reply:B cos(246)
Reply:Letter (a). Of course, the answer is negative because


cos(246 degrees) is negative.


Using C++ to write a tic tac toe game?

Hi I'm writng a c++ program using classes to write a tic tac toe program ( actually it's a Gomoku game, same thing except five in a row instead of 3). I have the board constructed using a 2 D vector, but now I need to come up with a function (isWinner) that will tell me if a player has five in a row, column or diagonal. Does anyone have a suggestion? The header file looks like this:





class Gomoku


{


private:


vector%26lt;vector%26lt;int%26gt; %26gt; board;//sets up multi D vector


int size;


public:


Gomoku();


Gomoku(int h);//Constructor, takes one integer.


void draw(int);//Draws present board position;takes no argument; no return.


bool place (int a, int b, int c);//a=player,b=row,c=column


//puts players stone on board


//returns true/falsebased on whether move was legal or not.


bool isWinner (int d, int e);//d=row, e=column; returns boolean indicating if postion is a winn

Using C++ to write a tic tac toe game?
Well Ill answer this for tic tac toe, and you can extract what I say to fit your Gomoku game.





Because the state space (the possible winning situations) is small in number when it comes to tic tac toe we can compare the current situation against all the possible winning situations.





supposing you represent a X by the integer 1, a O by the integer 0 and a not played yet by -1 then you will have some kind of vector that has some configuration of 1's 0's and -1's in it.





There are 8 possible winning situations for each player (in tic tac toe) for example for player X (or 1) we can compare against:





((1,-,-),(-,1,-),(-,-,1)) -- horizontal


((1,-,-),(1,-,-),(1,-,-)) -- left column


((-,1,-),(-,1,-),(-,1,-)) -- middle column


((-,-,1),(-,-,1),(-,-,1)) -- right column


((1,1,1),(-,-,-),(-,-,-)) -- top row


((-,-,-),(1,1,1),(-,-,-)) -- middle row


((-,-,-),(-,-,-),(1,1,1)) -- bottom row


((-,-,1),(-,1,-),(1,-,-)) -- other horizontal





where eash - is a dont care position (that is we dont care what is in it). You would have the same comparisons against the O player except using 0's instead of 1's. For more complex games this state space can become too large to be effective but for your question it will work effectively and quickly.





good luck.

song downloads