An algorithm for automatic switching of a two-speed pump based on the rotational speed of a ship

By designing an algorithm including data acquisition, status judgment and switching control module, the problems of inaccurate switching of two-speed pumps and waste of energy are solved, and the frequency optimization of the switching of two-speed pumps according to demand is realized, which is suitable for a variety of ships.

CN118757379BActive Publication Date: 2025-06-24CHINA STATE SHIPBUILDING CORP LTD RESEARCH INSTITUTE 719
View PDF 8 Cites 0 Cited by

Patent Information

Application Number
CN202410855733.7
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-06-28
Publication Date
2025-06-24
Estimated Expiration
2044-06-28

AI Technical Summary

Technical Problem

The existing technology cannot realize the rapid switching function of the two-speed pump according to demand, the collection and processing function of the ship's speed data, the analysis and judgment function of the ship's speed, and the optimization function of the switching frequency of the two-speed pump, resulting in the inaccurate switching of the pump speed of the ship under different operating conditions, and energy is wasted and it is impossible to widely apply to a variety of ships.

Method used

An algorithm for automatic switching of two-speed pumps based on the speed of the ship is designed, including a data acquisition module, a state judgment module and a switching control module. Through the data connection of local network, real-time acquisition and processing of ship speed data is realized, analyzing and judging the current status, and the automatic switching and switching frequency of the dual-speed pump are optimized through the switching control module.

Benefits of technology

The two-speed pump is quickly switched according to demand, which improves the accuracy and timeliness of switching, saves energy, and is suitable for a variety of ships to ensure stable operation of ships under different working conditions.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118757379B_ABST
    Figure CN118757379B_ABST
Patent Text Reader

Abstract

The present invention discloses an algorithm for automatically switching a two-speed pump according to the rotational speed of a ship, which relates to the technical field of automatic switching of two-speed pumps. It includes a data acquisition module, a state judgment module, and a switching control module. The data acquisition module is connected to both the state judgment module and the switching control module through local area network data. The switching control module is used to automatically switch the two-speed pump according to the rotational speed of the ship. The switching control module includes: a low-speed pump switching unit, a high-speed pump switching unit, and a switching state recording unit. By designing the switching control module, the present invention realizes the function of quickly switching the two-speed pump according to requirements, solves the switching requirements of the pump rotational speed under different operating states of the ship, ensures the stable operation of the ship under different working conditions, and achieves the purpose of energy conservation and emission reduction.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of automatic switching of two-speed pumps, and specifically to an algorithm for automatically switching two-speed pumps according to the rotational speed of a ship. Background Art

[0002] With the development of the shipbuilding industry, the automatic switching system of two-speed pumps plays a key role in improving the efficiency and flexibility of the ship's power system. The traditional single-speed pump system has problems such as low energy efficiency and poor adaptability when dealing with different operating states. The traditional switching system usually uses a fixed rotational speed threshold to trigger the switching, and cannot adapt to the changes in different working conditions and ship operating states, resulting in poor performance of the system in some cases. The traditional system is difficult to effectively adjust the rotational speed of the pump according to actual needs, leading to low energy efficiency, energy waste, and unnecessary fuel consumption. There is relatively little research on the optimization of switching frequency and parameter adaptability for different working conditions and load characteristics, and there is a lack of means for intelligent operation and optimization.

[0003] Therefore, there is an urgent need for a more intelligent and adaptive solution. It is very necessary for this application to propose an algorithm for automatically switching two-speed pumps according to the rotational speed of a ship to solve the defects existing in the prior art.

[0004] 1. Patent document CN112228328B discloses a method for hot standby switching of double extraction pumps. The above patent realizes analyzing the real-time operation data of the extraction pump according to the data collected by temperature and vibration sensors, and inputting the real-time data into the PLC control system to automatically switch the extraction pump through the PLC control system, with high switching efficiency. However, the above patent cannot realize the function of quickly switching two-speed pumps according to requirements.

[0005] 2. Patent document CN110985653B discloses an automatic transmission hydraulic oil supply system. The above patent realizes high power utilization rate, and the grade requirements of components and wiring harnesses and other accessories are synchronously reduced, reducing costs and system complexity. However, the above patent cannot realize the function of collecting and processing the rotational speed data of a ship.

[0006] 3. Patent document CN104564868B discloses a confluence control system, method, and crane. The above patent realizes improving micro-mobility and reducing energy consumption. However, the above patent cannot realize the function of analyzing and judging the rotational speed of a ship.

