Wikipedia:Reference desk/Archives/Mathematics/2007 October 18

= October 18 =

-(-A) = A
Any suggestions on this, or is it clear / correct?

For any set A.

$$\overline{\overline{A}} = A$$

$$A = \{x|x \in A\}$$

$$\overline{A} = \{ x | x \notin A \}$$

$$\therefore$$

$$\overline{\overline{A}} = \{ x | x \notin \overline{A} \} = A$$

91.84.143.82 11:21, 18 October 2007 (UTC)


 * This is correct. However he last step is not particularly convincing.
 * You could go with something like this:
 * $$x \in \overline{\overline{A}} \Leftrightarrow x \not\in \overline{A} \Leftrightarrow \neg(x \in \overline{A}) \Leftrightarrow \neg(x \not\in A) \Leftrightarrow \neg(\neg(x \in A)) \Leftrightarrow x \in A$$.
 * Therefore
 * $$\overline{\overline{A}}=A$$
 * Morana 08:16, 18 October 2007 (UTC)


 * Sorry, this is nonsense from start to finish because of a critical omission. We can only define the complement AC of a set A when A is a subset of some "universal" set U, A&sube;U. The proper expression is
 * $$ A^{\mathrm{C}} = \{x \in U \mid x \not\in A \} = U \setminus A . \,\!$$
 * (See Complement (set theory).) Now try again. --KSmrqT 10:33, 18 October 2007 (UTC)


 * I assumed the OP was more interested in a proof of $$\overline{\overline{A}} = A$$ than in the definition of complements. Therefore, since the very fact that complements are being used implicitly presupposes the existence of a universal set, an explicit mention of this set is unnecessary. If, however, you need it spelled out, insert this before the proof:
 * Let U be a universal set. That is $$\forall A \subseteq U$$, let $$\overline{A}$$ be understood as $$U \setminus A$$. Then $$\forall A \subseteq U, \forall x \in U$$ ...
 * You will then see that:
 * this addition doesn't bring anything.
 * the original proof wasn't nonsensical after all.
 * Morana 12:27, 18 October 2007 (UTC)


 * Would it be acceptable, then, to start the demonstration with: "For any set $$A \,$$ such that $$A \subseteq U \,$$, where $$U \,$$ is the universal set"? 91.84.143.82 11:21, 18 October 2007 (UTC)
 * Yes. Another way to say this is "Let A be a subset of a universe set U." Now we can properly define the complement of A using meaningful notation. The line you previously found "not particularly convincing" transforms into something sensible. The complement of A contains those elements of U not in A, and the complement of that now convincingly produces A. We can also consider an indicator function &chi;A from U to {0,1}, defined for all x&isin;U to be 1 if x&isin;A and 0 otherwise. Subtracting its output from 1 gives an indicator function for AC. And what is 1−(1−&chi;A(x))? We have caught a glimpse of the beautiful and powerful relationships captured by abstract boolean algebras. And for this theory, the universe set is essential. --KSmrqT 14:54, 18 October 2007 (UTC)

