# Personalized Recommendation Algorithm for University Civics Courses with Multiple User Interests

Authors: Hanyin Liang; Wanwan Li
Journal: Mathematical Problems in Engineering
 (2022)

---

## Abstract

In response to the problems of unity, lack of relevance, lack of synergy, and inability to form a personalized collaborative education mechanism in the current curriculum setting of university thinking and politics education, a personalized recommendation system for university thinking and politics courses based on the multiple interests of users was developed. The system of interests is divided into two parts: first is initial interest guidance, in which theN meta-model is used to learn the context of known course processes; second is user interest extraction; at the end of creating the recommendation process, facing the diversity of user interests, probabilistic latent semantic analysis trains the interest-service-flow distribution of students to recommend the civics course that matches the current interest for students. A good recommendation algorithm can simulate learners’ enthusiasm and give full play to different learners’ learning personalities. The simulation experiments show that the system is stable in operation, complete in function, and has strong practicality and robustness, which is of positive significance in creating a win-win, diverse, and innovative atmosphere for students’ and teachers’ thinking education in colleges and universities.


---

## Body

## 1. Introduction

Nowadays, the development of the Internet and new media has entered the era of algorithmic recommendations [1]. Surveys show that “by the end of 2021, more than 98% of the social distribution of online information is done by algorithmic recommendations” [2]. (1) As with all transformative technologies, algorithms are influencing and even transforming every aspect of social life with unprecedented power. “Increasingly, social behavior exists within algorithms, which not only shape society and culture, but directly impact individual lives” [3]. (2) Under the leadership of algorithms, university education and teaching, and the corresponding aspects of classroom teaching, individual life and ideological construction, have been reconstructed to varying degrees, and the majority of students and teachers, as audiences, have experienced a shift in their roles and an exploration of the boundaries of their rights in the process [4]. In short, recommendation algorithms bring new development opportunities [5] for the development of university curricula and even the governance of university life [6].As the main channel and forum for ideological and political work in Chinese colleges and universities, the Civic education course is an important way to practice the education mechanism of colleges and universities, and an important part of the theory course system of colleges and universities [7]. It plays a fundamental role in strengthening the valuable guidance of students in colleges and universities, enhancing the propagation and education of the main melody of patriotic dedication, and establishing an all-around nurturing mechanism for all staff and all processes.At present, most of the university’s thought and political education is conducted collectively in the form of large classes and public lectures, which has the problems of single form, poor relevance, lack of synergy effect, and inability to form a personalized and collaborative education mechanism. The system follows the general design concept of software engineering and optimizes the traditional personalized course recommendation algorithm and introduces the gradual forgetting curve based on the change of the user’s interest over time, which better solves the problems of low efficiency, weak adaptation, and new ranking of the traditional collaborative filtering algorithm. The system has been developed and applied to provide a better solution to the disadvantages of the traditional collaborative filtering algorithm, such as low efficiency, weak adaptability, and newness. The development and application of the above system provides a new approach to the development of higher education work, which is conducive to improving the overall quality of students in the thinking class and is of positive significance in creating a collaborative, diverse, and innovative atmosphere in higher education for teachers and students.The paper is arranged in the following way: Section2 explains the work related to the research. Section 3 describes the algorithm used in the paper. Section 4 consists of the design of a recommendation system for higher education courses. Section 5 has the experimental results and analysis. Section 6 concludes the research topic.


## 2. Related Work

In this section, give an explanation of all the past work that was used in the paper to make it more powerful. The first subsection consists of the development and attributes of the algorithmic recommender system. Different types of recommendations are also included in this subsection defined by different authors. The second subsection gives a review of the impact of algorithms on the civics courses in colleges and universities.


### 2.1. Development and Characteristics of Algorithmic Recommender Systems

