natix.CompactDS.SArray64.Select1 C# (CSharp) Method

Select1() public method

public Select1 ( long _rank ) : long
_rank long
return long
        public override long Select1(long _rank)
        {
            if (_rank <= 0) {
                return -1;
            }
            int rank = (int)_rank;
            long pos_rank = this.H.Select1 (rank);
            // int high_weight = this.H.Rank0 (pos_rank) - 1;
            long high_weight = pos_rank - rank;
            high_weight <<= this.GetNumLowerBits ();
            long ell = this.L [rank - 1];
            return high_weight | ell;
            //return (high_weight << this.GetNumLowerBits ()) | ((long)this.L [rank - 1]);
        }