MathOverflow is a question and answer site for professional mathematicians. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

What can you say about a function defined on a square region of the complex plane, if the integral of the function along any horizontal, vertical or diagonal of the square is equal ? - an analytic magic square.

share|cite|improve this question
I think you'd probably want to assume $f=f(x,y)$ to be a continuous function of $z=x+iy$, at least as a first step; without this assumption, you get all sorts of horrible measure theoretic difficulties and technicalities. But I think the complex analysis tag is wrong, unless you mean to restrict to analytic $f$. – Zen Harper Jan 26 '11 at 16:13
The idea of a magic square in the complex plane isn't really a natural analog of the usual discrete magic squares because in the discrete case you are summing along the same number of squares along a discrete diagonal, row or column, but in the complex integral case you would be integrating along diagonals which are not the same length as the other lines. – decomwe Jan 26 '11 at 16:26
Also, what is the measure you will integrate with when you integrate along the diagonal? There are two natural choices: (1) is to integrate $$ \int_0^1 f(x,x) dx $$ which is a direct analogue of the magic square case, but a possibly more natural integral (since you tagged complex-analysis) is the line-integral, which in coordinate presentation would be $$ \int_0^1 f(x,x) \sqrt{2} dx $$ the two different normalisations will give different answers in the case where you do not assume the integrals evaluate to 0. – Willie Wong Jan 26 '11 at 16:39
(Ah, I see decomwe beat me to it. Think of my comment then as an addendum to what decomwe wrote then.) – Willie Wong Jan 26 '11 at 16:40

CORRECTION: many thanks to Joel David Hamkins and Willie Wong; yes, we should take $I_1 = I_2 = 0$ (now edited out and removed). For some reason "constant" and "zero" keep getting mixed up together in my head!!

You can get lots of examples satisfying the vertical and horizontal integral conditions by choosing $f(x,y) = g(x)h(y)$ where $\int_0^1 g(x) dx = \int_0^1 h(y) dy = 0$. The diagonal integrals being equal to $0$ gives you two equations relating $g,h$, but these still leave very many possibilities for $g,h$.

(Note: I wrote $I_1$, $I_2$ before, but I've removed these to make it clearer).

Finally, taking arbitrary finite linear combinations of such $f$ (and also infinite linear combinations, if you are careful with convergence) gives you yet more examples.

If you want to restrict $f$ to, say, analytic functions, then this won't work - but you didn't say this in your question! (Although I suppose maybe you meant this, since you do say "analytic" magic square!)

EDIT: I'm definitely not claiming that every continuous example $f$ can be obtained in this way!! I just want to show that there are many, many possibilities for $f$.

share|cite|improve this answer
Just to give concrete examples. Let $g(x) = \sin 2\pi n x$ and $h(x) = \sin 2\pi m x$ with $m\neq n \in \mathbb{Z}$. – Willie Wong Jan 26 '11 at 16:29
You can't have $I_1$ and $I_2$ arbitrary, since if $I_2$ is nonzero, then for all the vertical integrals to be equal you would need $g(x)$ to be constant. Right? – Joel David Hamkins Jan 26 '11 at 16:34
The only way this can work is if $I_1=I_2=0$, as in Willie Wong's examples. – Joel David Hamkins Jan 26 '11 at 16:46
Thanks; yes, I have now edited out my stupid $I_1$, $I_2$ mistakes. – Zen Harper Jan 26 '11 at 18:50

Since this is tagged complex analysis:

(1) Such a function does not exist if you assume it is complex analytic on its domain and the various integrals evaluate to non-zero values.

Proof: apply Cauchy's integral theorem to the following contour: starting from the origin, go horizontally to $(1,0)$, go up to $(1,1)$, and travel back down diagonally to $(0,0)$.

(2) An analytic function with your properties must also be periodic. That is: $f(0,y) = f(1,y)$ and $f(x,0) = f(x,1)$.

Proof: consider the contour from the origin to $(1,0)$ to $(1,y)$ to $(0,y)$ and back to the origin. This shows that $\int_0^y f(0,t) dt = \int_0^t f(1,t)dt$ for every $t$. Apply the fundamental theorem of calculus.

From (2), apply Rademacher's characterisation of analytic functions (see Theorem 10 in this), you have that a periodic extension of $f$ is an analytic function on the complex plane, which immediately implies that $f\equiv 0$.

So, to summarize: if $f$ is a function with your properties, which in addition is analytic in $(0,1)\times(0,1)\subset\mathbb{C}$ and is continuous up to the boundary, then $f\equiv 0$.

share|cite|improve this answer
For (2), do you mean "doubly periodic" (i.e. periodic in each [real] variable separately?) So, I think it's using the fact that every elliptic function without poles must be constant? – Zen Harper Jan 26 '11 at 18:49
yes, periodic in the torus sense. And you don't need such high-brow terminology as "elliptic functions". :) Just Liouville's theorem. – Willie Wong Jan 26 '11 at 19:23
(that is is 0 follows from part (1), after you get that it is constant). – Willie Wong Jan 26 '11 at 19:24

Absolutely nothing beyond the definition. The complex plane is just R x R with some additional operations on it, which are irrelevant by your definition. The function doesn't have to be differentiable anywhere, continuous anywhere, or integrate to zero anywhere other than on the edges or on the main diagonals. Sorry. If you limited the question to say, meromorphic functions you might be able to get a better answer. In addition, you haven's specified directions, but i've taken it as implicit that you have.

If you have any open subset of C that crosses all 6 relevant integrals, and define an integrable function everywhere except that open region, you can always define the function on that subset such that the complete function satisfies the magic square condition.

share|cite|improve this answer
I think the given definition of magic square is ambiguous. In my view, there should be an infinite number of relevant integrals: one for each maximum length line segment contained in the box which is parallel to a side of the square and one each for the two diagonals of the square – Tony Huynh Jan 26 '11 at 15:10

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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