4
$\begingroup$

$$ S=\sum_{k=0}^{10}\sin\left(\frac{(2+4k)\pi}{23}\right) =\sum_{k=0}^{10}e^\left(i\frac{(2+4k)\pi}{23}\right) =e^{i\frac{2\pi}{23}}\sum_{k=0}^{10}e^{i\frac{4k\pi}{23}} =e^{iu}\sum_{k=0}^{10}\left(e^{2iu}\right)^k $$

For example, I did this by hand, and got an answer as $\frac{1}{2} \tan\left( \frac{\pi}{23} \right)$

But how do I use Mathematica to check?

Sum[Sin[Pi/23*(2 + 4*k)], {k, 0, 10}]
Sum[Sin[Pi/23*(2 + 4*k)], {k, 0, 10}] - Tan[Pi/23]/2 // Simplify

I have tried some functions like Simplify,TrigFactor,TrigToExp. But I am not sure how to guide Mathematica to the final answer.

And similarly, how do I simplify

Sum[Sin[(-1)^k*Pi/23*(2 + 4*k)], {k, 0, 10}]

which I got as $-\frac{1}{2} \tan\left( \frac{2\pi}{23} \right)$.

$\endgroup$
2
  • $\begingroup$ (Sum[Sin[Pi/23*(2 + 4*k)], {k, 0, 10}] - Tan[Pi/23]/2 )// FullSimplify produces 0 in version 12.0. $\endgroup$
    – user64494
    Feb 2, 2020 at 12:30
  • 1
    $\begingroup$ @user64494 I think what he want is , how to get $\frac{1}{2} \tan \left(\frac{\pi }{23}\right)$ by mma. (Sum[Sin[Pi/23*(2 + 4*k)], {k, 0, 10}] - Tan[Pi/23]/2 )// FullSimplify is for check the answer. $\endgroup$ Feb 2, 2020 at 12:36

1 Answer 1

9
$\begingroup$

One way is:

Sum[Sin[Pi/23*(2 + 4*k)], {k, 0, n}] /. n -> 10 // Simplify

(* 1/2 Tan[\[Pi]/23] *)
$\endgroup$
5
  • 1
    $\begingroup$ The second sum confuses Mathematica in its original form and has to be tweaked a little: Sum[(-1)^k*Sin[Pi/23*(2 + 4*k)], {k, 0, n}] /. n -> 10 $\endgroup$
    – aooiiii
    Feb 2, 2020 at 12:43
  • 1
    $\begingroup$ That's just so weird!! Why wouldn't Sum[Sin[Pi/23*(2 + 4*k)], {k, 0, 10}]//Simplify work straight away..... $\endgroup$
    – CasperYC
    Feb 2, 2020 at 12:46
  • $\begingroup$ @CasperYC. I don't really know, maybe because the algorithm is written in this way,can't find simpler form. Using Maple also can't . $\endgroup$ Feb 2, 2020 at 12:52
  • 2
    $\begingroup$ The reason is probably that simplifying such expressions requires guessing the pattern, finding the formula for x_i and then doing the sum the usual way, guessing the pattern being the hardest part of the problem. This would greatly slow down the Simplify function. $\endgroup$
    – aooiiii
    Feb 2, 2020 at 12:55
  • $\begingroup$ @MariuszIwaniuk HAHA. That's fine. I gave up Maple ten years ago ... $\endgroup$
    – CasperYC
    Feb 2, 2020 at 13:10

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.