With the development of the Internet, the global data volume is exploding, and the problem of information overload is becoming more and more prominent. The problem of how to find the required information quickly and accurately from the huge amount of information has become a problem for people [8]. Search engines can satisfy users’ information needs through active search, but they cannot understand users’ potential needs and cannot provide them with personalized information [9]. Unlike search engines, algorithmic recommendation systems can analyze a user’s preferences based on their historical behavioral data and recommend content that may be of interest to them, which has greatly improved the efficiency and accuracy of information distribution and disrupted the way people relate to information [10].The Grundy recommendation system was first introduced by scientist Elaine Rich in 1979 and applied to book recommendations [11]. In 1992, Goldberg et al. introduced the concept of collaborative filtering and applied it to the Tapestry e-mail filtering system, which is now recognized as the first true recommendation system [12]. In 1994, researchers at the University of Minnesota introduced group lens, the first collaborative filtering-based automated recommendation system with a high degree of automation [13]. In 1997, Ren snick and other researchers formally introduced the concept of “recommender systems” [14]. In 1998, the item-based collaborative filtering algorithm (Item CF algorithm) went live on the Amazon platform, which increased Amazon sales by around 35% [15]. This was a successful application of recommendation algorithms from the laboratory to the commercial sector. Since then, foreign social media platforms such as the YouTube video platform, Facebook, and Twitter have also adopted algorithmic recommendation technology, and these social media platforms have seen significant increases in user hours and ad click-through rates. The domestic Internet industry has also embraced algorithms. In the past decade, algorithmic recommendation systems have been widely used in news and information, social media, e-commerce, video websites, music, movies, and other fields, creating huge commercial value while also promoting the rapid development of algorithmic recommendation technology.Recommendation algorithms are the core technology in recommendation systems and have a crucial impact on the effectiveness of recommendations [16]. At present, there are many types of recommendation algorithms, and different classification results can be obtained according to different classification criteria. The mainstream generally classifies recommendation algorithms into three categories: content-based recommendation algorithms [17], collaborative filtering-based recommendation algorithms [18], and hybrid recommendation algorithms [19]. Content-based recommendation algorithms analyze the user’s past preferences and generate recommendations for items that are similar to them. Collaborative filtering-based recommendation algorithms use data to analyze the similarity of users and thus push similarly preferred information to similar users. An illustration of the logic of the item-based collaborative filtering algorithm is shown in Figure 1. Hybrid recommendation algorithms combine content-based recommendation algorithms with collaborative filtering and may also introduce technical approaches from other domains to generate recommended content. The mathematical theories and techniques used to construct these algorithms vary widely, but whatever the algorithmic system, it can be deconstructed into three basic components: the underlying data used to train the algorithm, the logic of the algorithm itself, and the way in which the user interacts with the algorithm. The algorithm learns from, or operates on, the data, making suggestions or decisions on behalf of the user. The user then interacts with the suggestions made by the algorithm, from which the next generation of data is generated for the algorithm. Together, the three components i.e., the algorithm, data, and user are used to determine all the intended and unintended outcomes of the algorithmic system. Over the past decade or so, the underlying data used to train algorithms, the algorithms themselves, and the way users interact with them have all changed dramatically. These changes both drive the era of algorithmic recommendation and reveal the fundamental characteristics of the algorithmic recommendation era.Figure 1
Logical schematic of the item-based collaborative filtering algorithm.


### 2.2. Impact of Recommendation Algorithms on the Civics Course in Colleges and Universities

As a compulsory public course for all university students in China, the university’s civics course undertakes the task of spreading Marxist theory, strengthening value leadership and maintaining national ideological security. Therefore, it is important to carefully analyze the impact of algorithms on college civics courses, actively bring into play the institutional advantages of ideological and political education and raise the awareness of the majority of teachers and students about algorithms, in order to keep the righteousness and innovation of college civics courses. In recent years, algorithms have been increasingly used in university education and teaching, providing unprecedented opportunities for large-scale understanding of learner behavior and intrinsic characteristics. By introducing algorithms and data into information finding, the recommendation system provides a new approach and new energy to the teaching of college civics courses, allowing some work that relies on large amounts of data processing to be further developed and driving changes in the college education ecology.


## 2.1. Development and Characteristics of Algorithmic Recommender Systems

With the development of the Internet, the global data volume is exploding, and the problem of information overload is becoming more and more prominent. The problem of how to find the required information quickly and accurately from the huge amount of information has become a problem for people [8]. Search engines can satisfy users’ information needs through active search, but they cannot understand users’ potential needs and cannot provide them with personalized information [9]. Unlike search engines, algorithmic recommendation systems can analyze a user’s preferences based on their historical behavioral data and recommend content that may be of interest to them, which has greatly improved the efficiency and accuracy of information distribution and disrupted the way people relate to information [10].The Grundy recommendation system was first introduced by scientist Elaine Rich in 1979 and applied to book recommendations [11]. In 1992, Goldberg et al. introduced the concept of collaborative filtering and applied it to the Tapestry e-mail filtering system, which is now recognized as the first true recommendation system [12]. In 1994, researchers at the University of Minnesota introduced group lens, the first collaborative filtering-based automated recommendation system with a high degree of automation [13]. In 1997, Ren snick and other researchers formally introduced the concept of “recommender systems” [14]. In 1998, the item-based collaborative filtering algorithm (Item CF algorithm) went live on the Amazon platform, which increased Amazon sales by around 35% [15]. This was a successful application of recommendation algorithms from the laboratory to the commercial sector. Since then, foreign social media platforms such as the YouTube video platform, Facebook, and Twitter have also adopted algorithmic recommendation technology, and these social media platforms have seen significant increases in user hours and ad click-through rates. The domestic Internet industry has also embraced algorithms. In the past decade, algorithmic recommendation systems have been widely used in news and information, social media, e-commerce, video websites, music, movies, and other fields, creating huge commercial value while also promoting the rapid development of algorithmic recommendation technology.Recommendation algorithms are the core technology in recommendation systems and have a crucial impact on the effectiveness of recommendations [16]. At present, there are many types of recommendation algorithms, and different classification results can be obtained according to different classification criteria. The mainstream generally classifies recommendation algorithms into three categories: content-based recommendation algorithms [17], collaborative filtering-based recommendation algorithms [18], and hybrid recommendation algorithms [19]. Content-based recommendation algorithms analyze the user’s past preferences and generate recommendations for items that are similar to them. Collaborative filtering-based recommendation algorithms use data to analyze the similarity of users and thus push similarly preferred information to similar users. An illustration of the logic of the item-based collaborative filtering algorithm is shown in Figure 1. Hybrid recommendation algorithms combine content-based recommendation algorithms with collaborative filtering and may also introduce technical approaches from other domains to generate recommended content. The mathematical theories and techniques used to construct these algorithms vary widely, but whatever the algorithmic system, it can be deconstructed into three basic components: the underlying data used to train the algorithm, the logic of the algorithm itself, and the way in which the user interacts with the algorithm. The algorithm learns from, or operates on, the data, making suggestions or decisions on behalf of the user. The user then interacts with the suggestions made by the algorithm, from which the next generation of data is generated for the algorithm. Together, the three components i.e., the algorithm, data, and user are used to determine all the intended and unintended outcomes of the algorithmic system. Over the past decade or so, the underlying data used to train algorithms, the algorithms themselves, and the way users interact with them have all changed dramatically. These changes both drive the era of algorithmic recommendation and reveal the fundamental characteristics of the algorithmic recommendation era.Figure 1
Logical schematic of the item-based collaborative filtering algorithm.


