Take the 2-minute tour ×
Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. It's 100% free, no registration required.

Given a set of random integers {0,5,100,65,...,0,1,2}, is there a mathematical method existing to construct a parametric form $f$ (the number of parameters $<<$ the number of integers) so that given any integer $x$, $f(x)$ gives the relative position (sorting position) of $x$?

Thanks!

share|improve this question
    
Just for clarity I suggest that you either remove the second zero or explain how it should be treated (even though the general answer is no). –  Bitwise Sep 26 '12 at 13:46

1 Answer 1

The silly answer is yes. For your example (and ignoring the second zero), $$f(x)=\begin {cases} 1 & x=0 \\2 & x=5 \\ 3 & x=100 \\ \ldots \end {cases}$$ You can also find an interpolating polynomial through the points-for these first three it would be $f(x)=(x-1)(5(x-3)+100(x-2))$

I suspect neither of these is what you were thinking of, that the structure is so complicated that it violates the idea of "few parameters". If so, there cannot be one, as you need to pick out one order out of $n!$ You need too much information to make a simple function.

share|improve this answer

Your Answer

 
discard

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.