Questions tagged [rank]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
0 votes
0 answers
39 views

Binary combinatorics with rank

I am looking at finding acceptable binary values with maximum 2 consecutive 1s and 0s, from a range of maximum 6 bits (2^6 values). Also, I want to rank and unrank these subset of values (in ...
Dave's user avatar
  • 23
0 votes
0 answers
27 views

DFA for "K" bit value with max "n" consecutive "0"s and "1"s

I had posted earlier a question regarding ranking max "n" consecutive "0"s and "1"s in a "K"-bit string - Order in a subset I got clarification regarding how ...
Dave's user avatar
  • 23
0 votes
0 answers
32 views

Finding Minimum Elements for Longest Path in Disjoint Set

I want to know the minimum number of elements needed to create a tree with the longest path having n edges. How can I approach this problem using the forest implementation of disjoint sets with union ...
user159841's user avatar
1 vote
0 answers
41 views

What is the worst case time complexity of unranking n choose k combinations (combinatorial number system, combinadics)

The combinatorial number system shows that there is a bijection between the natural numbers less than $n \choose k$ and $n\choose k$ combinations. There is a greedy algorithm for unranking ...
Quantum Guy 123's user avatar
2 votes
1 answer
78 views

Find a key in a BBST for which sum of values of keys smaller then it - is maximal

I'm required to describe an implementation of a data structure that holds key,value pairs, which can be signed integers. We need to be able to init() in O(1), insert(x) in O(logn), delete(x) in O(logn)...
sadcat_1's user avatar
  • 165
1 vote
1 answer
151 views

Rank of a graph in matroid theory

I was going through the concept of graphs as matroids and I came upon the rank of a graph. Wikipedia lists it as $n - c$, $n = |V|$, $c =$ # of connected components. I do understand rank and nullity ...
Ash Ketchum's user avatar
1 vote
1 answer
84 views

Why merge into the larger tree in union by rank

When we do union by rank we merge the smaller tree into the larger tree. I dont understand why we do this exactly?
Trajan's user avatar
  • 143
0 votes
0 answers
21 views

Reference selection for rating assignment based on pair comparison

Background: a set of 300 images are prepared, randomly pair compared with 60 other images, assigned a rating (from 1-star to 5-star) based on the pair comparison score (+1 if wins a pair comparison ...
PhysicsMath's user avatar
0 votes
2 answers
83 views

How can I get index of combination from element indices

An array of combinations is generated from two arrays, ...
Jin Kwon's user avatar
  • 103