From 444d3196359be6bb82fdb6a0f5d5ba32fde4118a Mon Sep 17 00:00:00 2001 From: Paweł Redman Date: Sun, 14 Jun 2026 18:36:53 +0200 Subject: Initial commit --- site/content/integrating_sin2x.typ | 66 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 66 insertions(+) create mode 100644 site/content/integrating_sin2x.typ (limited to 'site/content/integrating_sin2x.typ') diff --git a/site/content/integrating_sin2x.typ b/site/content/integrating_sin2x.typ new file mode 100644 index 0000000..65b17a6 --- /dev/null +++ b/site/content/integrating_sin2x.typ @@ -0,0 +1,66 @@ +#import "/common.typ": post, link-self + +#show: post.with( + title: "Integrating sin² x", + date: datetime(year: 2018, month: 5, day: 1), +) + +$ + integral sin^2 x dif x = (x - sin x cos x) / 2 + C +$ + += Using the Pythagorean identity + +Integrate by parts using $u = sin x, d u = cos x$ and $v = -cos x, d v = sin x$: + +$ + & integral sin x sin x dif x = -sin x cos x - integral -cos x cos x dif x \ + & integral sin^2 x dif x = -sin x cos x + integral cos^2 x dif x +$ + +Add $integral (sin x)^2 dif x$ to both sides: + +$ + 2 integral sin^2 x dif x = -sin x cos x + integral cos^2 x dif x + integral sin^2 x dif x +$ + +Apply integral linearity: + +$ + 2 integral sin^2 x dif x = -sin x cos x + integral (cos^2 x + sin^2 x) dif x +$ + +Apply the Pythagorean identity and divide both sides by 2: + +$ + 2 integral sin^2 x dif x &= -sin x cos x + integral 1 dif x \ + &= -sin x cos x + x + C \ + integral sin^2 x dif x &= (x - sin x cos x) / 2 + C +$ + += Using the double angle formula + +#html.elem("aside", attrs: (class: "warning"))[ + Careful! This derivation differs from the one in #link-self("integrating_cos2x")[integrating_cos2x] by just a sign. +] +Rewrite the integral using the double angle formula for the cosine: + +$ + integral sin^2 x dif x = integral (1 - cos 2 x) / 2 dif x +$ + +Substitute $u = 2 x, d u = 2 dif x$: + +$ + integral (1 - cos 2 x) / 2 dif x &= integral (1 - cos u) / 2 1 / 2 dif u \ + &= 1 / 4 (integral 1 dif u - integral cos u dif u) \ + &= (u - sin u + C) / 4 +$ + +Substitute back and simplify: + +$ + (u - sin u + C) / 4 &= (2 x - sin 2 x + C) / 4 \ + &= (x - (sin 2 x) / 2) / 2 + C \ + &= (x - sin x cos x) / 2 + C +$ -- cgit