[0007] 4. Patent document CN107618565B discloses a switching control method for a dual-source emergency electric power steering system. The above patent realizes the smooth switching of high and low pressure power steering systems, avoiding the time delay caused by the vehicle controller sending an emergency start command. However, the above patent cannot realize the function of optimizing the switching frequency of two-speed pumps.

[0008] In summary, the above-mentioned patent cannot achieve the functions of rapid switching of the two-speed pump according to requirements, the acquisition and processing of ship speed data, the analysis and judgment of ship speed, and the optimization of the switching frequency of the two-speed pump, resulting in the problems of not meeting the switching requirements of the pump speed under different operating states of the ship, inaccurate switching, energy waste, and inability to be widely applicable to various ships;

[0009] Therefore, this application proposes an algorithm for automatically switching a two-speed pump according to the ship's speed, which can achieve the functions of rapid switching of the two-speed pump according to requirements, the acquisition and processing of ship speed data, the analysis and judgment of ship speed, and the optimization of the switching frequency of the two-speed pump. Summary of the Invention

[0010] The purpose of the present invention is to provide an algorithm for automatically switching a two-speed pump according to the ship's speed, so as to solve the problems in the above-mentioned background technology that the functions of rapid switching of the two-speed pump according to requirements, the acquisition and processing of ship speed data, the analysis and judgment of ship speed, and the optimization of the switching frequency of the two-speed pump cannot be achieved, resulting in the inability to meet the switching requirements of the pump speed under different operating states of the ship, inaccurate switching, energy waste, and the inability to be widely applicable to various ships.

[0011] To achieve the above purpose, the present invention provides the following technical solution: An algorithm for automatically switching a two-speed pump according to the ship's speed, including a data acquisition module, a state judgment module, and a switching control module. The data acquisition module is connected to the state judgment module and the switching control module through local area network data. The switching control module is used for automatically switching the two-speed pump according to the ship's speed;

[0012] The switching control module includes: a low-speed pump switching unit, a high-speed pump switching unit, and a switching state recording unit;

[0013] The low-speed pump switching unit includes a PID control algorithm, an electro-hydraulic servo valve, and a CAN bus. The low-speed pump switching unit uses the PID control algorithm to send PID control instructions to the electro-hydraulic servo valve through the CAD bus according to real-time speed data to adjust the valve opening;

[0014] The high-speed pump switching unit includes an inverter, a motor, and a Fuzzy Logic control algorithm. The high-speed pump switching unit uses the Fuzzy Logic control algorithm to control the inverter to control the starting process of the motor and adjusts the motor input gradually in real time;

[0015] The switching state recording unit integrates an EEPROM and an I2C bus, records the start state, target state, and switching time information at each switching, performs data reading and writing using the I2C bus, and stores the detailed switching information in the EEPROM.

[0016] Preferably, the data acquisition module is used to collect and process the engine speed data of the ship;

[0017] The data acquisition module includes: a sensor interface unit, a data preprocessing unit, and a data storage unit;

[0018] The sensor interface unit includes a magnetic speed sensor and the Modbus RTU communication protocol. The magnetic speed sensor is installed in the engine, configured as a Modbus RTU slave mode, the communication address is set, and the data of the magnetic speed sensor is read through the serial port module of Arduino Due by the Modbus RTU protocol;

[0019] The data preprocessing unit integrates a digital low-pass filter and the Kalman filtering algorithm. The FIR algorithm is used to perform digital low-pass filtering on the data of the magnetic speed sensor to eliminate high-frequency noise, and the Kalman filtering algorithm is used to perform real-time smoothing processing on the output of the magnetic speed sensor data;

[0020] The data storage unit integrates the MariaDB database, the MySQL database, and the InnoDB storage engine. The database table structure is configured, including fields such as timestamp and speed value. MariaDB is used as the database management system to ensure data integrity.

[0021] Preferably, a threshold setting module is designed in the data preprocessing unit, and the threshold setting module is used to dynamically set and adjust the thresholds for high and low speeds of the engine;

[0022] The threshold setting module includes a low-speed threshold setting unit, a high-speed threshold setting unit, and a switching delay setting;

[0023] The low-speed threshold setting unit integrates Simulink and the PID control algorithm. System identification is carried out using Simulink, and the PID control algorithm is used to automatically adjust the minimum speed threshold for starting the low-speed pump to achieve online parameter adjustment;

[0024] The high-speed threshold setting unit integrates the RNN recursive neural network and TensorFlow. Online learning is carried out using the RNN recursive neural network, and the minimum speed threshold for starting the high-speed pump is adjusted according to the real-time performance data. TensorFlow is used as the machine learning framework to achieve adaptive optimization of the threshold;

