Author Topic: Problem with PQ-formula  (Read 2383 times)

Offline eddie

  • Newbie
  • *
  • Posts: 2
  • Karma: 0
Problem with PQ-formula
« on: March 18, 2010, 12:04:27 PM »
First of all thank you for the software. This is really a useful package, but i have a small problem:
When i enter
solve(x^2+p*x+q=0);
the answer is
(1/2(-p+sqrt(p^2+-4q)) , (1/2(-p-sqrt(p^2+-4q))

why is it +-4q ? I think this is simply wrong. Maple and xcas give the correct -4q.
Am I doing something wrong?
Greetings Eddie
« Last Edit: March 18, 2010, 03:26:53 PM by MrMage »

Offline MrMage

  • Administrator
  • *****
  • Posts: 470
  • Karma: 7
Re: problem
« Reply #1 on: March 18, 2010, 03:26:32 PM »
+-4q in fact is the same as +(-4q), which is -4q. So this is correct.

Offline eddie

  • Newbie
  • *
  • Posts: 2
  • Karma: 0
Re: Problem with PQ-formula
« Reply #2 on: March 18, 2010, 04:13:45 PM »
Hmm, at least this seems to be a strange, uncommen notation to me and i must admit i thought 2 solutions were meant somehow..
Anyway, I now understand what's meant and of course it's correct. As pocketcas is based on xcas i expected the same output as from xcas.
Another question:
Is the current version timebombed, too?

Greetings Eddie

Offline MrMage

  • Administrator
  • *****
  • Posts: 470
  • Karma: 7
Re: Problem with PQ-formula
« Reply #3 on: March 18, 2010, 04:36:58 PM »
The difference in results is that PocketCAS uses giac's LaTeX output to generate fancy-looking formulas. But the LaTeX output has some glitches like the one you described. PocketCAS for iPhone does it right, by the way.

The current version is not timebombed. But I still accept donations via PayPal  :)