Christian writes: << Let f(x , x , ..., x ) = k x + k x + ... + k x 1 2 n 1 1 2 2 n n where k , k , ..., k are n REAL constants 1 2 n and x , x , ..., x are n INTEGERS (positive or negative) 1 2 n If we try to have the best possible approximations of f(x , x , ... x ) = 0 1 2 n do you know good algorithms giving best values of (x , x , ..., x )?
Assume x_j = 0 for all j is not true. Let K and X be the n-dim vectors of real constants and unknown integers, respectively. Then we want to find X so that <K,X> = 0 as near as possible. The set of all values G := {<K,X> : X in Z^n} is a subgroup of the reals, so it's either discrete or dense. The discrete case is easy to handle, and only occurs for measure 0 among possible vectors K in R^n. Otherwise the set G* := {<K,X> : X in Z^n - {0}} contains elements arbitrarily close to 0, so there is no "best" value of X. I'll leave finding "good" values of X to the number theorists, once "good" is defined. --Dan _____________________________________________________________________ "It don't mean a thing if it ain't got that certain je ne sais quoi." --Peter Schickele