## 2.2. Impact of Recommendation Algorithms on the Civics Course in Colleges and Universities

As a compulsory public course for all university students in China, the university’s civics course undertakes the task of spreading Marxist theory, strengthening value leadership and maintaining national ideological security. Therefore, it is important to carefully analyze the impact of algorithms on college civics courses, actively bring into play the institutional advantages of ideological and political education and raise the awareness of the majority of teachers and students about algorithms, in order to keep the righteousness and innovation of college civics courses. In recent years, algorithms have been increasingly used in university education and teaching, providing unprecedented opportunities for large-scale understanding of learner behavior and intrinsic characteristics. By introducing algorithms and data into information finding, the recommendation system provides a new approach and new energy to the teaching of college civics courses, allowing some work that relies on large amounts of data processing to be further developed and driving changes in the college education ecology.


## 3. Algorithm Description

The personalized recommendation algorithm based on the multiple interests of users in higher education can be divided into 3 parts: (1)Data processing. The crawled service access information is transformed into a user interest matrix for subsequent processing. (2) Initial interest guidance. The first i−1 selected interest components are known, and the probability of the i-th different interest component is calculated according to the N-gram model. The recommended interest is selected according to the probability, and the course topic is created according to the recommended interest. (3) Studen-interest extraction. After the student has completed interest creation, the user’s interest-course topic distribution is trained through probabilistic latent semantic analysis to recommend other course topics for the student that match the current interest.


### 3.1. Data Processing

The crawled service access information is converted into a student-interest matrix of the formuser1:sc1,sc2,…,scn according to the order of access time, where sc1,sc2,…,scn is the course subject interest selected by student user 1, and the interest elements sc1,sc2,…,scn are sorted in the order of student user 1’s access time, with a direct linkage between the front and back interests. The student-interest matrix is then cleaned of inactive user data, and the active student data is put into the text as the experimental dataset.


### 3.2. Initial Interest Guidance

The N-gram model is a probability-based discriminant model that assumes that the occurrence of thei-th word is only related to the i−1 preceding words and not to any other word. Based on this assumption, it can be assumed that the probability of occurrence of the i-th interest in an interest is only related to the preceding i−1 interests that have been selected and not to any other interests. Therefore, when a student clicks on an interest component, the subsequent predicted interests are calculated by the N element model and the course topic is recommended to the student, i.e., the different candidate course topics are brought into the probability formula psci|sc1…sci−1, is used further to measure the chances of occurrence of an event and recommend interests greater than a threshold T to students as candidates. Here, sci denotes the i-th interest element, sc1,…,sci−1 denotes the sequence of interests from sc1 to sci−1, and psci|sc1…sci−1 denotes when the sequence of interests sc1,…,sci−1 occurs, the probability that the sequence can be linked to sci.To solve the problem in practice, the parameter space ofpsci|sc1…sci−1 is too large and the calculation is very time-consuming. To solve the problem, the Markov assumption is introduced: the emergence of service is only related to a number of services that precede it. Thus equation (1) can be introduced from psci|sc1…sci−1 to hold(1)psci|sc1…sci−1≈psci|sci−N+1…sci−1.Then using the maximum likelihood estimation to solve forpsci,sci−N+1⋯sci−1, equation (2) holds(2)psci|sci−N+1…sci−1=Csci−N+1…sci−1sciCsci−N+1…sci−1,where Csci−N+1…sci−1sci represents the number of occurrences of the sequence of interest sci−N+1…sci−1 in a known dataset.


### 3.3. User Interest Extraction

