I am new to Wolfram Alpha.

Doing my best, still I don't know how to use a variable with a length higher than one. Here I use a variable called ba while wolfram alpha interprets that as b*a instead of a single variable.


  • WolframAlpha is prone to do that. Even for single letters WolframAlpha will try to interpret some of those as something other than a simple variable name, using x,y,z and a,b,c seems to usually work. community.wolfram.com is probably a better place to ask WolframAlpha questions, as long as you clearly indicate in the posting title that this is what you are asking about.
    – Bill
    Commented Jul 17, 2015 at 5:50
  • Can't search that forum... and feels silly to ask something that's surely been asked before.
    – Michael
    Commented Nov 6, 2019 at 16:02

3 Answers 3


As you found out, Wolfram Alpha (unlike Mathematica) assumes that ab is a product even if there is no space or multiplication sign between a and b. So you can't use "ab" or "ba" as a variable name.

But this does not mean you are restricted to a..z, A..Z for variable names. You can still use:

  • alpha, beta, gamma... example
  • indexed variables x_1, x_2, x_10, x_11,... example (But note that letters cannot be used as indices--they must be numbers)
  • Ah, but it looks like indexes can be at most two digits long. Any easy way of extending this to more than two digits? Commented Jun 1 at 14:58

I know this is not really a full answer to this general question.
But it does let you use variable names in Wolfram Alpha ... of a sort.

And it is COOL!
I'll definitely be coming back to this. It seems to do quite alright with mathematical expressions (and evaluating them) so maybe it is close enough to help you and others -- it does what I wanted variable names for. I also don't know jack about this cloud notebook thing, so there might be a way to where you want to go from there.

The notebook feature will let you use variable names. I really don't know much about it, but i found it while trying to make an image of a unit conversion / factor-label thing.

input the expression

My Input is basically this question: given 5g salt, how much 0.075 solution can I make? So I put in the expression with single letter variables. You could just simply START your expression here, and continue building it after the next step.

Once you've got something in there that evaluates, click on the orange banner at the bottom that says Instantly go further which will open a new tab to a notebook. I don't know any other way to get to the next screen without doing this.

enter image description here

Change the variable names on the Input: line (shown above before and below after) and/or continue to build your expression. Works also with underscore char in the variable name (they just aren't blue anymore). You can evaluate the expression by SHIFT-ENTER or from the arrow button to the right.

enter image description here

Just under the evaluate Go arrow button for the input line is a kinda well hidden tools menu (gear icon). Here I have already converted the input line into "TraditionalForm" and opened the menu again afterward.

enter image description here

Reformat if you want, or continue building your expression, or whatever. This will NOT be parsed the same way you can do a more natural language input on the main page. It seems to work out alright for evaluating expressions.

Evaluating! Just hit the orange Go icon, or Shift-Enter.

evaluated with units

You see? I can make 6.666 Liters of my 0.075% solution from my 5 grams of salt. (Note, converting to TraditionalForm and back to InputForm has messed with my original input line, but it is still the same expression.) It's cool that unit names can be used as variables like this.


Putting double quotes around the multi-letter variables seem to work.

  • 2
    Doesn't seem to be working for me :/ Commented Feb 26, 2022 at 12:56
  • Works fine for me, e.g. {{"ca",-"sa",0,0},{"sa","ca",0,0},{0,0,1,0},{0,0,0,1}} {{"cb",0,"sb",0},{0,1,0,0},{-"sb",0,"cb",0},{0,0,0,1}} {{1,0,0,0},{0,"cy",-"sy",0},{0,"cy","sy",0},{0,0,0,1}}, which runs the matrix multiplication as it should, whereas without quotes it doesn't even know what's being asked and goes "I think f is a musical note?" Commented 2 days ago

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.