Matching Method and Device for Different Student Management Systems Based on Greedy Algorithm
By applying greedy algorithms in the student management system, the problem of low efficiency and accuracy in cross-system student information matching is solved, and automated matching and accurate results are achieved.
Patent Information
- Application Number
- CN202510287095.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-03-12
- Publication Date
- 2025-06-13
- Estimated Expiration
- 2045-03-12
AI Technical Summary
The prior art has low efficiency and accuracy in cross-system student information matching, especially due to increased matching difficulty due to data inconsistency and different naming rules.
Using a method based on greedy algorithm, by obtaining and preprocessing student data, using student name information to calculate the number of students matched in class, determining the class match pair, and adding it to the preset matching relationship set.
It realizes efficient and accurate automated student information matching, reduces the need for manual intervention, and ensures the accuracy and reliability of matching results.
Smart Images

Figure CN119809890B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of intelligent education technology, and particularly to a matching method and device for different student management systems based on a greedy algorithm. Background Art
[0002] With the development of educational management informatization, a large amount of student, school, and class information is recorded in different student management systems. However, due to different data entry sources, student transfers or class changes, etc., the same student's different class or school information may be recorded in System A and System B. For example, the class recorded in System A is C1, while the class recorded in System B is C101. This data inconsistency hinders the effective integration and management of student information.
[0003] In cross-system data matching, the student name is usually the only common data that can be provided between two systems, while other data (such as class ID, school ID, grade, etc.) often cannot be directly used for matching due to different naming rules, data formats, or data security requirements, which further increases the difficulty of student information matching.
[0004] In the prior art, although there are some methods attempting to perform cross-system student information matching, most of these methods rely on manual intervention or use fuzzy matching techniques, and do not provide an efficient and accurate automated matching method. Summary of the Invention
[0005] In view of this, the purpose of the present invention is to provide a matching method and device for different student management systems based on a greedy algorithm, aiming to solve the problem of low efficiency and accuracy in cross-system student information matching in the prior art.
[0006] On the one hand, the present invention proposes a matching method for different student management systems based on a greedy algorithm, and the method includes:
[0007] Obtain student data in different student management systems that need to be matched, and preprocess the student data, where the preprocessing includes unifying the data format and cleaning invalid data;
[0008] Respectively obtain the class set and the student set in one of the student management systems and the class set ;
[0009] Determine each class in the class set corresponding to the student set each class among them to determine their respective class matching pairs according to the number of matching students in each class, and add the class matching pairs to a preset matching relationship set.
[0010] Furthermore, in the above matching method for different student management systems implemented based on the greedy algorithm, wherein, the step of determining the class set according to the name information of each student using the greedy algorithm each class among them and the class set each class among them the steps of determining their respective class matching pairs according to the number of matching students in each class include:[[]]
[0011] Calculating the number of matching students between each class in the class set each class among them and the class set each class among them ;
[0012] Finding the target class in the class set corresponding to the class in the class set according to the preset conditions based on the number of matching students to form a class matching pair.
[0013] Furthermore, in the above matching method for different student management systems implemented based on the greedy algorithm, wherein, the calculation method of the number of matching students is:[[]]
[0014] ;
[0015] wherein represents the number of intersection elements of the student set and the student set , that is, the number of common students in the class determined according to the name information of the student and the class .
[0016] Furthermore, in the above matching method for different student management systems implemented based on the greedy algorithm, wherein, the expression of the preset condition is:[[]]
[0017] ;
[0018] wherein, the preset condition means finding the target class with the largest number of matching students with the class from all classes .
[0019] Further, for the above matching method for different student management systems implemented based on the greedy algorithm, after the step of adding the class matching pairs to the preset matching relationship set, the following steps are further included:
[0020] Mark the class matching pairs that have been added to the preset matching relationship set as the paired state and no longer participate in subsequent class matching.
[0021] Further, for the above matching method for different student management systems implemented based on the greedy algorithm, wherein, using the greedy algorithm to determine the class set according to the name information of each student each class in the class set each class in the steps of determining the matching number of students for each class in the class set to determine their respective class matching pairs and adding the class matching pairs to the preset matching relationship set include:
[0022] Select the class matching pair with the largest number of matching students from all classes and add it to the preset matching relationship set, and then continue to select the class matching pair with the largest number of matching students from the remaining classes and add it to the preset matching relationship set until the matching is completed.
[0023] Another object of the present invention is a matching device for different student management systems implemented based on the greedy algorithm, which is used to implement the above matching method for different student management systems implemented based on the greedy algorithm. The device includes:
[0024] A preprocessing module, which is used to obtain the student data in different student management systems that need to be matched and preprocess the student data. Among them, the preprocessing includes unifying the data format and cleaning invalid data;
[0025] An acquisition module, which is used to respectively obtain the class set and its student set in one of the student management systems and its student set ;
[0026] A matching module, which is used to use the greedy algorithm to determine the matching number of students for each class in the class set with each class in the class set to determine their respective class matching pairs and add the class matching pairs to the preset matching relationship set.
[0027] Another object of the present invention is to provide a readable storage medium having a computer program stored thereon, and when the program is executed by a processor, the steps of the above method are implemented.
[0028] Another object of the present invention is to provide an electronic device, including a memory, a processor, and a computer program stored on the memory and running on the processor. When the processor executes the program, the steps of the above method are implemented.
[0029] The present invention fully utilizes the student name information as the only common data between two different student management systems, and uses the greedy algorithm to determine the class set each class in with the class set each class in the number of matching students to determine their respective class matching pairs, and add the class matching pairs to a preset matching relationship set. Each time, select the class with the largest number of student matches among all possible classes for matching. This locally optimal selection can achieve the best matching result as much as possible at each step, and based on the unique matching of student names, ensure the accuracy of the result and avoid fuzzy matching errors. It solves the problems of low efficiency and accuracy in cross-system student information matching in the prior art.
[0030] In addition, the embodiments of the present invention at least further have the following beneficial effects:
[0031] 1. Even if there are students with the same name, the algorithm can still make the best choice according to the overall number of class matches, ensuring the accuracy and reliability of the final matching result;
[0032] 2. No manual intervention is required, and cross-system class matching is automatically completed, reducing labor costs;
[0033] 3. The algorithm structure is simple, easy to deploy and expand, and applicable to various system environments;
[0034] 4. The matching process is clear and transparent, and the matching basis is intuitively displayed through the number of matching students;
[0035] 5. Each time, select the class pair with the largest number of matching students, reduce unnecessary calculations, and have a fast execution speed. BRIEF DESCRIPTION OF THE DRAWINGS
[0036] Figure 1 is a flowchart of a method for implementing matching between different student management systems based on the greedy algorithm in the first embodiment of the present invention;
[0037] Figure 2 is a structural block diagram of a device for implementing matching between different student management systems based on the greedy algorithm in the third embodiment of the present invention.
[0038] The following specific embodiments will further illustrate the present invention in conjunction with the above-mentioned drawings. Specific Embodiment
[0039] For ease of understanding the present invention, the present invention will be described more comprehensively below with reference to the relevant drawings. Several embodiments of the present invention are given in the drawings. However, the present invention can be implemented in many different forms and is not limited to the embodiments described herein. On the contrary, these embodiments are provided so that the disclosure of the present invention is more thorough and comprehensive.
[0040] It should be noted that when an element is referred to as being "fixedly provided on" another element, it can be directly on the other element or there can also be an intermediate element. When an element is considered to be "connected" to another element, it can be directly connected to the other element or there may be an intermediate element at the same time. The terms "vertical", "horizontal", "left", "right" and similar expressions used herein are for illustrative purposes only.
[0041] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by those of ordinary skill in the technical field to which this invention belongs. The terms used herein in the specification of the present invention are only for the purpose of describing specific embodiments and are not intended to limit the present invention. The term "and / or" used herein includes any and all combinations of one or more of the related listed items.
[0042] Embodiment 1
[0043] Please refer to Figure 1 , which shows a matching method for different student management systems based on the greedy algorithm in the first embodiment of the present invention. The method includes steps S10 to S12.
[0044] Step S10: Obtain the student data in different student management systems that need to be matched, and preprocess the student data. Among them, the preprocessing includes unifying the data format and cleaning invalid data.
[0045] Specifically, before matching, the student data in two different student management systems is uniformly preprocessed, including but not limited to unifying the data format, cleaning invalid data, etc., to ensure the accuracy of subsequent matching.
[0046] Step S11: Obtain the class set and its student set in one of the student management systems, and the class set and its student set
[0047] Among them, in the embodiments of the present invention, the entire matching problem is decomposed into the student matching problem between classes, which simplifies the complexity. And the matching of each class is achieved by comparing the student information within the class. Therefore, it is necessary to obtain the corresponding student sets for the class sets. Specifically, the class set A is the set of all classes in one of the student management systems, which can be expressed as ; where is the A th class in the class set i . Similarly, the class set B is the set of all classes in another student management system, which can be expressed as ; where is the th class in system B.
[0048] Step S12, use the greedy algorithm to determine the matching number of students between each class in the class set and each class in the class set according to the name information of each student, so as to determine their respective class matching pairs, and add the class matching pairs to the preset matching relationship set.
[0049] Among them, the greedy algorithm is an algorithm that makes the best or optimal (i.e., the most favorable) choice at each step of the selection, hoping to lead to a globally best or optimal result. In the embodiments of the present invention, the class with the largest number of student matches is selected for matching among all possible class pairs each time. The greedy algorithm selects a locally optimal solution at each step and gradually constructs a globally optimal solution.
[0050] For each class in the class set , the system will compare it with each class in the class set . The system will compare according to the student names between each pair of classes and count the number of identical students in each pair of classes. Select the class with the largest number of matching students for correspondence. And form two classes into a class matching pair, and store the class matching pair into the preset matching relationship set.
[0051] In addition, in some optional embodiments of the present invention, in order to ensure the optimal global class matching effect, when performing matching, the class matching pair with the largest number of matching students will be first selected from all classes and added to the preset matching relationship set, and then continue to select the class matching pair with the largest number of matching students from the remaining classes and add it to the preset matching relationship set until the matching is completed.
[0052] In summary, the matching method for different student management systems based on the greedy algorithm in the above embodiments of the present invention fully utilizes the student name information as the only common data between two different student management systems, uses the greedy algorithm to determine the number of matching students for each class in the class set with each class in the class set to determine their respective class matching pairs, and adds the class matching pairs to the preset matching relationship set. Each time, the class with the largest number of student matches is selected from all possible classes for matching. This locally optimal selection can achieve the best matching result at each step as much as possible, and based on the unique matching of student names, ensures the accuracy of the result and avoids fuzzy matching errors. It solves the problems of low efficiency and accuracy in cross-system student information matching in the prior art.
[0053] Embodiment 2
[0054] This embodiment also proposes a matching method for different student management systems based on the greedy algorithm. The difference between the matching method for different student management systems based on the greedy algorithm in this embodiment and the matching method for different student management systems based on the greedy algorithm in Embodiment 1 is as follows:
[0055] The step of using the greedy algorithm to determine the number of matching students for each class in the class set according to the name information of each student in the class set with each class in the class set in the class set to determine their respective class matching pairs includes:
[0056] Calculate the number of matching students for each class in the class set in the class set with each class in the class set in the class set according to the name information of each student;
[0057] Use preset conditions to find the target class in the class set corresponding to the class in the class set in the class set to form a class matching pair according to the number of matching students.
[0058] Among them, during the matching process, first, the number of matching students for each class in the class set will be calculated according to the name information of each student in the class set with each class in the class set in the class set . Specifically, the number of matching students can be expressed as;
[0059] ;
[0060] in, Represents a collection of students Gather with students The number of intersection elements, that is, the class determined based on the student's name information With class The number of common students.
[0061] After obtaining the number of directly matching students for each pair of classes, you can filter and determine the final class matching pairs according to the conditions. Specifically, use the preset conditions to find the class set according to the number of matching students. The class Corresponding class set The target class Form a class matching pair. The expression of the preset condition is:
[0062] ;
[0063] The precondition is expressed as Find the class Match the target class with the largest number of students , that is, select the class set Each class The largest number of matching students Class matching pairs are formed and then added to the preset matching relationship set. The number of matching students can also be accumulated to indicate the final overall matching effect.
[0064] In addition, in order to improve the matching effect, during the actual matching, the class matching pairs that have been added to the preset matching relationship set are marked as paired and will no longer participate in subsequent class matching.
[0065] In order to describe the specific implementation process of the embodiment of the present invention in more detail, for example, there are currently two student management systems: System 1 and System 2, which have multiple classes. Each class contains a number of students, and the names of the students are the same in the two systems, but the classes and schools may be different. The goal is to match the classes in System 1 and System 2 to ensure that students with the same names can be correctly mapped to the corresponding classes.
[0066] Assume that the class and student information in System 1 and System 2 are as follows:
[0067] System 1 includes Class A 1 , A 2 , A 3 ; Class A 1 Including students: Zhang San, Li Si, Wang Wu, Zhao Liu; Class A 2Including students: Sun Qi, Li Si, Liu Jiu, Zhou Shi; Class A 3 Including students: Qian Ba, Wang Wu, Li Si, Wu Shi Yi.
[0068] System Two includes Class B 1 、B 2 、B 3 ; Class B 1 Including students: Zhang San, Li Si, Wang Wu, Sun Qi; Class B 2 Including students: Li Si, Zhao Liu, Liu Jiu, Qian Ba; Class B 3 Including students: Wang Wu, Li Si, Zhou Shi, Wu Shi Yi
[0069] Calculate the number of student matches for each pair of classes, as shown in Table 1 below:
[0070] Table 1
[0071]
[0072] Start the step-by-step greedy selection (each time select the class match pair with the most matches):
[0073] First step: From the matching results of all classes, select the class match pair with the most matching people. For example, A 1 →B 1 (3 people are matched: Zhang San, Li Si, Wang Wu);
[0074] Matched: A 1 and B 1 ;
[0075] Excluded: A 1 and B 1 Will no longer participate in subsequent matches.
[0076] Second step: Continue to select the class match pair with the most matching people from the remaining class pairs. For example, A 3 → B 3 (3 people are matched: Wang Wu, Li Si, Wu Shi Yi);
[0077] Matched: A 3 and B 3 ;
[0078] Excluded: A 3 and B 3 Will no longer participate in subsequent matches.
[0079] Third step: Select the class match pair with the most matching people from the remaining class pairs. For example, A 2 → B 2 (2 people are matched: Li Si, Liu Jiu);
[0080] Matched: A 2With B 2 ;
[0081] Exclude: A 2 and B 2 will no longer participate in subsequent matching.
[0082] The final matching results are shown in Table 2 below:
[0083] Table 2
[0084]
[0085] It should be noted that in this example, the student "Li Si" appears in multiple classes, which is a case of duplicate names. When the greedy algorithm is processed, each time it selects according to the "number of matching students" of the current class pair. Although "Li Si" appears repeatedly, the greedy algorithm only focuses on the number of matches of the current class pair, and finally ensures the optimal global class matching effect.
[0086] In summary, the matching method for different student management systems based on the greedy algorithm in the above embodiments of the present invention fully utilizes the student name information as the only common data between two different student management systems, uses the greedy algorithm to determine the number of matching students for each class in the class set with each class in the class set to determine their respective class matching pairs, and adds the class matching pairs to the preset matching relationship set. Each time, the class with the largest number of student matches is selected from all possible classes for matching. This locally optimal selection can achieve the best matching result as much as possible at each step, and based on the unique matching of student names, ensures the accuracy of the result and avoids fuzzy matching errors. It solves the problems of low efficiency and accuracy in cross-system student information matching in the prior art.
[0087] Embodiment III
[0088] Please refer to Figure 2 , which shows the matching device for different student management systems based on the greedy algorithm proposed in the third embodiment of the present invention. The device includes:
[0089] A preprocessing module 100, configured to obtain student data in different student management systems that need to be matched, and preprocess the student data, where the preprocessing includes unifying the data format and cleaning invalid data;
[0090] An obtaining module 200, configured to respectively obtain the class set and its student set in one of the student management systems and the class set and its student set
[0091] Matching module 300, used to determine the class set using a greedy algorithm based on the name information of each student Each class Gather with class Each class The number of matching students is determined to determine the respective class matching pairs, and the class matching pairs are added to the preset matching relationship set.
[0092] Furthermore, the above-mentioned matching device for implementing different student management systems based on the greedy algorithm, wherein the class set is determined by using the greedy algorithm according to the name information of each student. Each class Gather with class Each class The steps of determining the number of matching students for each class to determine the matching pairs include:
[0093] Calculate the class set based on each student's name information Each class Gather with class Each class The number of matching students;
[0094] According to the number of matching students, use the preset conditions to find the class set The class Corresponding class set The target class Form class matching pairs.
[0095] Furthermore, in the above-mentioned matching device for implementing different student management systems based on the greedy algorithm, the number of matching students is calculated as follows:
[0096] ;
[0097] in, Represents a collection of students Gather with students The number of intersection elements, that is, the class determined based on the student's name information With class The number of common students.
[0098] Furthermore, in the above-mentioned matching device for implementing different student management systems based on the greedy algorithm, the expression of the preset condition is:
[0099] ;
[0100] The preset condition is expressed as Find the class Match the target class with the largest number of students 。
[0101] Furthermore, in the above matching device for different student management systems implemented based on the greedy algorithm, after the step of adding the class matching pair to the preset matching relationship set, the following steps are further included:
[0102] Mark the class matching pairs that have been added to the preset matching relationship set as the paired state and no longer participate in subsequent class matching.
[0103] Furthermore, in the above matching device for different student management systems implemented based on the greedy algorithm, where each class in the class set is determined by using the greedy algorithm according to the name information of each student in the class set with each class in the class set in the class set to determine the matching number of students for each class to determine their respective class matching pairs, and the steps of adding the class matching pairs to the preset matching relationship set include:
[0104] Select the class matching pair with the largest number of matching students from all classes and add it to the preset matching relationship set, and then continue to select the class matching pair with the largest number of matching students from the remaining classes and add it to the preset matching relationship set until the matching is completed.
[0105] The functions or operation steps implemented when the above modules are executed are substantially the same as those in the above method embodiments, and will not be repeated here.
[0106] Example 4
[0107] On the other hand, the present invention also provides a readable storage medium, on which a computer program is stored, and when the program is executed by a processor, the steps of the method described in any one of the above embodiments 1 to 2 are implemented.
[0108] Example 5
[0109] On the other hand, the present invention also provides an electronic device, the electronic device includes a memory, a processor, and a computer program stored on the memory and running on the processor, and when the processor executes the program, the steps of the method described in any one of the above embodiments 1 to 2 are implemented.
[0110] The technical features of each of the above embodiments can be combined arbitrarily. For the sake of brevity of description, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, it should be considered as the scope recorded in this specification.
[0111] Those skilled in the art will understand that the logic and / or steps represented in the flowchart or otherwise described herein, for example, can be considered as a definite sequence list of executable instructions for implementing logical functions, and can be specifically implemented in any computer-readable storage medium for use by an instruction execution system, apparatus, or device (such as a computer-based system, a system including a processor, or other systems that can fetch and execute instructions from the instruction execution system, apparatus, or device), or used in combination with these instruction execution systems, apparatuses, or devices. For the purposes of this specification, a "computer-readable storage medium" can be any device that can contain, store, communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device.
[0112] More specific examples (non-exhaustive list) of computer-readable storage media include the following: an electrical connection part with one or more wirings (electronic device), a portable computer disk cartridge (magnetic device), a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber device, and a portable compact disc read-only memory (CDROM). Additionally, a computer-readable storage medium can even be paper or other suitable media on which the program can be printed, because the program can be obtained electronically, for example, by optically scanning the paper or other media, followed by editing, interpretation, or other appropriate processing when necessary, and then stored in a computer memory.
[0113] It should be understood that various parts of the present invention can be implemented by hardware, software, firmware, or a combination thereof. In the above embodiments, multiple steps or methods can be implemented by software or firmware stored in a memory and executed by a suitable instruction execution system. For example, if implemented by hardware, as in another embodiment, any one or a combination of the following techniques well known in the art can be used: discrete logic circuits having logic gate circuits for implementing logical functions on data signals, application-specific integrated circuits having appropriate combinational logic gate circuits, programmable gate arrays (PGAs), field programmable gate arrays (FPGAs), etc.
[0114] In the description of this specification, the descriptions referring to terms such as "one embodiment", "some embodiments", "example", "specific example", or "some examples", etc. mean that the specific features, structures, materials, or characteristics described in connection with the embodiment or example are included in at least one embodiment or example of the present invention. In this specification, the schematic representations of the above terms do not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials, or characteristics described can be combined in a suitable manner in any one or more embodiments or examples.
[0115] The above-described embodiments merely represent several implementation manners of the present invention. The description thereof is relatively specific and detailed, but it should not be construed as a limitation on the scope of the patent for the present invention. It should be noted that for those of ordinary skill in the art, without departing from the concept of the present invention, several modifications and improvements can still be made, and these all fall within the protection scope of the present invention. Therefore, the protection scope of the patent for the present invention shall be subject to the appended claims.
Claims
1. A matching method for different student management systems based on a greedy algorithm, characterized in that: The method comprises: Obtaining student data from different student management systems that need to be matched, and preprocessing the student data, wherein the preprocessing includes unifying the data format and cleaning invalid data; Get the class collection in one of the student management systems respectively and its student collection And another class collection in the student management system and its student collection ; Determine the class set using a greedy algorithm based on each student's name information Each class Gather with class Each class The number of matching students is used to determine the respective class matching pairs, and the class matching pairs are added to the preset matching relationship set; The class set is determined by using a greedy algorithm based on the name information of each student. Each class Gather with class Each class The steps of determining the number of matching students for each class to determine the matching pairs include: Calculate the class set based on each student's name information Each class Gather with class Each class The number of matching students; According to the number of matching students, use the preset conditions to find the class set The class Corresponding class set The target class Form class matching pairs; The calculation method of the number of matching students is: ; in, Represents a collection of students Gather with students The number of intersection elements, that is, the class determined based on the student's name information With class The number of common students.
2. According to claim 1, the matching method for implementing different student management systems based on a greedy algorithm is characterized in that: The expression of the preset condition is: ; The preset condition is expressed as Find the class Match the target class with the largest number of students .
3. The matching method for implementing different student management systems based on a greedy algorithm according to claim 1 is characterized in that: After the step of adding the class matching pair to the preset matching relationship set, the method further includes: The class matching pairs that have been added to the preset matching relationship set are marked as paired and will no longer participate in subsequent class matching.
4. The matching method for implementing different student management systems based on a greedy algorithm according to claim 1 is characterized in that: The class set is determined by using a greedy algorithm based on the name information of each student. Each class Gather with class Each class The steps of determining the respective class matching pairs based on the number of matching students and adding the class matching pairs to the preset matching relationship set include: Select the class matching pair with the largest number of matching students from all classes and add them to the preset matching relationship set, and then continue to select the class matching pair with the largest number of matching students from the remaining classes and add them to the preset matching relationship set until the matching is completed.
5. A matching device for implementing different student management systems based on a greedy algorithm, characterized in that: The device is used to implement the matching method of different student management systems based on the greedy algorithm as described in any one of claims 1 to 4, and the device comprises: A preprocessing module, used to obtain student data from different student management systems that need to be matched, and preprocess the student data, wherein the preprocessing includes unifying the data format and cleaning invalid data; The acquisition module is used to obtain the class collection in one of the student management systems. and its student collection And another class collection in the student management system and its student collection ; The matching module is used to determine the class set based on the name information of each student using a greedy algorithm Each class Gather with class Each class The number of matching students is determined to determine the respective class matching pairs, and the class matching pairs are added to the preset matching relationship set.
6. A readable storage medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, the steps of the method according to any one of claims 1 to 4 are implemented.
7. An electronic device, characterized in that: The method comprises a memory, a processor and a computer program stored in the memory and running on the processor, wherein the steps of the method according to any one of claims 1 to 4 are implemented when the processor executes the program.
Citation Information
Patent Citations
Method and device for generating information
CN110264005A
System and method based on user side multi-source data connection and service fusion
CN117971947A