How to create a 3 parameter function that gets its maximum in the center of the cube? I have an problem where I have a 3 dimensional board, and I want to assign to the center of that cube (aka the board) maximum values and to the edges of the board lower values (preferably in a way so that the upper left side will get higher values then the lower right side) - so i have a cube with R rows, C columns and depth D. I have a coordinate inside the cube with coordinates (i,j,d), With the following constraint on the values  (0,0,0)<=(i,j,d)<(R,C,D). I want a function that will map each value (i,j,d) to distinct values between 0 inclusive to RCD non inclusive in a way that the medium of the cube will get the highest values, then the upper left side and then the lower right side. 

Pick a function in each direction and multiply them.  Ignoring the right being higher than the left and letting the board range from $0$ to $1$, a nice one is $4(x-\frac 12)^2$.  It has a peak of $1$ at the center and is zero at the ends.  For 3D, just use $64(x-\frac 12)^2(y-\frac 12)^2(z-\frac 12)^2$
