Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. 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

For a ray from the origin with a given angle in $R^n$, I am trying to find the radius at which that ray intersects the frontier of the unit n-cube. In two dimensions, the picture is this: enter image description here

Given $\theta$, find the distance r to the edge of the unit square. Or, in $n$ dimensions, given angles $\theta_1,...,\theta_{n-1}$, find the distance $r$ to the edge of the unit hypercube.

If somebody could provide a good source of information on doing trigonometry in arbitrary dimensions, that may be enough. As it is I don't know how to approach this problem.

share|cite|improve this question

In 2D it is min$(1/\cos\theta, 1/\sin\theta)$ Where are you measuring your angles? In 3D, is $\theta_1$ the angle in the plane as you show and $\theta_2$ the angle out of the plane?

share|cite|improve this answer

In higher dimensions it is usually best to use a directional vector from the sphere $S^{n-1}$ instead of an angle $\theta$. For convex bodies (or even star bodies) the radial function. $\rho$: $S^{n-1}$$\rightarrow R_{\ge0}$ gives the radius of the body in a particular direction. In your case, you are working with the $l_\infty$ ball. The radial function, when restricted to $S^{n-1}$ is simply the receprical of the minkowski functional:

In short, you need a "nice" formula for the radial function $\rho$ of the $l_\infty$ ball. You may find such a formula in a convex geometry book. In particular, Koldobsky has a book on Fourier analysis and convex geometry which contains extensive results on $l_p$ balls and radial functions.

I'll edit my answer if I think of more specific references.

share|cite|improve this answer

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.