Find a vector function that represents the curve of intersection of two surfaces and the tangent vector Consider the curve $C$ obtained by intersecting the surfaces defined by
$$x^2+y^2 + z^2=3$$ and $$x^2-y^2+z^2 =1$$
At the point $(1,1,1)$, which of the following is a tangent vector to the curve?
The answer to this question is $(2, 0, -2)$ , but I don't understand why that is the case. I've tried finding the curve to the two surfaces, but I don't know how to properly do so in this case because I end up with $\pm$ square roots and I'm not sure you need to find it in this case.
I know how to find the tangent vector given a vector equation, just take the derivative and substitute in the point, but I'm missing the vector equation.
 A: First, try to determine the intersection curve.
By subtracting the equations you get $y=\pm 1$.
By adding the equations you get $x^2+z^2=2$.
Therefore the intersection curve is made by two circles located on two planes parallel to XOZ, one given by equation y=-1 and the other by y=1.
Now moving to point of construction: [1,1,1] is located on one of the two circles.
The intersection curve is:
$
\vec{p}(t)= \left[ {\begin{array}{ccc} \sqrt2 \cdot cos (t) &s & \sqrt2 \cdot sin(t) \end{array} }\right], t\epsilon [0, 2\pi), s=\pm1$;
If $t=\frac{\pi}{4}, s=1, $ then the point [1, 1, 1] is obtained.
Now to determine the tangent vector, is enough to differentiate the position vector:
$\frac{d\vec{p}}{dt}(\frac{\pi}{4})= \left[ {\begin{array}{ccc} -1&0 & 1 \end{array} }\right]$
Next I would normalize the vector to $ \left[ {\begin{array}{ccc} -\frac{\sqrt{2}}{2} &0 & \frac{\sqrt{2}}{2} \end{array} }\right]$
Note: this vector is not identical to the one you provided as answer. Is opposite in direction and has a length 1.
A: Recall that $df(x)/dx$ gives you a slope at $x$ for the function $f(x)$. Along the same lines the gradient of $f(x,y,z)$ will give you the "equivalent to the slope but in higher dimensions". The gradient of your first curve is the vector $(2x 2y 2z)^T$, where $T$ means transpose. The other is computed analogously. Since you have the point of intersection $P=(1,1,1)$, by replacing the coordinates of $P$ into the vectors determined via the gradient you will  get 2 vectors (not necessarily parallel). The tangent you are looking for is perpendicular to the two tangents to the curves, so the cross product will lead to a vector pointing in the direction you are looking for up to a multiplicative constant (for example, if you remove the 2 in the gradient vectors and operate you will get a different vector, but the direction is the same).