Probabilistic latent semantic analysis (PLSA) is a generative modeling method for flexible clustering. In this paper, the main purpose of PLSA is to calculate the probability distribution of interest-course topics to achieve clustering so that when students create a learning course based on the recommended topics, the topics that are similar to them are selected based on the probability that they belong to different interests. The probabilistic graphical model of PLSA is shown in Figure2.Figure 2
PLSA’s probabilistic graphical model.In the figureU denotes a student, Z denotes an interest category, SP denotes an observed course topic, pui denotes the probability that student ui appears in the dataset, pzk|ui denotes the probability that student ui belongs to interest category zk, where the student’s interest is not unique, and pspj|zk denotes the probability that course topic spj belongs to this interest category zk when interest zk is determined. As a generative model, to calculate pspj|zk, the joint distribution of pspj|zk needs to be obtained, and since zk is a hidden variable, this joint distribution cannot be found directly. Therefore, the joint distribution of ui,spj can be calculated first based on the observed data pair ui,spj, as shown in equation (3).(3)pui,spj=puipspj|ui=pui∑kKpzk|uipspj|zkThe parameters of the PLSA model are according to the maximum likelihood estimationpspj|zk with the likelihood function L shown in equation (4).(4)L=∏i=1N∏j=1Mpui,spjnui,spj=∏i−1N∏j=1Mpui∑k=1Kpzk|uipspj|zknui,spj,where nui,spj denotes the number of times the student ui selected the interest combination spj. To prevent data overflow due to concatenation, the likelihood function is logarithmically processed to obtain the following equation:(5)logL=∑i=1N∑j=1Mnui,spjlogpui∑k=1Kpzk|uipspj|zk=∑i=1N∑j=1Mnui,spjlogpui+∑i=1N∑j=1Mnui,spjlog∑k=1Kpzk|uipspj|zk.where the first half of ∑i=1N∑j=1Mnui,spjlogpui is a constant. Therefore, only the second half is considered in the calculation, and the second half is named Lh, if the partial derivatives are found directly for the independent variables in Lh , the solution of the equation is difficult due to the fact that the independent variables are included in the logarithmic sum, the solution of the equation is difficult. Here, the Jensen inequality is used to transform Lh. Let Qzk=pzk|ui,spj, which leads to ∑k=1KQzk=1, and Qzk>0, have equation (6) holds(6)Lh=∑i=1N∑j=1Mnui,spjlog∑k=1Kpzk|uipspj|zk=∑i=1N∑j=1Mnui,spjlog∑k=1KQzkpzk|uipspj|zkQzk≥∑i=1N∑j=1Mnui,spj∑k=1KQzklogpzk|uipspj|zkQzk.According to equation (6), instead of calculating the value of the maximum likelihood function itself, the expectation-maximum (EM) algorithm can be used. Instead of calculating the value of the function itself, the expectation-maximum algorithm can be used to maximize the lower bound of the function. The EM algorithm is divided into two steps, E and M. The lower bound of the likelihood function is approximated by cycling through the two steps E and M. When the EM algorithm converges, the parameter values are close to those of the real dataset. The EM algorithm is as follows:(1)
StepE focuses on calculating Qzk, the posterior probability of the hidden variable pzk|ui,spj, which can be done by first randomly initializing the parameters pzk|ui and values of pspj|zk, and then solving the posterior probability of the hidden variable based on the results of the initialization in posterior probability under the current parameter conditions. Their equation (7) holds(7)pzk|ui,spj=pzk,ui,spjpui,spj=puipzk|uipspj|zkpuipspj|ui=pzk|uipspj|zkpspj|ui=pzk|uipspj|zk∑k=1Kpzk|uipspj|zk.(2)
The task of theM-step is expectation maximization, which focuses on polarizing the log-likelihood function containing the parameters based on the posterior probabilities of the hidden variables obtained in the E-step to obtain new parameter values for pzk|ui and pspj|zk, which are then brought into the E-step for looping. To simplify the equation, pzk|ui and pspj|zk are abbreviated as Z. M Steps are shown in equations (3) to (8).(8)Z≔fz=argmax∑i=1N∑j=1Mnui,spj∑k=1KPzk|ui,spjlogpzk|uipspj|zk,s.t.∑k=1Kpzk|ui=1,∑j=1Mpspj|zk=1.Equation (8) is a multivariate polarization problem with constraints. Using the Lagrange multiplier method, a constrained polarization problem can be transformed into a pairwise unconstrained polarization problem by creating a Lagrange function Lg, as shown in the following equation:(9)Lg=fz+∑i=1Nρi1−∑k=1Kpzk|ui+∑k=1Kτk1−∑j=1Mpspj|zk.This is a function ofpzk|ui and pspj|zk. For parameter pzk|ui by taking the partial derivative and making the partial derivative zero, we can obtain the equation as follows: (10)∂Lg∂pzk|ui=0⇒∑i=1N∑j=1Mnui,spj,∑k=1Kpzk|ui,spj=∑i=1N∑k=1Kρipzk|ui.Since∑k=1Kpzk|ui=1, one can deduce that ρi=∑k=1K∑j=1Mnui,spjpzk|ui,spj. Substituting ρi back into equation (10) gives a new value for pzk|ui, as in the following equation:(11)∑i=1N∑j=1Mnui,spj∑k=1Kpzk|ui,spj=∑i=1N∑k=1Kρipzk|ui⇒∑k=1Kpzk|ui=∑k=1K∑j=1Mnui,spjpzk|ui,spjρi⇒pzk|ui=∑j=1Mnui,spjpzk|ui,spj∑k=1K∑j=1Mnui,spjpzk|ui,spj.Similarly,Lg taking the partial derivative of pspj|zk and making the partial derivative zero gives the following equation:(12)pspj|zk=∑i=1Nnui,spjpzk|ui,spj∑i=1N∑j=1Mnui,spjpzk|ui,spj.After obtaining the newpspj|zk and pzk|ui values, the parameters are then brought into the E step to further derive the new pzk|ui,spj, followed by the M step to obtain the updated pspj|zk and pzk|ui values again until the change in the maximum likelihood value reaches a threshold, which indicates that the final parameter values obtained can describe the dataset.


