EN
Let G = (V (G),E(G)) be a nontrivial connected graph of order n with an edge-coloring c : E(G) → {1, 2, . . . , q}, q ∈ N, where adjacent edges may be colored the same. A tree T in G is a rainbow tree if no two edges of T receive the same color. For a vertex set S ⊆ V (G), a tree connecting S in G is called an S-tree. The minimum number of colors that are needed in an edge-coloring of G such that there is a rainbow S-tree for each k-subset S of V (G) is called the k-rainbow index of G, denoted by rxk(G), where k is an integer such that 2 ≤ k ≤ n. Chartrand et al. got that the k-rainbow index of a tree is n−1 and the k-rainbow index of a unicyclic graph is n−1 or n−2. So there is an intriguing problem: Characterize graphs with the k-rainbow index n − 1 and n − 2. In this paper, we focus on k = 3, and characterize the graphs whose 3-rainbow index is n − 1 and n − 2, respectively.