[0025] The switching delay setting unit integrates a real-time clock module and the timer library of Python. Using the real-time clock module, millisecond-level switching delay control is achieved through hardware interrupts, and configurable switching delay options are provided in the user interface, which is achieved through the timer library of Python.

[0026] Preferably, the state judgment module is used to judge the engine speed in real time and transmit the state information to the switching control module;

[0027] The state judgment module includes: a current state judgment unit, a state stability detection unit, and a state feedback unit;

[0028] The current state judgment unit integrates a finite state machine algorithm and the Stateflow toolbox. The Stateflow toolbox is used to model the finite state machine algorithm, define three states of low speed, medium speed, and high speed. Based on the event-driven model, the trigger mechanism is used to update the state to ensure real-time performance and accuracy;

[0029] The state stability detection unit integrates an average filtering algorithm and MATLAB. The average filtering algorithm is used to smooth the engine speed data, and MATLAB is used for system simulation to evaluate the smoothness of state changes;

[0030] The state feedback unit integrates a message queue algorithm and the WebSocket protocol. MQTT is used to achieve real-time transmission of state information to ensure low-latency state feedback. Using the WebSocket protocol, the real-time state information is transmitted to the user interface through the WebSockets library.

[0031] Preferably, a switching optimization module is also designed in the switching control module. The switching optimization module is used to optimize the switching frequency and response speed of the two-speed pump for the switching control module;

[0032] The switching optimization module includes: a switching frequency optimization unit, a load adaptability unit, and an adaptive parameter adjustment unit;

[0033] The switching frequency optimization unit integrates Python, the NumPy library, and the K-means clustering algorithm. The NumPy library of Python is used for historical data analysis to obtain the switching frequency. The K-means clustering algorithm is used to identify the switching modes under different operating conditions and optimize the switching frequency;

[0034] The load adaptability unit integrates a fuzzy logic control algorithm and the Scikit-learn library. The Scikit-learn library is used to model the fuzzy logic system. Considering the real-time load data, the response speed of the switching algorithm is dynamically adjusted according to the load characteristics. Using the fuzzy logic control algorithm, the threshold is dynamically adjusted according to the real-time load data;

[0035] The adaptive parameter adjustment unit integrates a reinforcement learning algorithm, TensorFlow, and OpenAI Gym. By introducing the reinforcement learning algorithm, online parameter adjustment is performed using the TensorFlow framework, and environment simulation is achieved using OpenAI Gym, enabling the system to continuously learn and optimize.

[0036] Preferably, the data acquisition module, the state judgment module, and the switching control module are connected to a user interface interaction module through a data cable. The user interface interaction module is used to display the information of the ship's rotational speed and pump status in real time.

[0037] The user interface interaction module includes: a real-time data display unit, a manual control interface unit, and an alarm information display unit.

[0038] The real-time data display unit integrates React.js, D3.js, and WebSocket. A modern Web interface is built using React.js and D3.js, and the current rotational speed, pump status, and system operation status are displayed in real time using WebSocket technology.

[0039] The manual control interface unit integrates the QT framework and OpenGL acceleration technology. A user-friendly manual control interface is designed based on the QT framework, and OpenGL acceleration technology is used to ensure the smoothness and response speed of the interface, providing an intuitive manual control panel that supports multi-platform use.

[0040] The alarm information display unit integrates HTML5, CSS3, and Web Audio API. A responsive alarm information display interface is designed using HTML5 and CSS3 technologies, and a sound library is integrated. Sound prompts for alarm information are achieved through the Web Audio API, detailed alarm information is displayed, and the sensitivity of the operator to problems is improved through sound and visual prompts.

[0041] Preferably, the formula of the PID control algorithm in the low-speed pump switching unit is as follows:

[0042]

[0043] Among them, U(t) is the output of the controller, that is, the valve opening of the electro-hydraulic servo valve, e(t) is the error between the current rotational speed set value and the actual rotational speed value, K p is the proportional gain, controlling the proportional action, K i is the integral gain, controlling the integral action, K d is the derivative gain, controlling the derivative action.

[0044] Preferably, the application steps of the Fuzzy Logic control algorithm integrated in the high-speed pump switching unit are as follows:

[0045] Obtain the speed setting value (usually a preset value) for starting the target high-speed pump and the current actual speed value;

[0046] Calculate the error and change rate of the current speed, and obtain the speed error and change rate based on system feedback;

[0047] Map the speed error and change rate to fuzzy rules, and calculate the fuzzy output of the motor input;

