variable dimension of domain of integration

*To*: mathgroup at smc.vnet.net*Subject*: [mg115956] variable dimension of domain of integration*From*: Ulvi Yurtsever <a at b.c>*Date*: Thu, 27 Jan 2011 03:41:16 -0500 (EST)

Consider the function $f(n) = \int_{{0,1}^n} \sqrt{\sum_{i=1}^{n} {x_i}^2} dx_1 ... dx_n$. How would you define a mathematica function F[n_] (using NIntegrate) that computes this integral over the n-cube? I can think of several inelegant solutions; but surely there are neat ways of doing things of this sort... thanks