Accidents brought on by pipeline corrosion have been common in recent years. The number of pipeline failure accidents caused by external factors has decreased annually, and the proportion of pipeline failures caused by corrosion has been increasing. Therefore, reducing or avoiding the internal corrosion of oil pipelines is an urgent problem that must be solved. Currently, the mainstream repair material is epoxy resin modified with only one or two rigid particles, which often exhibits insufficient hardness and hydrophobicity when dealing with a complex tube environment and can easily lead to the occurrence of secondary accidents. To improve the hardness and hydrophobicity of the repair materials and provide the most suitable material ratio for different environments, a new rigid nanomodified epoxy resin repair coating was designed for in-pipe repairs. The coating is based on a graphene-modified bisphenol A epoxy resin. Using the orthogonal experimental design technique, nanopowders with different proportions of nano-Al2O3, nano-TiO2, and nano-SiO2 were divided into 17 experimental groups, and the nanopowders from each group were combined with the same amount of unmodified epoxy resin. Rigid nanoparticles of different proportions were evenly dispersed in epoxy resin using multiple ultrasonic dispersions, and intermolecular fastening was carried out using a coupling agent. After filtering, drying, and curing, 17 new repair coatings with uniform densities were obtained. In the theoretical section, the grey prediction model is used to generate the known data series, valuable information is extracted by modeling, and a mathematical model is established. In this study, a multi-factor grey model was used to simulate and fit the data. A modeling method was adopted. The whitening equation was used to describe the law and form a response function to obtain the predicted results, thereby providing theoretical support for the multimaterial fusion experiments. In the experimental part, the nanopowders from each of the 17 experimental groups designed by the orthogonal test method were tested by SEM for morphology, water contact angle, and hardness, and the dispersion of nanorigid particles was observed by SEM electron scanning microscope. Hydrophobicity was determined using water contact angle data generated by a water contact angle measuring instrument. The hardness data were obtained using a hardness meter by attaching a test coating to the pipe. A multi-factor gray model of the contact angle and hardness was established, and the optimal ratio of the coating materials was obtained using a genetic algorithm. A multi-factor grey prediction model was established based on the water contact angle and hardness data, which were processed using a genetic algorithm. For the hardness value and contact angle of the 17 experimental groups, the optimal parameters were obtained by constantly calculating the fitness function through the selection, crossover, and optimization operations of the experimental data and the combination of output parameters. The optimal coating ratio was determined using the adaptive value (hardness + contact Angle hardness), and the absolute value of the adaptive value obtained (hardness: 49.834 N / mm(2), contact angle: 97.7 degrees) was 147.534. The adaptive value of the pure epoxy resin without rigid particles was 117.5 (hardness: 31.6 N / mm(2)). The contact angle was 85.9 degrees, the optimal ratio for SiO2:Al2O3: TiO2 0.146:4. 849: 0.006. The experimental results show that the gray model can accurately establish the relationship between the coating properties and rigid particles. The optimal coating ratio increased the hardness and hydrophobicity of graphene-modified bisphenol A epoxy resin by 60% and 23%, respectively, with an average error of less than 4%. The relationship between the nanorigid particles and coating properties can be used as a theoretical basis for the configuration of different coatings in different working environments.