\[ \newcommand{\sbr}[1]{\left[#1\right]} \newcommand{\br}[1]{\left(#1\right)} \newcommand{\cbr}[1]{\left\{#1\right\}} \newcommand{\abr}[1]{{\left|#1\right|}} \newcommand{\exbr}[1]{{\left\langle #1 \right\rangle}} \newcommand{\nbr}[1]{{\left\lVert #1 \right\rVert}} \newcommand{\fNorm}{\mathcal{N}} \newcommand{\sC}{\mathbb{C}} \newcommand{\sN}{\mathbb{N}} \newcommand{\sZ}{\mathbb{Z}} \newcommand{\sR}{\mathbb{R}} \newcommand{\sL}{\mathit{\Lambda}} \newcommand{\sSS}{\mathit{\Omega}} \newcommand{\sFW}{\mathfrak{W}} \newcommand{\sFB}{\mathfrak{B}} \newcommand{\sFO}{\mathfrak{O}} \newcommand{\sFF}{\mathfrak{F}} \newcommand{\sFP}{\mathfrak{P}} \newcommand{\Open}[1]{\mathfrak{O}(#1)} \newcommand{\Close}[1]{\mathfrak{A}(#1)} \newcommand{\sComp}[1]{{#1}^{c}} \newcommand{\sIn}[1]{{#1}^{i}} \newcommand{\sAd}[1]{{#1}^{a}} \newcommand{\sOp}[2]{{#1}^{#2}} \newcommand{\rt}{\mathbf{t}} \]
If you write a subset like, "users ranked top 25% with the measurament", this document instruct you how to such set complicated at glance easily.
Let \(U\) be a set of objects (like users in human-computer domains), and \(S: U \to \sR\) is a score function, in other words for those prefer natural language expression, \(S(u), u\in U\) denotes a score for user \(u\)). Let \(U_q\subset U, q \in [0, 1]\) be a set of top \(100 q\) % users with respect to the score \(S\), it is defined formally as an maximum set \(U_q\) within, \begin{equation} \abr{U_q}/\abr{U} \leq q, \forall u\in U_q\forall u'\in U-U_q \br{S(u)\geq S(u')}. \end{equation}
The point of the formulation is that, the above definition of \(U_q\) does not define the contents of \(U_q\) explicitely. It defines the number of object first, and the property of those object using \(S\) is defined. Actual objects in \(U_q\) then determined.
In computer science, you will consider sorting when you encouter for this ranked subset kind, but in mathematical notation, we do not need actual mechanism of the computation, so just need to define desired property equivalent to that you want in the most easy and clear way.Using this, you can get "users of top 40 %" as \(U_{0.40}\) without ambiguity. "Users of bottom 76 percent" will be \(U-U_{0.24}\). Do you want to care about the difference between \(\geq, >\)? In computer science for human related, it will be never concerned. Just make it consistent with your implementation on the system.
Meadian is then defined as that, let \(u\) be an object at the most middle position with respect to \(S\), it can be1 defined as, \[ S(u) = \min \cbr{S(u')| u'\in U_{0.5}} \] the definition is for the case \(\abr{U}\) is odd number. For even number, it will be depending on the case.