3

Why will Mathematica not give a soluion to Solve[Log[x] == Log[j, Log[j, x]], j], but Wolfram Alpha will?

martin
  • 8,678
  • 4
  • 23
  • 70

1 Answers1

5

Wolfram|Alpha points out that this is a solution over the reals:

enter image description here

This is how to get this solution in Mathematica:

Reduce[Log[x] == Log[j, Log[j, x]], j, Reals]

(* Log[x] != 0 && j == x^E^-ProductLog[Log[x]^2] *)

Wolfram|Alpha tries to interpret input as natural language. Certain Mathematica expressions work, but they don't always do the same thing as in Mathematica. Here W|A interprets the input as "solve this equation with reasonable assumptions", not as "run the Mathematica code Solve[Log[x] == Log[j, Log[j, x]], j]".

Szabolcs
  • 234,956
  • 30
  • 623
  • 1,263
  • Great - that you :) - Had me a little confused! – martin Jun 16 '14 at 14:11
  • Is it better to use Reduce in most cases? – martin Jun 16 '14 at 14:12
  • ... Is there any way of solving for an extra Log? ie Reduce[Log[x] == Log[j, Log[j, Log[j, x]]], j, Reals]? – martin Jun 16 '14 at 14:16
  • 1
    @martin Solve tends to be faster because it doesn't seek a general solution. E.g. in v8 Solve[Sin[x] == y, x] returned {{x -> ArcSin[y]}} which is not the general solution. Reduce[Sin[x] == y, x] returned C[1] \[Element] Integers && (x == \[Pi] - ArcSin[y] + 2 \[Pi] C[1] || x == ArcSin[y] + 2 \[Pi] C[1]) which is general. I couldn't find a v9 example off the top of my head but that's the main difference. In v9 (?) Solve can take the option Method -> Reduce to do what Reduce does ... (check the docs for another example on this). – Szabolcs Jun 16 '14 at 14:16
  • Ah, ok, thanks - that helps me to understand a little better. – martin Jun 16 '14 at 14:17