## 3.1. Data Processing

The crawled service access information is converted into a student-interest matrix of the formuser1:sc1,sc2,…,scn according to the order of access time, where sc1,sc2,…,scn is the course subject interest selected by student user 1, and the interest elements sc1,sc2,…,scn are sorted in the order of student user 1’s access time, with a direct linkage between the front and back interests. The student-interest matrix is then cleaned of inactive user data, and the active student data is put into the text as the experimental dataset.


## 3.2. Initial Interest Guidance

The N-gram model is a probability-based discriminant model that assumes that the occurrence of thei-th word is only related to the i−1 preceding words and not to any other word. Based on this assumption, it can be assumed that the probability of occurrence of the i-th interest in an interest is only related to the preceding i−1 interests that have been selected and not to any other interests. Therefore, when a student clicks on an interest component, the subsequent predicted interests are calculated by the N element model and the course topic is recommended to the student, i.e., the different candidate course topics are brought into the probability formula psci|sc1…sci−1, is used further to measure the chances of occurrence of an event and recommend interests greater than a threshold T to students as candidates. Here, sci denotes the i-th interest element, sc1,…,sci−1 denotes the sequence of interests from sc1 to sci−1, and psci|sc1…sci−1 denotes when the sequence of interests sc1,…,sci−1 occurs, the probability that the sequence can be linked to sci.To solve the problem in practice, the parameter space ofpsci|sc1…sci−1 is too large and the calculation is very time-consuming. To solve the problem, the Markov assumption is introduced: the emergence of service is only related to a number of services that precede it. Thus equation (1) can be introduced from psci|sc1…sci−1 to hold(1)psci|sc1…sci−1≈psci|sci−N+1…sci−1.Then using the maximum likelihood estimation to solve forpsci,sci−N+1⋯sci−1, equation (2) holds(2)psci|sci−N+1…sci−1=Csci−N+1…sci−1sciCsci−N+1…sci−1,where Csci−N+1…sci−1sci represents the number of occurrences of the sequence of interest sci−N+1…sci−1 in a known dataset.


## 3.3. User Interest Extraction