[0048] Use defuzzification technology to convert the fuzzy output into a specific motor input value;

[0049] Apply the calculated motor input value to motor control, and gradually increase the motor input to ensure smooth startup of the high-speed pump;

[0050] According to system feedback, update the fuzzy rules and membership functions in real time to improve the stability and response speed of the system.

[0051] Compared with the prior art, the beneficial effects of the present invention are:

[0052] 1. By designing a switching control module, the present invention realizes the function of quickly switching the two-speed pump according to requirements, solves the switching requirements of the pump speed under different operating states of the ship, ensures the stable operation of the ship under different working conditions, and achieves the purpose of energy conservation and emission reduction;

[0053] 2. By designing a data acquisition module, the present invention realizes the functions of collecting and processing the ship speed data, provides real-time and accurate ship speed data, provides input for the switching control module and the state judgment module, improves the accuracy and timeliness of the two-speed pump switching, and achieves the purpose of energy conservation and emission reduction;

[0054] 3. By designing a state judgment module, the present invention realizes the function of analyzing and judging the ship speed, determines the current operating state of the ship, provides a judgment basis for the switching of the two-speed pump, and makes the system more flexible and applicable;

[0055] 4. By designing a switching optimization module, the present invention realizes the function of optimizing the switching frequency of the two-speed pump, improves the efficiency of the switching system, reduces unnecessary speed switching, and adapts to the actual operation of the ship. BRIEF DESCRIPTION OF THE DRAWINGS

[0056] Figure 1 It is a schematic diagram of the switching control module of the present invention;

[0057] Figure 2 It is a schematic diagram of the data acquisition module of the present invention;

[0058] Figure 3 It is a schematic diagram of the state judgment module of the present invention;

[0059] Figure 4 Schematic diagram of the switching optimization module of the present invention; Detailed implementation manners

[0060] The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are only a part of the embodiments of the present invention, rather than all of the embodiments. All other embodiments obtained by those of ordinary skill in the art based on the embodiments of the present invention without creative efforts shall fall within the protection scope of the present invention.

[0061] Embodiment 1

[0062] Please refer to Figure 1 and Figure 3 An embodiment provided by the present invention: An algorithm for automatically switching a two-speed pump according to the rotational speed of a ship, including a data acquisition module, a state judgment module, and a switching control module. The data acquisition module is connected to the state judgment module and the switching control module through a local area network data connection. The switching control module is used to automatically switch the two-speed pump according to the rotational speed of the ship;

[0063] The switching control module includes: a low-speed pump switching unit, a high-speed pump switching unit, and a switching state recording unit;

[0064] The low-speed pump switching unit includes a PID control algorithm, an electro-hydraulic servo valve, and a CAN bus. The low-speed pump switching unit uses the PID control algorithm to send a PID control instruction to the electro-hydraulic servo valve through the CAD bus according to the real-time rotational speed data to adjust the valve opening;

[0065] The high-speed pump switching unit includes a frequency converter, a motor, and a Fuzzy Logic control algorithm. The high-speed pump switching unit uses the Fuzzy Logic control algorithm to control the frequency converter to control the starting process of the motor and adjusts the motor input gradually in real time;

[0066] The switching state recording unit integrates an EEPROM and an I2C bus, records the starting state, target state, and switching time information during each switching, performs data reading and writing using the I2C bus, and stores the detailed switching information in the EEPROM;

[0067] Furthermore, the PID algorithm is used to adjust the electro-hydraulic servo valve according to the real-time rotational speed data to ensure a smooth transition during the low-speed pump switch. The PID control command is sent to the electro-hydraulic servo valve via the CAN bus to adjust the valve opening, achieving a smooth transition of the hydraulic system during the low-speed pump switch. The Fuzzy Logic control algorithm is used to adjust the motor input in real time to ensure a gradual transition during the high-speed pump startup. The frequency converter is used to control the motor startup process, gradually increasing the motor input to achieve a smooth startup of the motor during the high-speed pump switch, reducing shock and vibration. Information such as the starting state, target state, and switching time is recorded during each switch. The I2C bus is used for data reading and writing, and the switching details are stored in the EEPROM.

[0068] Embodiment 2

[0069] Please refer to Figure 1 and Figure 2 An embodiment provided by the present invention: An algorithm for automatically switching a two-speed pump according to the rotational speed of a ship. The data acquisition module is used to collect and process the rotational speed data of the ship's engine;

[0070] The data acquisition module includes: a sensor interface unit, a data preprocessing unit, and a data storage unit;

