clisp and gclisp give different answer for the same problem, not related to texmacs/maxima interface
Subject: clisp and gclisp give different answer for the same problem, not related to texmacs/maxima interface
From: James Amundson
Date: Fri, 19 Sep 2003 09:03:51 -0500
On Fri, 2003-09-19 at 01:31, Javed Alam wrote:
> I tried to solve this 2nd order differential equation
> and end up with
> a wrong answer because if I try doing the same with maxima compiled with
> GCL I get the
> right answer. Did some body else had the same problem?
<snip>
> (C1) 'diff(x,t,2) + a*x = b*sin(c*t);
> 2
> d x
> (D1) --- + a x = b SIN(c t)
> 2
> dt
> (C2) ode2(d1,x,t);
> Is a positive, negative, or zero?
>
> positive;
> /
> [
> (D2) x = b SIN(SQRT(a) t) I (SIN(c t + SQRT(a) t) + SIN(c t - SQRT(a) t))
> ]
> 1. Break [1]>
>
> d
> /(2 COS(SQRT(a) t) (-- (SIN(SQRT(a) t)))
> dt
>
> d
> - 2 SIN(SQRT(a) t) (-- (COS(SQRT(a) t)))) dt
> dt
>
> /
> [
> + b COS(SQRT(a) t) I (COS(c t + SQRT(a) t) - COS(c t - SQRT(a) t))
> ]
> /
>
> d
> /(2 COS(SQRT(a) t) (-- (SIN(SQRT(a) t)))
> dt
>
> d
> - 2 SIN(SQRT(a) t) (-- (COS(SQRT(a) t)))) dt + %K1 SIN(SQRT(a) t)
> dt
>
> + %K2 COS(SQRT(a) t)
I was not able to reproduce this result with Maxima 5.9.0+Clisp 2.29 or
the current Maxima cvs+Clisp 2.31. Looking at it, I don't see how you
could possibly get "1. Break [1]>" In the middle of a displayed
equation. Do you know what happened there? It would be helpful for you
to send us the output of "build_info();"
--Jim