Message Boards Message Boards

Product just for the even numbers?

GROUPS:
mathematics wolfram alpha wolfram language

How to compute a product just for the even numbers? The multiplication must be computed for i being 0, 2, 4, 6, 8, 10, so on until 60, 62 and 64 and not for all the i from 0 to 64 as in example... How the input should be look like? I tried something as " where i is even", "even(i)" but no success...

Here is example input in W|A:

product (2^i+1), i=0 to 64

enter image description here

POSTED BY: Stefan P
Answer
1 month ago

In Mathematica:

Product[1 + 2^i, {i, 0, 64, 2}]
POSTED BY: Valeriu Ungureanu
Answer
1 month ago

This can't be done using WolframAlpha's engine?

POSTED BY: Stefan P
Answer
1 month ago

Yes, it can be done:

product 1 + 2^(2i),  i = 0 to 32

enter image description here

Exactly the same result is found by Mathematica:

In[8]:= Product[1 + 2^i, {i, 0, 64, 2}]

Out[8]= 20938047277156744484034659764096189108263758406006051370922858\
6118246862458142924512702592682151377556998653509642018354565232926801\
5845410033321503967023531688970809328414948820703193048389035777448706\
6402449391971662407986932466355936361560726425018122283263943137284411\
01056546992945870757184144578986549377441406250
POSTED BY: Valeriu Ungureanu
Answer
1 month ago

Group Abstract Group Abstract