Probabilistic latent semantic analysis (PLSA) is a generative modeling method for flexible clustering. In this paper, the main purpose of PLSA is to calculate the probability distribution of interest-course topics to achieve clustering so that when students create a learning course based on the recommended topics, the topics that are similar to them are selected based on the probability that they belong to different interests. The probabilistic graphical model of PLSA is shown in Figure2.Figure 2
PLSA’s probabilistic graphical model.In the figureU denotes a student, Z denotes an interest category, SP denotes an observed course topic, pui denotes the probability that student ui appears in the dataset, pzk|ui denotes the probability that student ui belongs to interest category zk, where the student’s interest is not unique, and pspj|zk denotes the probability that course topic spj belongs to this interest category zk when interest zk is determined. As a generative model, to calculate pspj|zk, the joint distribution of pspj|zk needs to be obtained, and since zk is a hidden variable, this joint distribution cannot be found directly. Therefore, the joint distribution of ui,spj can be calculated first based on the observed data pair ui,spj, as shown in equation (3).(3)pui,spj=puipspj|ui=pui∑kKpzk|uipspj|zkThe parameters of the PLSA model are according to the maximum likelihood estimationpspj|zk with the likelihood function L shown in equation (4).(4)L=∏i=1N∏j=1Mpui,spjnui,spj=∏i−1N∏j=1Mpui∑k=1Kpzk|uipspj|zknui,spj,where nui,spj denotes the number of times the student ui selected the interest combination spj. To prevent data overflow due to concatenation, the likelihood function is logarithmically processed to obtain the following equation:(5)logL=∑i=1N∑j=1Mnui,spjlogpui∑k=1Kpzk|uipspj|zk=∑i=1N∑j=1Mnui,spjlogpui+∑i=1N∑j=1Mnui,spjlog∑k=1Kpzk|uipspj|zk.where the first half of ∑i=1N∑j=1Mnui,spjlogpui is a constant. Therefore, only the second half is considered in the calculation, and the second half is named Lh, if the partial derivatives are found directly for the independent variables in Lh , the solution of the equation is difficult due to the fact that the independent variables are included in the logarithmic sum, the solution of the equation is difficult. Here, the Jensen inequality is used to transform Lh. Let Qzk=pzk|ui,spj, which leads to ∑k=1KQzk=1, and Qzk>0, have equation (6) holds(6)Lh=∑i=1N∑j=1Mnui,spjlog∑k=1Kpzk|uipspj|zk=∑i=1N∑j=1Mnui,spjlog∑k=1KQzkpzk|uipspj|zkQzk≥∑i=1N∑j=1Mnui,spj∑k=1KQzklogpzk|uipspj|zkQzk.According to equation (6), instead of calculating the value of the maximum likelihood function itself, the expectation-maximum (EM) algorithm can be used. Instead of calculating the value of the function itself, the expectation-maximum algorithm can be used to maximize the lower bound of the function. The EM algorithm is divided into two steps, E and M. The lower bound of the likelihood function is approximated by cycling through the two steps E and M. When the EM algorithm converges, the parameter values are close to those of the real dataset. The EM algorithm is as follows:(1)
StepE focuses on calculating Qzk, the posterior probability of the hidden variable pzk|ui,spj, which can be done by first randomly initializing the parameters pzk|ui and values of pspj|zk, and then solving the posterior probability of the hidden variable based on the results of the initialization in posterior probability under the current parameter conditions. Their equation (7) holds(7)pzk|ui,spj=pzk,ui,spjpui,spj=puipzk|uipspj|zkpuipspj|ui=pzk|uipspj|zkpspj|ui=pzk|uipspj|zk∑k=1Kpzk|uipspj|zk.(2)
The task of theM-step is expectation maximization, which focuses on polarizing the log-likelihood function containing the parameters based on the posterior probabilities of the hidden variables obtained in the E-step to obtain new parameter values for pzk|ui and pspj|zk, which are then brought into the E-step for looping. To simplify the equation, pzk|ui and pspj|zk are abbreviated as Z. M Steps are shown in equations (3) to (8).(8)Z≔fz=argmax∑i=1N∑j=1Mnui,spj∑k=1KPzk|ui,spjlogpzk|uipspj|zk,s.t.∑k=1Kpzk|ui=1,∑j=1Mpspj|zk=1.Equation (8) is a multivariate polarization problem with constraints. Using the Lagrange multiplier method, a constrained polarization problem can be transformed into a pairwise unconstrained polarization problem by creating a Lagrange function Lg, as shown in the following equation:(9)Lg=fz+∑i=1Nρi1−∑k=1Kpzk|ui+∑k=1Kτk1−∑j=1Mpspj|zk.This is a function ofpzk|ui and pspj|zk. For parameter pzk|ui by taking the partial derivative and making the partial derivative zero, we can obtain the equation as follows: (10)∂Lg∂pzk|ui=0⇒∑i=1N∑j=1Mnui,spj,∑k=1Kpzk|ui,spj=∑i=1N∑k=1Kρipzk|ui.Since∑k=1Kpzk|ui=1, one can deduce that ρi=∑k=1K∑j=1Mnui,spjpzk|ui,spj. Substituting ρi back into equation (10) gives a new value for pzk|ui, as in the following equation:(11)∑i=1N∑j=1Mnui,spj∑k=1Kpzk|ui,spj=∑i=1N∑k=1Kρipzk|ui⇒∑k=1Kpzk|ui=∑k=1K∑j=1Mnui,spjpzk|ui,spjρi⇒pzk|ui=∑j=1Mnui,spjpzk|ui,spj∑k=1K∑j=1Mnui,spjpzk|ui,spj.Similarly,Lg taking the partial derivative of pspj|zk and making the partial derivative zero gives the following equation:(12)pspj|zk=∑i=1Nnui,spjpzk|ui,spj∑i=1N∑j=1Mnui,spjpzk|ui,spj.After obtaining the newpspj|zk and pzk|ui values, the parameters are then brought into the E step to further derive the new pzk|ui,spj, followed by the M step to obtain the updated pspj|zk and pzk|ui values again until the change in the maximum likelihood value reaches a threshold, which indicates that the final parameter values obtained can describe the dataset.


## 4. Design of a Recommendation System for Higher Education Courses Based on Multiple User Interests

Recommendation systems are used in various fields. Design guidelines are sets of recommendations on how to apply design principles to provide a positive user experience. So, the following design recommendation for a system used in courses based on multiple user interests for higher education is as follows.


### 4.1. Functional Logic Design of the System

The system is based on an analysis of the functional requirements of a multiinterest college and university course promotion system. On this basis, the functional logic of the system was designed, and the overall functional framework of the system was designed in accordance with the general process of software engineering design, as shown in Figure3.Figure 3
System functional logic design diagram.The functional modules of the system are designed according to the principles of practicality, modularity, and scalability. The core modules of the system mainly include the submodules for selecting courses for the university thinking course, the submodule for evaluating students of the university thinking course, the submodule for recommending the university thinking course, and the submodule for maintaining and updating the system. All submodules work together under the control of the workflow of the system to build an efficient and practical closed-loop dynamic recommendation mechanism for university thinking courses, forming a virtuous cycle and providing a basic guarantee for the development of university thinking education work.


