# Research on Grain Moisture Model Based on Improved SSA-SVR Algorithm
## 1 Introduction  
Grains are an important foundation of the national economy and a key factor in ensuring social stability. Given China's current population of 1.3 billion people, the demand for grains is self-evident, leading to a tight balance between supply and demand. Currently, international grain prices are fluctuating, necessitating the smooth development of agriculture in China. China must feed nearly a quarter of the world's population with less than 10% of the world's arable land. However, statistics show that nearly 10% of grains in China become moldy and rot during storage and transportation each year, resulting in estimated losses of billions of kilograms annually. This loss is extremely severe. A significant portion of China's grain production consists of high-moisture grains. Due to their high moisture content, these grains require drying during storage and transportation. Otherwise, they are prone to spoilage and deterioration. Thus, effectively controlling the moisture content of grains is crucial. Drying grains is a continuous process. Initially, processed grains are fed into drying towers where they undergo stages such as preheating, dehydration, equilibration, and cooling until their moisture content reaches the standard level before being discharged from the tower. Monitoring the moisture content of grains throughout the drying process is extremely important. However, due to various environmental factors affecting the detection process, real-time online measurement becomes quite challenging [1; 2]. Providing a method that can, to some extent, mitigate the interference of environmental factors and more accurately obtain the moisture content of grains is undoubtedly good news for the grain industry. Grain moisture detection technologies include the oven-drying method, resistance method, capacitance method, microwave method, neutron method, etc. Compared to other methods, the resistance method has higher accuracy, faster measurement speed, a wider range of applicability, simpler equipment, and lower costs. The temperature of the grain significantly affects its resistance, which manifests as the equivalent resistance of the grain decreasing with an increase in temperature [3; 4]. Experimental research has shown that at normal temperatures (\(-10\)\({}^{\circ}\)C to \(+50\)\({}^{\circ}\)C) [5; 6], an increase in temperature has an effect on resistance equivalent to an increase in moisture content of 0.1% (moisture content) per degree Celsius. This paper conducts moisture detection on long-grain rice at 30 \({}^{\circ}\)C using the resistance method with a homemade moisture meter. After converting the electrical resistance of the rice grains into voltage values and correlating them with the corresponding moisture content, the collected data are used to establish a model using machine learning. This model allows for the timely and accurate assessment of the grain's moisture content. Based on the training model results, appropriate adjustments and optimizations are made. Finally, by analyzing historical data for trend determination, we provide new methods and ideas for moisture management during the grain drying process. In 2020, [PERSON] proposed the Sparrow Search Algorithm (SSA) based on the behavior of sparrows searching for food while avoiding predators. The optimization ability, fast convergence speed, and good stability of the SSA algorithm are better than the current swarm intelligence optimization algorithms [7], showing excellent search capabilities. In the SSA algorithm, the behavior of sparrows searching for food while avoiding predators is considered as a process of seeking the optimal solution within a specific range. Each sparrow represents a solution vector, and its flight speed and direction are influenced by its fitness. Sparrows randomly fly within a specific range of space, updating their positions and fitness values with each flight to find the global optimal value throughout the process.