Skip to main content
22 events
when toggle format what by license comment
Dec 11, 2014 at 4:42 vote accept Jerry Guern
Dec 2, 2014 at 1:21 comment added Szabolcs @RolfMertig I didn't manage to run either on my machine (OS X). Here's maxima instead (gives 0) and sympy (best result so far, but very slow).
Dec 2, 2014 at 1:01 history edited Jerry Guern CC BY-SA 3.0
fixed sign typo
Dec 2, 2014 at 0:47 comment added Nasser fyi, this is what Maple gives for Integrate[Cos[m*x]*Cos[n*x], {x, 0, 2 Pi}, Assumptions -> Element[{m, n}, Integers]] !Mathematica graphics but one has to use the AllSolutions to get this.
Dec 2, 2014 at 0:30 comment added Rolf Mertig @Scabolcy Did you try FriCAS or Open-Axiom? Axiom ( aka ScratchPad) had a clean type design (theoretically; in practice it is quite hard to get anything non-purely mathematical done).
Dec 2, 2014 at 0:07 comment added Szabolcs @Daniel They're still not doing well enough to satisfy the complaint here. MuPad figures out the $\cos mx \; \cos nx$ case but not the $e^{ix}\cos mx$ one. Maple simplifies straight to 0, ignoring the possibility of $m=n$ or $m=1$.
Dec 1, 2014 at 23:56 comment added Daniel Lichtblau @Szabolcs Thats certainly an interesting route taken by Maple and MuPad. That said, I do not foresee Mathematica also going that way unless and until we do one of two things. (1) Make some changes at a fairly deep level to Refine and related functions that use Assumptions. (2) Make some fairly deep changes in Integrate to bypass much of the assumptions handling in the presence of explicit assumptions of integrality.
Dec 1, 2014 at 23:55 comment added Szabolcs And some more
Dec 1, 2014 at 23:45 comment added Szabolcs Not trying to make any sort of point here, I was just curious how other systems would handle the basic $\int_0^{2\pi} \cos nx \; \cos mx \; dx$, $n,m \in \mathbb{Z}$ example. Here's Maple and MuPad.
Dec 1, 2014 at 21:52 comment added Jerry Guern @SjoerdC.deVries True about the "infinitely large", can't handle them all. But it's bizarre and inexplicable to me that Wolfram wouldn't have designed MMa to handle THESE to cases correctly, given that they are the entire basis of Fourier Analysis and hence cornerstones of EE and SigProc.
Dec 1, 2014 at 21:52 answer added Daniel Lichtblau timeline score: 20
Dec 1, 2014 at 21:48 comment added Sjoerd C. de Vries I have a hunch that the set of special cases is infinitely large, so there's probably no general method to handle them all. It may be possible to anticipate a restricted set of known cases though.
Dec 1, 2014 at 21:39 comment added Jerry Guern @Szabolcs I get wrong results in each of the case I listed. And I know Limit will fix the problem if I happened to know that f[x] was a Cos[], but I usually won't know what f[x] is beforehand, so I need a general method that anticipates and handles these problems.
Dec 1, 2014 at 21:38 review Close votes
Dec 2, 2014 at 2:23
Dec 1, 2014 at 21:36 history edited Jerry Guern CC BY-SA 3.0
added 66 characters in body
Dec 1, 2014 at 21:35 comment added Jerry Guern @rm-rf I clarified the question.
Dec 1, 2014 at 21:33 comment added Szabolcs Could you amend your question and point out the specific wrong results you get? The $n=m$ case can be handled with Limit.
Dec 1, 2014 at 21:32 comment added Jerry Guern @Hector, I reworded that part. The error happens for Cos[nx]*Cos[mx] because MMa ignores the special case m == n.
Dec 1, 2014 at 21:30 history edited Jerry Guern CC BY-SA 3.0
added 50 characters in body
Dec 1, 2014 at 21:16 comment added Hector I did Integrate[Cos[m*x]*Cos[m*x], {x, 0, 2 Pi}, Assumptions -> {Element[m, Integers]}] and I got a sensible answer. It seems you had a typo in Assumptions.
Dec 1, 2014 at 21:12 history edited Sjoerd C. de Vries CC BY-SA 3.0
corrected incorrect function definitions
Dec 1, 2014 at 20:57 history asked Jerry Guern CC BY-SA 3.0