Ch15 Generalized Linear Least Squares Multidimensional Fits
duyoplait
04-18-2002, 05:56 AM
Hi,
I am trying to implement the GLLS in multidimension according to the last paragraph in 15.4 but I am not sure I understood correctly your explanation to go from one dimension (x) to multiple ones (x vector). In fact, even if we consider the same basic functions for all dimensions the a (the regression coefficients) will be an array and not a vector anymore (the dimensions being coefficient on each basic functions * each dimension). Am I right?
Thanks for any feedback,
Duyoplait
duyoplait
04-22-2002, 02:56 PM
Basically, the paragraph "multidimensional fits" in 15.4 describe a specific case where the coefficients in front of each basis function is the same for all x1, ...,xn variables.
In other word if y depends on x1, ..., xn and in the case where the basis functions are polynomial:
y = a0 + a1*(x1+x2+...+xn) + a2*(x1^2+x2^2+...+xn^2)+...+ap*(x1^p+x2^p+...+xn^p )
But I am looking for something more general such that:
y = a00 + (a11*x1+a12*x2+...+a1n*xn) + (a21*x1^2+a22*x2^2+...+a2n*xn^2)+...+
(ap1*x1^p+ap2*x2^p+...+apn*xn^p)
To the Authors:
Do you have any implementation of this problem?
Members:
Has anyone worked on such issues?
Thank in advance for your feedback
Bill Press
04-23-2002, 08:59 PM
Hi!
No, I'm afraid you haven't understood the last paragraph in Section 15.4. The trick it describes is completely general, and applies to any set of multidimensional basis functions.
The chi-square function doesn't know anything about the multidimensional nature of the fit. All it knows is a set of points at which there is a function value and the values of a set of basis functions. You seem to be thinking of the basis functions as being some kind of product set of basis functions in one-dimension, but that is not generally true. If you do have some kind of product set, the basis functions are all the products, and each will get its own coefficient from the fit.
The trick described in 15.4 for turning any linear least square problem into one that can be solved with one-dimensional routines is, basically, to renumber all your multi-dimensional points into a single one-dimensional sequence (the order doesn't matter), and kludge up the user-supplied function to supply basis function values at these points.
This is completely general.
Hope this helps.
duyoplait
04-26-2002, 05:49 AM
Thanks a lot for your reply!
I was indeed heading in the wrong direction. I think I was a bit confused by your notation (m functions X of the vector x (x1,x2,...) which should be in fact m*p where p in the number of variable in the vector x) and instead of looking at the problem I focused on the notations...
Anyway, I have created a rough modified version of your svd function to accomodate for the multidimensional case. I have to polish it and I will post if in case anybody is interested.
Thanks.
smoghe
01-04-2006, 11:32 AM
Per section 15.4, (tweak for multidimentional fits), when I insert the statement x[i]=i, I get an error message, 'error C2166: l-value specifies const object'. I am clueless as to why I'm getting this error message.
vietdung
01-18-2007, 09:18 AM
I am interested too in this thread
So as I understand the key to treat the multi-dimensional problem is " renumber all your multi-dimensional points into a single one-dimensional sequence "
The question is how to do that ?
In my particular case, I have the independents random variables B , of M dimensions, with normal distribution N[0,1]. So how I can transforme them from M-dimensions to 1-dimension ?
Thanks for any feedback
Ps: Is the article "Linear Approach to LS - Multidimensional Polynomial Fitting" of Tian-Bo Deng a good ref ?