[0071] The sensor interface unit includes a magnetic rotational speed sensor and the Modbus RTU communication protocol. The magnetic rotational speed sensor is installed in the engine, configured as a Modbus RTU slave mode, the communication address is set, and the data of the magnetic rotational speed sensor is read through the serial port module of Arduino Due via the Modbus RTU protocol;

[0072] The data preprocessing unit integrates a digital low-pass filter and the Kalman filtering algorithm. The FIR algorithm is applied to perform digital low-pass filtering on the data of the magnetic rotational speed sensor to eliminate high-frequency noise, and the Kalman filtering algorithm is used to perform real-time smoothing processing on the output of the magnetic rotational speed sensor data;

[0073] The data storage unit integrates the MariaDB database, the MySQL database, and the InnoDB storage engine. The database table structure is configured, including fields for timestamp and rotational speed value. MariaDB is used as the database management system to ensure data integrity;

[0074] Further, set the Honeywell HMC1022 magnetic rotational speed sensor to the Modbus RTU slave mode, specify the communication address, read the sensor data through the Modbus RTU communication protocol using the serial port module of the Arduino Due, apply the FIR filtering algorithm to perform digital low-pass filtering on the sensor output to eliminate high-frequency noise, use the Kalman filtering algorithm to perform real-time smoothing processing on the sensor output, configure the MariaDB database table structure, including fields such as timestamp and rotational speed value, use MariaDB as the database management system to ensure data integrity, and store the rotational speed data in real time.

[0075] Embodiment 3

[0076] Please refer to Figure 1 、 Figure 2 and Figure 3 For an embodiment provided by the present invention: an algorithm for automatically switching a two-speed pump according to the rotational speed of a ship, a threshold setting module is designed in the data preprocessing unit, and the threshold setting module is used to dynamically set and adjust the thresholds for the high and low speeds of the engine;

[0077] The threshold setting module includes a low-speed threshold setting unit, a high-speed threshold setting unit, and a switching delay setting;

[0078] The low-speed threshold setting unit integrates Simulink and the PID control algorithm. System identification is performed using Simulink, and the PID control algorithm is used to automatically adjust the minimum rotational speed threshold for starting the low-speed pump to achieve online parameter adjustment;

[0079] The high-speed threshold setting unit integrates the RNN recursive neural network and TensorFlow. Online learning is performed using the RNN recursive neural network, and the minimum rotational speed threshold for starting the high-speed pump is adjusted according to real-time performance data. TensorFlow is used as the machine learning framework to achieve adaptive optimization of the threshold;

[0080] The switching delay setting unit integrates a real-time clock module and the timer library of Python. Using the real-time clock module, millisecond-level switching delay control is achieved through hardware interrupts, and configurable switching delay options are provided in the user interface through the timer library of Python;

[0081] Furthermore, the minimum speed threshold for starting the low-speed pump is adjusted online using the PID control algorithm. System identification is performed using Simulink, and the starting threshold of the low-speed pump is automatically adjusted by analyzing real-time performance data. The dynamically adjusted low-speed threshold is fed back to the switching control module. Online learning is carried out using a Recurrent Neural Network (RNN), and the minimum speed threshold for starting the high-speed pump is adjusted according to real-time performance data. TensorFlow is used as a machine learning framework to achieve adaptive optimization of the threshold. The dynamically adjusted high-speed threshold is fed back to the switching control module. A real-time clock module is used to implement millisecond-level switching delay control through hardware interrupts. Configurable switching delay options are provided in the user interface, which is implemented through the timer library of Python. The dynamically adjusted switching delay is fed back to the switching control module.

[0082] Embodiment 4

[0083] Please refer to Figure 1 、 Figure 2 and Figure 3 An embodiment provided by the present invention: An algorithm for automatically switching a two-speed pump according to the rotational speed of a ship. The state judgment module is used to judge the engine rotational speed in real time and transmit the state information to the switching control module;

[0084] The state judgment module includes: a current state judgment unit, a state stability detection unit, and a state feedback unit;

[0085] The current state judgment unit integrates the finite state machine algorithm and the Stateflow toolbox. The finite state machine algorithm is modeled using the Stateflow toolbox, defining three states: low speed, medium speed, and high speed. Based on the event-driven model, the trigger mechanism is used to update the state to ensure real-time performance and accuracy;

[0086] The state stability detection unit integrates the average filtering algorithm and MATLAB. The average filtering algorithm is used to smooth the engine rotational speed data, and MATLAB is used for system simulation to evaluate the smoothness of state changes;