### 4.2. System Workflow Model Design

Based on the functional logic design of the system, the workflow model of the system is designed in conjunction with the general model of workflow technology in software engineering to ensure that the system operates according to the intended process, as shown in Figure4.Figure 4
System model workflow diagram.After identifying the student population, the system is initialized, mainly by entering information on the current civic studies courses offered by the university and the preferences of students for each course during the previous historical cycles, and by writing initial values to the system data warehouse. The initial dataset is used as the initial cold start of the user multiinterest recommendation algorithm; the personalized scoring mechanism of the civic education courses is activated to evaluate the personalized civic education programmers formulated by the university from the multidimensional effect evaluation; the personalized recommendation submodule of the civic education courses is activated to make personalized and precise civic education course recommendations for different students so as to enhance the interests of students and ensure that the civic education of the university plays its role as a human being.


## 4.1. Functional Logic Design of the System

The system is based on an analysis of the functional requirements of a multiinterest college and university course promotion system. On this basis, the functional logic of the system was designed, and the overall functional framework of the system was designed in accordance with the general process of software engineering design, as shown in Figure3.Figure 3
System functional logic design diagram.The functional modules of the system are designed according to the principles of practicality, modularity, and scalability. The core modules of the system mainly include the submodules for selecting courses for the university thinking course, the submodule for evaluating students of the university thinking course, the submodule for recommending the university thinking course, and the submodule for maintaining and updating the system. All submodules work together under the control of the workflow of the system to build an efficient and practical closed-loop dynamic recommendation mechanism for university thinking courses, forming a virtuous cycle and providing a basic guarantee for the development of university thinking education work.


## 4.2. System Workflow Model Design

Based on the functional logic design of the system, the workflow model of the system is designed in conjunction with the general model of workflow technology in software engineering to ensure that the system operates according to the intended process, as shown in Figure4.Figure 4
System model workflow diagram.After identifying the student population, the system is initialized, mainly by entering information on the current civic studies courses offered by the university and the preferences of students for each course during the previous historical cycles, and by writing initial values to the system data warehouse. The initial dataset is used as the initial cold start of the user multiinterest recommendation algorithm; the personalized scoring mechanism of the civic education courses is activated to evaluate the personalized civic education programmers formulated by the university from the multidimensional effect evaluation; the personalized recommendation submodule of the civic education courses is activated to make personalized and precise civic education course recommendations for different students so as to enhance the interests of students and ensure that the civic education of the university plays its role as a human being.


## 5. Experimental Results and Analysis

### 5.1. Datasets

This paper uses the student course selection call records, the interest portfolio dataset, and the course portfolio dataset from the school selection system website for the experiment. The interest portfolio dataset includes 130 records of interests, the course component dataset includes 20 services, and the user service call records include 20,035 user call records.


### 5.2. Evaluation of Interest-Based Link Recommendation Algorithms Based onN-Gram Models

The N-gram model considers the emergence of interest to be dependent onN other interests before it. In order to select a suitable N value, the accuracy of interest recommendations is compared for different N values, and only N = 2 and N = 3 are considered here because as N increases, the number of dependent interest items also increases. Although the accuracy of the recommendation increases, the number of parameters to be calculated increases exponentially, and in reality, only the cases N = 2 and N = 3 are considered.As shown in Figure5, the vertical coordinates indicate the accuracy of the service component recommendation.(13)precisionsc=LRecsc1…sci∩sci+1LRecsc1…sci,where LRecsc1…sci∩sci+1 denotes the number of interests actually recommended for the called interest sequence sc1…sci, and sci+1 denotes the interest group actually linked for the called interest sequence sc1…sci. It can be seen that as the Top−P increases, the probability that the numerator in precisionsc is 1 increases gradually, and therefore the accuracy of the interest recommendation for 2-gram and 3-gram also gradually improves. However, this improvement ends at a certain point and enters a smoothing period, e.g., at Top−P=6 for 3-gram, the actual recommended components of interest will no longer change with increasing Top−P because of the threshold, and the recommendation accuracy will gradually stabilize.Figure 5
N value estimation.A comparison of the 3-gram and hyperlink-induced topic search (HITS) algorithms is shown in Figure6. The HITS algorithm defines the call-in and call-out of service nodes as authority value and hub value, respectively, and then finds high-quality nodes through nonstop linking iterations, which can be used to discover the linking relationship between services. The graph shows that the interest recommendation accuracy of the 3-gram algorithm is higher than that of the HITS algorithm, especially as the Top-P increases. The recommendation accuracy of the 3-gram gradually stabilizes, but the HITS algorithm will produce link drift after many iterations, and its recommendation accuracy decreases instead.Figure 6
Algorithm comparison.


### 5.3. Evaluation of a PLSA Model-Based Course Recommendation Algorithm