sin(a+ib)
Is there an article somewhere on topics relating to sin(a+ib) - specifically sin(a+ib)=c+id (and getting a,b from c,d) - or is it too obscure/trivial? (a,b,c,d are real)87.102.3.9 13:17, 18 October 2007 (UTC)
 * Trigonometric function contains some information about this. You basically just need to express the sine in terms of the exponential function, and use Euler's formula. As for finding a,b from c,d, this is effectively computing the arcsine, which shouldn't be difficult either. -- Meni Rosenfeld (talk) 14:42, 18 October 2007 (UTC)
 * I found 4 (a b)s for each (c d) - it seemed slightly complex.. I wondered if there was anything on this or if I missed a trick or made a mistake. I used sin(a+ib)=sin(a)cos(ib)+cos(a)sin(ib)=c+id so c=sin(a)cos(ib), d=cos(a)sin(ib) .. solving this gave me a quartic.. Does this all sound right?87.102.3.9 15:25, 18 October 2007 (UTC)


 * In fact, d=(-i)cos(a)sin(ib)
 * Keeping imaginary numbers as arguments of sin and cos is confusing and make the split in real and imaginary parts not at all obvious. Going all the way, with hyperbolic functions, is probably better:
 * sin(a+ib)=sin(a)cos(ib)+cos(a)sin(ib)=sin(a)cosh(b)+icos(a)sinh(b)
 * and from there you get c=sin(a)cosh(b) and d=cos(a)sinh(b).
 * Morana 16:01, 18 October 2007 (UTC)
 * That's pretty much what I did (the loss of "i" was a typing error) .. any articles? or indeed any uses for it?87.102.3.9 17:04, 18 October 2007 (UTC)
 * Don't forget that the Sine is periodic, so for every solution, you can change a by $$2\pi k$$ and you will get more solutions. But I still think it is best to work completely in terms of exp. -- Meni Rosenfeld (talk) 16:04, 18 October 2007 (UTC)
 * I used an expansion like that by Morana - to separate out real and imaginary... Then removing a gave a quartic (in e2b) - an easy one that reduced to (x2+nx+1)(x2+mx+1) - and n and m could be got (n<>m) - so I should get 4 values of e2b .. these can include e2b=-1 which of course is wrong for b being real.. So it looks like I get just 2 solutions (plus the +2npi extras)..
 * I was wondering what you meant by "work completely in terms of exp"? ... as a different method87.102.3.9 16:56, 18 October 2007 (UTC)
 * exp is the exponential function. Did you take a look at the links I provided? -- Meni Rosenfeld (talk) 20:08, 18 October 2007 (UTC)
 * (of course I did) so
 * sin(a+ib) = (ei(a+ib) - e-i(a+ib))/2i = c+ id
 * eiae-b - e-iaeb = 2ic - 2d
 * I'm stuck there (without splitting eix in real and imaginary = cos(x)+isin(x) )
 * so then I think I need to use Euler's formula.. Isn't that the same method.. (I'm getting confused..)87.102.3.9 20:32, 18 October 2007 (UTC)


 * Don't separate the real and imaginary parts. That is with $$\sin(z)=w$$ you get:
 * $$\frac{e^{iz}-e^{-iz}}{2i}=w$$
 * Define $$s:=e^{iz}$$ and you have
 * $$\frac{s-\frac{1}{s}}{2i}=w$$
 * which you can then solve. Morana 04:44, 19 October 2007 (UTC)
 * I'm ok with that - I think I must have misread what "Meni Rosenfeld" ws saying.. So there is no specific article then I assume.87.102.7.57 15:14, 19 October 2007 (UTC)

Integrals
How would one integrate $$\int\sqrt{1 + 1/x} dx$$ and $$\int\sqrt{1+1/x^2} dx$$? -Elmer Clark 18:43, 18 October 2007 (UTC)
 * Well, if one is me, one would head over to The Integrator. If you want to know how to actually do it by hand, you'll have to wait for someone who didn't stop caring about such things years ago. Algebraist 19:32, 18 October 2007 (UTC)


 * I have a method for the second


 * (Second example) For y=sqrt(1+1/x^2)dx
 * how about using x=tan(a) see Integration by substitution


 * so y= sqrt (1+1/tan2(a)) = sqrt ( 1+tan2(a)/ tan2(a) )
 * and because 1+tan2(a) = 1+ ( sin2(a)/cos2(a) ) =  ( sin2(a) + cos2(a) / cos2(a) ) = 1 / cos2(a)


 * we get y = sqrt ( 1 / tan2(a) cos2(a) )
 * so y = 1 / tan(a) cos(a) = 1/sin(a)

Then using dx/da = 1 / cos2(a)
 * gives
 * y = 1/sin(a) cos2(a) da which appears at List_of_integrals_of_trigonometric_functions .. assuming I haven't made a mistake I'd bet there is an easier way.87.102.3.9 19:44, 18 October 2007 (UTC)

The first one elludes me.. (maybe x=tan2(a) would be a substitution that works.. I haven't checked)87.102.3.9 19:44, 18 October 2007 (UTC)


 * For the first one how about

$$u = \sqrt{1 + 1/x}$$

$$u^2 = 1 + 1/x$$

$$u^2 - 1 = 1/x$$

$$x = \frac{1}{u^2-1}$$

$$dx = \frac{-2u}{(u^2-1)^2} du$$

$$\int \sqrt{1 + 1/x}\ dx = -2 \int \frac{u^2}{(u^2-1)^2} du$$


 * and partial fractions from there --tcsetattr (talk / contribs) 19:57, 18 October 2007 (UTC)

The answer to question two contains an error, but the thinking is totally correct. Note that you should be working with $$u$$, not $$a$$ since it is generally the variable of choice for substitutions in Calculus. The mistake is that he forgot his parenthesis around $$1+\operatorname{tan}^2u$$.

So $$y=\sqrt{\frac{1+\operatorname{tan}^2u}{\operatorname{tan}^2u}}$$ and $$1+\operatorname{tan}^2u=\operatorname{sec}^2u$$

So $$y=\sqrt{\frac{\operatorname{sec}^2u}{\operatorname{tan}^2u}}$$

$$y=\sqrt{\frac{1}{\operatorname{sin}^2u}}$$

$$y=\sqrt{\operatorname{csc}^2u}$$

$$y=\operatorname{csc}u$$

Then use the integration formula for $$\operatorname{csc}$$ —Preceding unsigned comment added by A math-wiki (talk • contribs) 23:36, 18 October 2007 (UTC)


 * Thanks a lot, guys. I am curious, though, whether #1 can be done without partial fractions - I suspect there exists a method similar to the one used for #2 that works for it as well... -Elmer Clark 01:33, 19 October 2007 (UTC)
 * Trying various substitutions (such as f=sqrt(1+1/x) ) leads to things like y=-2f df /(1-f2) .. (but the obvious substitution from here is a=sin(f) ... )87.102.7.57 13:18, 19 October 2007 (UTC)

Euler Angle rotations with pitch and yaw but not roll
So I'm at the origin (0, 0, 0) facing (1, 0, 0) which is straight forward and (0, 0, 1) is straight up. I want to rotate to face the point (px, py, pz) such that my local y-axis remains globally horizontal. That is to say I want to: However, I must do so using global Euler Angles (ax, ay, az) where:
 * pitch up or down around my local y-axis, and furthermore I prefer that my head remains higher than my feet when possible (note: this is not for any actual lifting equipment, just computer graphics);
 * yaw turning to one side or the other around the global z-axis;
 * but I must not roll.
 * ax is the angle rotated around the global x-axis, with 0 being top, π/2 being horizontally sideways to the right, and π/2 horizontally sideways to the left;
 * ay is similar for rotation around the global y-axis, with π/2 being face down with head in front of heels towards (0, 0, -1), and -π/2 face up on back towards (0, 0, 1). ax and ay together determine the pitch;
 * az is the angle of rotation around the z-axis, and much easier to determine than the other two because it alone determines yaw and nothing else. Π/2 faces left towards (0, 1, 0) and -π/2 right towards (0, -1, 0).

How does one calculate the Euler angles for a roll-less rotation?

Can rectangular-to-polar (or spherical) conversions be used to map the components of the point to be faced (px, py, pz) into the rotational angles of pitch, ax and ay? 208.58.10.195 18:54, 18 October 2007 (UTC)


 * From quickly looking at the Euler Angle page, I think bounding $$\alpha, \beta ,\gamma$$ to the domain $$(\frac{\pi}{2},-\frac{\pi}{2})$$ will do the trick. A math-wiki 23:02, 18 October 2007 (UTC)


 * Sorry, that was wrong. The condition (after muc thought) is either $$\beta = \gamma$$ or $$-\beta=\gamma $$. It depends on whether 'leaning back' is positive or negative for gamma and beta. A math-wiki 23:22, 18 October 2007 (UTC)


 * You have stated your problem with unusual clarity. I suspect you are aware that the problem is fairly easy if the coordinate system rotates with the body. Just to be sure, let's cover that first.
 * First find a pitch &phi; that brings your aim point P = (px,py,pz) into the xy plane, as P&prime; = (px&prime;,py&prime;,0). Next find a yaw &theta; that brings P&prime; onto the x axis. Then yaw Rz(−&theta;) followed by pitch Ry(−&phi;) will do the job.
 * Now we convert this to a matrix expression. Since the axes rotate with the body we want Rbody = Rz(−&theta;)Ry(−&phi;).
 * The final step is the most difficult: Convert Rbody to Rworld. Although fraught with peril, this conversion has been addressed in the literature; see Rotation matrix.
 * Since you are doing this for computer graphics, you might also look at the FAQ for the newsgroup news:comp.graphics.algorithms. Two articles there seem relevant: Aiming and Euler angles from matrix. Mathematicians will not be surprised by the relative simplicity of the quaternion methods shown. --KSmrqT 07:47, 19 October 2007 (UTC)