[0087] The state feedback unit integrates the message queue algorithm and the WebSocket protocol. MQTT is used to achieve real-time transmission of state information to ensure low-latency state feedback. Using the WebSocket protocol, the real-time state information is transmitted to the user interface through the WebSockets library;

[0088] Furthermore, obtain real-time rotational speed data through the data acquisition module as the input for state judgment. Use the Stateflow toolbox to establish a finite state machine algorithm model, define three states: low speed, medium speed, and high speed, and stipulate the transition conditions between states. Formulate accurate judgment rules. In the low-speed state, the system rotational speed is less than the set low-speed threshold; in the medium-speed state, the system rotational speed is between the low-speed and high-speed thresholds, continuously monitor the sensor data, update the current system state according to the state machine model, use methods such as sliding window to perform real-time smoothing processing on the rotational speed data to improve the accuracy and stability of the state, apply average filtering to process the rotational speed data to eliminate noise interference, use MATLAB for system simulation to evaluate the smoothness of state changes, use the message passing mechanism to transmit real-time state information to the switching control module and other relevant modules, and transmit the state information to the user interface through the WebSocket communication protocol to achieve real-time monitoring. Use the event trigger mechanism, such as triggering when exceeding a specific rotational speed threshold or time interval, to update the system state.

[0089] Embodiment 5

[0090] Please refer to Figure 2 and Figure 4 For an embodiment provided by the present invention: An algorithm for automatic switching of a two-speed pump according to the rotational speed of a ship, a switching optimization module is further designed in the switching control module, and the switching optimization module is used to optimize the switching frequency and response speed of the two-speed pump switching for the switching control module;

[0091] The switching optimization module includes: a switching frequency optimization unit, a load adaptability unit, and an adaptive parameter adjustment unit;

[0092] The switching frequency optimization unit integrates Python, the NumPy library, and the K-means clustering algorithm. Use the NumPy library of Python to analyze historical data to obtain the switching frequency, and use the K-means clustering algorithm to identify the switching patterns under different operating conditions to optimize the switching frequency;

[0093] The load adaptability unit integrates the fuzzy logic control algorithm and the Scikit-learn library. Use the Scikit-learn library to model the fuzzy logic system, consider the real-time load data, dynamically adjust the response speed of the switching algorithm according to the load characteristics, and use the fuzzy logic control algorithm to dynamically adjust the threshold according to the real-time load data;

[0094] The adaptive parameter adjustment unit integrates the reinforcement learning algorithm, TensorFlow, and OpenAI Gym. Introduce the reinforcement learning algorithm, use the TensorFlow framework for online parameter adjustment, and use OpenAI Gym to implement environment simulation to enable the system to continuously learn and optimize;

[0095] Furthermore, obtain historical switching frequency data from the database, perform data analysis using the NumPy library in Python, count the switching frequencies in different time periods, identify the switching patterns under different operating conditions using the K-means clustering algorithm, adjust the switching frequency according to the switching patterns to ensure optimal switching performance under different conditions, model a fuzzy logic system using the Scikit-learn library, obtain real-time load data from the data acquisition module, dynamically adjust the response speed of the switching algorithm according to the output of the fuzzy logic system, continuously monitor the load characteristics, continuously adjust the adaptability of the system according to the real-time data to ensure stable operation of the system when the load changes, introduce a reinforcement learning algorithm, perform online parameter adjustment using the TensorFlow framework, implement environment simulation using OpenAI Gym, enable the system to continuously learn and optimize, dynamically adjust the parameters in the switching optimization module according to the output of the reinforcement learning algorithm to improve the system performance and stability, continuously monitor the system feedback, and update the reinforcement learning model in real time to ensure that the system can obtain the optimal switching strategy under different conditions.

[0096] Working principle: First, obtain the real-time rotational speed data of the ship through the data acquisition module. This module uses the Honeywell HMC1022 magnetic rotational speed sensor to transmit the rotational speed data to the system through the Modbus RTU communication protocol. The acquired data needs to go through a filtering algorithm and smoothing process to ensure accuracy and stability. Subsequently, the processed data is stored in the database in real time, using the MariaDB database management system;

[0097] Second, the state judgment module monitors the rotational speed state of the ship in real time. This module applies a finite state machine model, defines three states: low speed, medium speed, and high speed, uses the sensor data to perform real-time smoothing processing on the rotational speed data through methods such as a sliding window to improve the accuracy and stability of the state. The update of the state is event-driven. For example, it is triggered by exceeding a specific rotational speed threshold or time interval to ensure that the system's response to state changes is event-triggered rather than continuous;

