{'fraction_non_alphanumeric': 0.030620467365028204, 'fraction_numerical': 0.004834810636583401, 'mean_word_length': 4.886255924170616, 'pattern_counts': {'":': 0, '<': 0, '<?xml version=': 0, '>': 0, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
P6- and triangle-free graphs revisited: structure and bounded clique-width

The Maximum Weight Stable Set (MWS) Problem is one of the fundamental problems on graphs. It is well-known to be NP-complete for triangle-free graphs, and Mosca has shown that it is solvable in polynomial time when restricted to P6- and triangle-free graphs. We give a complete structure analysis of (nonbipartite) P6- and triangle-free graphs which are prime in the sense of modular decomposition. It turns out that the structure of these graphs is extremely simple implying bounded clique-width and thus, efficient algorithms exist for all problems expressible in terms of Monadic Second Order Logic with quantification only over vertex predicates. The problems Vertex Cover, MWS, Maximum Clique, Minimum Dominating Set, Steiner Tree, and Maximum Induced Matching are among them. Our results improve the previous one on the MWS problem by Mosca with respect to structure and time bound but also extends a previous result by Fouquet, Giakoumakis and Vanherpe which have shown that bipartite P6-free graphs have bounded clique-width. Moreover, it covers a result by Randerath, Schiermeyer and Tewes on polynomial time 3-colorability of P6- and triangle-free graphs.