9
\$\begingroup\$

Here are some example submissions using Wolfram|Alpha:

Valentine's golf! I heart you!

Largest number in ten bytes of code

I have two main questions about the use of Wolfram|Alpha:

  1. Is the use of the Internet problematic?
  2. What is considered the output?

The Internet connectivity concern gets brought up alot on these answers and the argument is usually raised that since there are Raspberry Pis which run the Wolfram Language without an Internet connection, they are fine. The problem is that the WL is not the same thing as Wolfram|Alpha (indeed, most Mathematica answers on this site would be more accurately called WL solutions since Mathematica is just one program which runs the WL). I can't find any evidence that these Raspberry Pis can actually evaluate W|A queries such as ack(9!,9!) or heartcurve1 (which are meaningless in the WL) without an Internet connection. Even if they did, it would have to be a limited in scope compared to the W|A site and I doubt people are testing their code on Raspberry Pis to ensure that their query will work.

I think it's also unclear what the output of an expression typed into W|A should be. The results page for any W|A query consists of several pods and subpods, such as Input interpretation, Plot, Equations, Properties, Input, Result, Alternate forms, etc. For the heart curve example, I think we are expected to interpret the content in Plot as the output, whereas for the Ackermann function example, we go with the Knuth up-arrow subpod in Alternate forms (note that we can't even say that the rule is to use the first pod after the input interpretation pod since in this case the output would be (too large to represent)). How is this valid, but just outputting all possible strings of length 13 isn't considered a valid answer if the challenge is to output Hello, world!?

Note that this isn't covered by this question about the use of W|A's datasets since we're not just getting data using Mathematica built-ins, but using Wolfram|Alpha to parse the "code" and functions (such as the Ackermann function) which only exist in W|A.

\$\endgroup\$

2 Answers 2

23
\$\begingroup\$

The website wolframalpha.com should not be treated as a language

wolframalpha.com is not a language, it's a website powered by the Wolfram Language.


Some of the arguments for this is already brought up in the question, but I'll try to elaborate and bring in a few more reasons (some are borrowed from Peter Taylor and Martin Ender's comments on the other answer).

There are (almost) always more than one output:

  • Plot a sine wave from -6 to 6: sin.
  • Plot a sine wave from -26.4 to 26.4: sin
  • Series expansion, derivative, integral: sin

How should you choose which one is the result? The first "result" is always the interpretation of the input, so that doesn't make much sense. Always pick the second result? We can not allow this to be arbitrary, since that would open up for a bunch of loopholes ("disregard all outputs from this function except output number 23").

There is no version control

Quoting Peter Taylor:

The only interpreter is subject to arbitrary changes and doesn't provide any kind of version number, so there's no guarantee that answers can be verified in six months time tomorrow, and there's no way to be sure when answering an old a question that you're not using functionality which has been added since the question was asked. (It might have been added 30 minutes ago)

It's using the internet

Exceptions can be made here, but it's opening up for a lot of loopholes. What's preventing me from solving something in google. heartcurve gives us the curve (along with a bunch of other stuff).

How can you tell if your query is solved using the Wolfram Language, or it's just acting as a regular browser?

Curious about stocks on the New York Stock Exchange, the weather where you are right now? This can't possibly be solved without accessing outside sources. How much else is solved using outside sources (a disallowed loophole)?


This argument was brought up in a comment:

Actually, you can make W|A queries with a single, concrete result. In Mathematica, enter Free-form Input mode with =. It will lookup your query with W|A and return a single result. On the other hand, this can be argued to just be the Wolfram Language with = prepended to whatever your query was.

As far as I can tell, that would be Mathematica with access to online resources. I'd claim the language is Mathematica, and it's using a forbidden loophole by fetching results from online resources.


Also, I'm not sure how this relates to this, but as far as I know, you can't give input to a function/script/query on wolframalpha.com, it's only good for fixed output challenges.

\$\endgroup\$
5
  • 1
    \$\begingroup\$ Actually, you can make W|A queries with a single, concrete result. In Mathematica, enter Free-form Input mode with =. It will lookup your query with W|A and return a single result. On the other hand, this can be argued to just be the Wolfram Language with = prepended to whatever your query was. \$\endgroup\$
    – Pavel
    Commented Feb 20, 2017 at 8:03
  • 7
    \$\begingroup\$ In that case, won't the language be Mathematica, and the program fetches results from the internet? \$\endgroup\$ Commented Feb 20, 2017 at 8:06
  • 3
    \$\begingroup\$ Might be worth mentioning that the stuff you enter into Wolfram Alpha is not the Wolfram Language. The Wolfram Language is what most people call Mathematica and Mathematica is one implementation of that language. Under the hood W|A also uses WL afaik, but the queries you enter are first processed by something W|A specific before WL-code is generated from that. \$\endgroup\$
    – Martin Ender Mod
    Commented Feb 21, 2017 at 14:42
  • 1
    \$\begingroup\$ @LegionMammal978, the link is broken. I'm assuming it's this post? \$\endgroup\$ Commented Feb 21, 2017 at 21:15
  • 1
    \$\begingroup\$ @StewieGriffin Yes, that was the post I was referring to. \$\endgroup\$ Commented Feb 21, 2017 at 22:11
1
\$\begingroup\$

A language is defined by is interpreter (or at least on PPCG)

So yes, Wolfram|Alpha is a valid interpreter (and language by extension). Running a script on Wolfram|Alpha is no different that using TIO.

As for the output, i would say it's everything (too bad kolmogorov-complexity questions) but that's probably a good question for another meta post should Wolfram|Alpha be validated

\$\endgroup\$
4
  • 9
    \$\begingroup\$ I think this is actually an argument against Wolfram|Alpha. The only interpreter is subject to arbitrary changes and doesn't provide any kind of version number, so there's no guarantee that answers can be verified in six months time, and there's no way to be sure when answering an old question that you're not using functionality which has been added since the question was asked. \$\endgroup\$ Commented Feb 14, 2017 at 9:51
  • 2
    \$\begingroup\$ @PeterTaylor That is a fair point and should probably be made into an answer \$\endgroup\$
    – Sefa
    Commented Feb 14, 2017 at 11:34
  • 6
    \$\begingroup\$ I'm also not sure that it can be used for anything except fixed-output challenges since I don't think there is a way to write "program or function" which takes input in any other way than hardcoding it somewhere. \$\endgroup\$
    – Martin Ender Mod
    Commented Feb 14, 2017 at 13:12
  • 1
    \$\begingroup\$ @PeterTaylor Where does TIO show version numbers? Also I've asked before about answers that become invalid over time, and the consensus seems to be that nobody here cares. \$\endgroup\$ Commented Feb 21, 2017 at 23:45

You must log in to answer this question.