[0098] Finally, the automatic switching of the two-speed pump is achieved through the switching control module. This module first makes a switching decision based on the current state and the preset low-speed and high-speed thresholds. If the current state requires switching, during the switching execution phase, the rotational speed of the pump will be adjusted according to the switching type. The low-speed pump adjusts the valve opening of the electro-hydraulic servo valve, while the high-speed pump achieves it by dynamically adjusting the motor input. During the switching process, the system will provide real-time feedback on the switching state and relevant information to the user interface and the performance monitoring module to ensure that the operator can timely understand the system operation status.

[0099] It is obvious to those skilled in the art that the present invention is not limited to the details of the above-described exemplary embodiments, and that the present invention can be implemented in other specific forms without departing from the spirit or essential characteristics of the present invention. Therefore, in any regard, the embodiments should be regarded as exemplary and non-limiting. The scope of the present invention is defined by the appended claims rather than the above description. Accordingly, all changes that fall within the meaning and scope of the equivalent elements of the claims are intended to be embraced within the present invention. Any reference signs in the claims should not be construed as limiting the claims involved.

Claims

1. A system for automatically switching a dual-speed pump according to the rotation speed of a ship, characterized in that: It includes a data acquisition module, a state judgment module and a switching control module. The data acquisition module is connected to the state judgment module and the switching control module through a local area network data connection. The switching control module is used to automatically switch the dual-speed pump according to the rotation speed of the ship. The switching control module includes: a low-speed pump switching unit, a high-speed pump switching unit and a switching state recording unit; The low-speed pump switching unit includes a PID control algorithm, an electro-hydraulic servo valve and a CAN bus. The low-speed pump switching unit uses the PID control algorithm to send a PID control instruction to the electro-hydraulic servo valve through the CAD bus according to real-time speed data to adjust the valve opening; The high-speed pump switching unit includes a frequency converter, a motor and a Fuzzy Logic control algorithm. The high-speed pump switching unit uses the Fuzzy Logic control algorithm to control the frequency converter to control the motor starting process, and adjusts and gradually increases the motor input in real time; The switching state recording unit integrates EEPROM and I2C bus, records the starting state, target state, and switching time information at each switching, uses I2C bus to read and write data, and stores the switching detailed information in EEPROM; The switching control module is also designed with a switching optimization module, which is used to optimize the switching frequency and response speed of the dual-speed pump of the switching control module; The switching optimization module includes: a switching frequency optimization unit, a load adaptability unit and an adaptive parameter adjustment unit; The switching frequency optimization unit integrates Python and K-means clustering algorithm, uses Python's NumPy library to analyze historical data, obtains switching frequency, and uses K-means clustering algorithm to identify switching modes under different operating conditions and optimize switching frequency; The load adaptability unit integrates fuzzy logic control algorithm and Scikit-learn library. The fuzzy logic system is established using Scikit-learn library. The response speed of the switching algorithm is dynamically adjusted according to the load characteristics, taking into account the real-time load data. The threshold is dynamically adjusted according to the real-time load data using the fuzzy logic control algorithm. The adaptive parameter adjustment unit integrates reinforcement learning algorithm, TensorFlow and OpenAI Gym. It introduces reinforcement learning algorithm, uses TensorFlow framework for online parameter adjustment, and uses OpenAI Gym to realize environmental simulation, allowing the system to continuously learn and optimize.

2. A system for automatically switching a dual-speed pump according to the rotation speed of a ship according to claim 1, characterized in that: The data acquisition module is used to collect and process the engine speed data of the ship; The data acquisition module includes: a sensor interface unit, a data preprocessing unit and a data storage unit; The sensor interface unit includes a magnetic speed sensor and a Modbus RTU communication protocol. The magnetic speed sensor is installed in the engine, configured as a Modbus RTU slave mode, and the communication address is set. The serial port module of the Arduino Due is used to read the magnetic speed sensor data through the Modbus RTU communication protocol. The data preprocessing unit integrates a digital low-pass filter and a Kalman filter algorithm. The FIR algorithm is used to perform digital low-pass filtering on the magnetic speed sensor data to eliminate high-frequency noise, and the Kalman filter algorithm is used to perform real-time smoothing on the magnetic speed sensor data output. The data storage unit integrates MariaDB database, MySQL database and InnoDB storage engine, configures the database table structure, including timestamp and speed value fields, and uses MariaDB as the database management system to ensure data integrity.

