What does the syntax C[1][x][y] mean?

I am examining an integrability condition, $$u_{3,122}=u_{3,123}.$$ Typing

DSolve[D[u3[x1,x2,x3],x1,x2,x2]==D[u3[x1,x2,x3],x1,x2,x3],u3,{x1,x2,x3}]


it into MMA gives the following output:

{{u3 -> Function[{x1, x2, x3},
C[1][x2, x3] + x1 C[1][x1][x3] + x1 C[2][x1][x2 + x3]]}}


I understand that the integration 'constants' C[1] and C[2] are functions of two variables, so the result C[1][x2, x3] is clear. But what does C[1][x1][x3] mean? Specifically, why is there a concatenation of argument brackets [x1][x3] instead of an argument?

• I'm adding the bugs tag because there should be three independent parameters. Aug 9, 2018 at 13:00

It looks like an error. For C[1][x][y] to make sense C[1][x] must represent a single-variable function (and C[1] should represent a function that produces a function). However, in the solution returned by DSolve, C[1] has to have a different meaning in the first term. Probably the second two parameters should be C[2] and C[3]. Another point of confusion is that in classical math, C[1][x][y] would automatically be uncurried to form C[1][x, y]. See also Curry.

We can see that the more general expression with three functions C[1], C[2], C[3] is a solution:

D[u3[x1, x2, x3], x1, x2, x2] == D[u3[x1, x2, x3], x1, x2, x3] /.
{u3 -> Function[{x1, x2, x3},
C[1][x2, x3] + x1 C[3][x1][x3] + x1 C[2][x1][x2 + x3]]}
(*  True  *)


The uncurried form is also a solution:

D[u3[x1, x2, x3], x1, x2, x2] == D[u3[x1, x2, x3], x1, x2, x3] /.
{u3 -> Function[{x1, x2, x3},
C[1][x2, x3] + x1 C[3][x1, x3] + x1 C[2][x1, x2 + x3]]}
(*  True  *)


Speculation: Probably the parameter generator checks the heads for unique C[n] expressions, but the head of C[1][x1][x3] is C[1][x1] and doesn't match C[1]. One can see that the order of creation with the following:

Trace[
DSolve[D[u3[x1, x2, x3], x1, x2, x2] ==
D[u3[x1, x2, x3], x1, x2, x3], u3, {x1, x2, x3}],
C[_][__],
TraceInternal -> True]


Remark: Note that DSolve gives an unexplainable error (without examining internals):

Last::nolast: {} has zero length and no last element.

• Just to compare. Maple 2018 answers $${\it u3} \left( {\it x1},{\it x2},{\it x3} \right) ={F_1} \left( {\it x3},{\it x2} \right) +{F_2} \left( {\it x3},{\it x1} \right) +{F_3} \left( {\it x1},{\it x3}+{\it x2} \right) .$$ Aug 9, 2018 at 14:06