In order to achieve optimal performance of the scheme, this paper usesperplexity to determine the number of interesting clusters for the PLSA model. The perplexity can be thought of as the posterior probability taking a −log value; the larger the posterior probability, the smaller the perplexity, indicating that this parameter is more representative of the truth of this data.(14)perplexity=exp∧−∑j=1MlogpspjM,pspj=∑k=1K∑i=1Npspj|zk⋅pzk|ui.As shown in Figure7, with the number of clusters changing, the perplexity value is also changing. When the number of clusters is 160, the perplexity value is the smallest, with perplexity=198.6, representing the 160 process clusters that best fit this dataset.Figure 7
Selection of the number of interest clusters.


### 5.4. Summary of Experimental Results

Firstly, all the data related to university courses are collected, such as interest portfolios of students and course selection call records. Secondly, an evaluation of interest-based link recommendation algorithms based onN-gram models is underway. An N-gram is a probabilistic model that is trained on a corpus of text. The graph in Figure 5 shows the interest recommendation accuracy of the 3-gram algorithm is better than the N-gram model. Thirdly, PLSA model-based evaluation is discussed by using perplexity to determine the optimal number of interesting clusters to achieve optimal performance.


## 5.1. Datasets

This paper uses the student course selection call records, the interest portfolio dataset, and the course portfolio dataset from the school selection system website for the experiment. The interest portfolio dataset includes 130 records of interests, the course component dataset includes 20 services, and the user service call records include 20,035 user call records.


## 5.2. Evaluation of Interest-Based Link Recommendation Algorithms Based onN-Gram Models

The N-gram model considers the emergence of interest to be dependent onN other interests before it. In order to select a suitable N value, the accuracy of interest recommendations is compared for different N values, and only N = 2 and N = 3 are considered here because as N increases, the number of dependent interest items also increases. Although the accuracy of the recommendation increases, the number of parameters to be calculated increases exponentially, and in reality, only the cases N = 2 and N = 3 are considered.As shown in Figure5, the vertical coordinates indicate the accuracy of the service component recommendation.(13)precisionsc=LRecsc1…sci∩sci+1LRecsc1…sci,where LRecsc1…sci∩sci+1 denotes the number of interests actually recommended for the called interest sequence sc1…sci, and sci+1 denotes the interest group actually linked for the called interest sequence sc1…sci. It can be seen that as the Top−P increases, the probability that the numerator in precisionsc is 1 increases gradually, and therefore the accuracy of the interest recommendation for 2-gram and 3-gram also gradually improves. However, this improvement ends at a certain point and enters a smoothing period, e.g., at Top−P=6 for 3-gram, the actual recommended components of interest will no longer change with increasing Top−P because of the threshold, and the recommendation accuracy will gradually stabilize.Figure 5
N value estimation.A comparison of the 3-gram and hyperlink-induced topic search (HITS) algorithms is shown in Figure6. The HITS algorithm defines the call-in and call-out of service nodes as authority value and hub value, respectively, and then finds high-quality nodes through nonstop linking iterations, which can be used to discover the linking relationship between services. The graph shows that the interest recommendation accuracy of the 3-gram algorithm is higher than that of the HITS algorithm, especially as the Top-P increases. The recommendation accuracy of the 3-gram gradually stabilizes, but the HITS algorithm will produce link drift after many iterations, and its recommendation accuracy decreases instead.Figure 6
Algorithm comparison.


## 5.3. Evaluation of a PLSA Model-Based Course Recommendation Algorithm

In order to achieve optimal performance of the scheme, this paper usesperplexity to determine the number of interesting clusters for the PLSA model. The perplexity can be thought of as the posterior probability taking a −log value; the larger the posterior probability, the smaller the perplexity, indicating that this parameter is more representative of the truth of this data.(14)perplexity=exp∧−∑j=1MlogpspjM,pspj=∑k=1K∑i=1Npspj|zk⋅pzk|ui.As shown in Figure7, with the number of clusters changing, the perplexity value is also changing. When the number of clusters is 160, the perplexity value is the smallest, with perplexity=198.6, representing the 160 process clusters that best fit this dataset.Figure 7
Selection of the number of interest clusters.


## 5.4. Summary of Experimental Results

Firstly, all the data related to university courses are collected, such as interest portfolios of students and course selection call records. Secondly, an evaluation of interest-based link recommendation algorithms based onN-gram models is underway. An N-gram is a probabilistic model that is trained on a corpus of text. The graph in Figure 5 shows the interest recommendation accuracy of the 3-gram algorithm is better than the N-gram model. Thirdly, PLSA model-based evaluation is discussed by using perplexity to determine the optimal number of interesting clusters to achieve optimal performance.


## 6. Conclusion

The purpose of this algorithm is to better meet the development trend of university education in the new situation and to actively create a collaborative, diverse, and innovative atmosphere for university education. The method is designed to address the problems of mechanical rigidity, lack of relevance, lack of synergy, and inability to form a personalized, collaborative education mechanism in the setting of higher education courses. The method uses theN-model algorithm to recommend and invoke matching services for users, which alleviates the problem of mismatched interests of students in studying civics courses. Simulations have shown that the method in this paper can be used for course selection and course evaluation in higher education, providing statistics on students’ preferences for specific civics courses, and the methodology is also used to provide personalized and accurate course recommendations for individual students.



---

*Source: 5207167-2022-03-11.xml*