3. A system for automatically switching a dual-speed pump according to the rotation speed of a ship according to claim 2, characterized in that: The data preprocessing unit is designed with a threshold setting module, which is used to dynamically set and adjust the thresholds of the engine high and low speeds; The threshold setting module includes a low-speed threshold setting unit, a high-speed threshold setting unit and a switching delay setting; The low-speed threshold setting unit integrates Simulink and PID control algorithm. Simulink is used for system identification, and the PID control algorithm is used to automatically adjust the minimum speed threshold for starting the low-speed pump to achieve online parameter adjustment. The high-speed threshold setting unit integrates RNN recursive neural network and TensorFlow. The RNN recursive neural network is used for online learning to adjust the minimum speed threshold for high-speed pump startup according to real-time performance data. TensorFlow is used as a machine learning framework to achieve adaptive optimization of the threshold. The switching delay setting unit integrates a real-time clock module and a Python timer library. The real-time clock module is used to implement millisecond-level switching delay control through hardware interrupts, and a configurable switching delay option is provided in the user interface, which is implemented through the Python timer library.

4. A system for automatically switching a dual-speed pump according to the rotation speed of a ship according to claim 1, characterized in that: The state determination module is used to determine the engine speed in real time and transmit the state information to the switching control module; The state judgment module includes: a current state judgment unit, a state stability detection unit and a state feedback unit; The current state judgment unit integrates the finite state machine algorithm and the Stateflow toolbox. The Stateflow toolbox is used to model the finite state machine algorithm, and three states of low speed, medium speed and high speed are defined. Based on the event-driven model, the trigger mechanism is used to update the state to ensure real-time performance and accuracy. The state stability detection unit integrates the average filtering algorithm and MATLAB, uses the average filtering algorithm to smooth the engine speed data, uses MATLAB to simulate the system, and evaluates the stability of state changes; The state feedback unit integrates the message queue algorithm and the WebSocket protocol, uses MQTT to achieve real-time transmission of state information, ensures low-latency state feedback, and uses the WebSocket protocol to pass real-time state information to the user interface through the WebSockets library.

5. The system for automatically switching a dual-speed pump according to the rotation speed of a ship according to claim 1, characterized in that: The data acquisition module, the state judgment module and the switching control module are connected to a user interface interaction module via a data line, and the user interface interaction module is used to display the information of the rotation speed of the ship and the pump state in real time; The user interface interaction module includes: a real-time data display unit, a manual control interface unit and an alarm information display unit; The real-time data display unit integrates React.js, D3.js and WebSocket. React.js and D3.js are used to build a modern web interface, and WebSocket technology is used to display the current speed, pump status and system operation status in real time; The manual control interface unit integrates QT framework and OpenGL acceleration technology. A user-friendly manual control interface is designed based on the QT framework. OpenGL acceleration technology is used to ensure interface fluidity and response speed, provide an intuitive manual control panel, and support multi-platform use. The alarm information display unit integrates HTML5, CSS3 and Web Audio API. It uses HTML5 and CSS3 technologies to design a responsive alarm information display interface, integrates a sound library, implements sound prompts for alarm information through Web Audio API, displays detailed alarm information, and improves the operator's sensitivity to problems through sound and visual prompts.

6. The system for automatically switching a dual-speed pump according to the rotation speed of a ship according to claim 1, characterized in that: The PID control algorithm formula in the low-speed pump switching unit is as follows: Among them, U(t) is the controller output, that is, the valve opening of the electro-hydraulic servo valve, e(t) is the error between the current speed setting value and the actual speed value, K p is the proportional gain, controlling the proportional action, K i is the integral gain, controlling the integral action, K d is the differential gain, which controls the differential action.

7. The system for automatically switching a dual-speed pump according to the rotation speed of a ship according to claim 1, characterized in that: The application steps of the Fuzzy Logic control algorithm integrated in the high-speed pump switching unit are as follows: Obtain the speed setting value and current actual speed value of the target high-speed pump startup; Calculate the error and change rate of the current speed, and obtain the speed error and change rate based on system feedback; Map the speed error and rate of change to fuzzy rules and calculate the fuzzy output of the motor input; Use defuzzification techniques to convert fuzzy outputs into specific motor input values; Apply the calculated motor input value to the motor control, gradually increasing the motor input to ensure smooth start-up of the high-speed pump; According to system feedback, fuzzy rules and membership functions are updated in real time to improve the stability and response speed of the system.

Citation Information

Patent Citations

  • Merging control system, method and crane

    CN104564868B

  • A switching control method for a dual-source emergency electric power steering system

    CN107618565B

  • An automatic transmission hydraulic oil supply system

    CN110985653B

  • Dual extraction pump hot standby switching method

    CN112228328B

  • Full-automatic tyre glue spraying production line production monitoring system

    CN106527387A