# Research on Mobile English Learning System Based on iOS

Authors: Xiaofei Zhen
Journal: Security and Communication Networks
 (2021)

---

## Abstract

In order to improve the use experience of mobile learning and reduce the response delay caused by the slow positioning of system resources, research on mobile English learning systems based on iOS is proposed. Firstly, the value of realizing mobile learning is objectively analyzed, and the practical significance of the research is clarified from the perspectives of social development and learning conditions. On this basis, taking the intelligent client equipped with an iOS operating system as the hardware condition of the system, the system architecture, including data access layer, business logic layer, and presentation layer, is constructed by MVC. In the model module, it is divided into ten difficulty levels by using the frequency of vocabulary, the length of words, and the number of syllables of a single word. The learning resources of the reading class are uniformly represented by the vector space model, and the improved TF-IDF is used to calculate the weight of eigenvalues in the resources. According to the calculation results, the resources are also divided into ten difficulty levels, and the divided resources correspond to their respective databases and use regular expressions to find the learning resources that match the access request. Finally, with the support of the iOS protocol, the feedback mechanism between each module is constructed by Express.js. By analyzing the access requests sent and received by the view, the timely call to the target database resources is realized to improve the response rate of the system. The test results show that the function of the designed system can be realized stably, and the module response delay time is stable within 1s; under the ideal network environment, the buffer delay is in the range of 0.4–0.6 s, and the loading delay is no more than 1.8 s when the network speed is 3 Mpbs, which has a good user experience.


---

## Body

## 1. Introduction

Personal needs face both opportunities and challenges in the present and future. In the face of the sharp increase of social knowledge capacity and the rapid obsolescence of personal knowledge enjoyment, people always hope to have the most convenient way to obtain knowledge sources, so as to minimize the deterioration and loss of information caused by too complex and twists and turns in the communication process. Obviously, this is not satisfied by traditional classroom teaching, and simple digital learning also fixes people in front of computers, which can not provide learners with the most portable access [1]. On the other hand, people also hope that in the high-intensity and fast-paced life, those interested or valuable knowledge and information can be consulted and obtained at any time. That is to call for a learning method that can effectively improve learning efficiency and personal knowledge acquisition efficiency. With the evolution of social informatization, the rapid rise of mobile Internet, and the emergence of intelligent mobile terminals, people’s lifestyle and pace of life have been changed. The innovation of science and technology has a far-reaching impact on our lives and greatly facilitates people’s daily lives. The combination of these two technologies not only brings convenience to our life but also has opened a new chapter for the education industry [2, 3]. Under the current social conditions, the possibility of mobile learning has been very mature and convenient. Firstly, with the help of the rapid development of mobile communication technology, from the first-generation mobile communication system, to the second-generation mobile communication system, to the third-generation mobile communication system, and then to the fourth-generation mobile communication system, World Telecom has gradually realized complete personal mobility, reliable transmission, and connection mode. In terms of mobile communication, environment construction has also made rapid development, and mobile communication has been realized in most areas. People can enjoy services from simple voice calls to mobile multimedia services to various broadband information services, such as fast data, TV images, and video phones. So far, mobile communication technology has become an indispensable tool for people’s life [4, 5]. Secondly, the gradual growth of mobile communication industry also promotes the realization of mobile learning. The merger and reorganization of mobile operators has opened a new chapter for the recreation of brilliance in the mobile communication industry. With the development and progress of mobile communication technology, the training of relevant talents, business, application environment, intelligent terminal chips, mobile devices, and other industrial chains have been widely driven and achieved good results. This booming trend has attracted the attention of operators and related enterprises and aroused the interest of more and more experts and scholars. In addition, the reduction and reduction of mobile application charges also make it possible to cover a large area of mobile learning. In terms of mobile devices, the price of mobile devices has become more and more popular in recent years. In terms of communication tariff, major telecom operators have launched different types and ways of tariff reduction schemes. In this context, mobile learning theory and practical technology are becoming more and more mature [6, 7]. Among them, Palau applies mobile learning to art education, describes and explains publications using the method of content-based analysis, and has achieved good application results, but the feedback time in the application process is long, so the use experience needs to be improved [8], in order to find out the problems in the process of biological learning, especially in teachers’ understanding of the developed learning media and the use of learning media in the classroom [9]. Fitriyanti et al. using learning media and mnemonic language skills based on mobile learning applications analyze teachers’ understanding of the development and use of printed learning media, and comes to the conclusion that most teachers can realize the effective application of mobile learning. Fatoni et al. designed mobile learning education games so that users can improve their ability and learning results in computer programs by using quantitative research methods of statistics and analysis. While obtaining good application feedback, some users have low satisfaction with the knowledge content corresponding to the difficulty of the game [10]. It can be seen that mobile learning has been widely developed in different learning fields, but there is still room for further improvement. In order to overcome the limitations of traditional English teaching mode and the disadvantages of mobile teaching classroom, reference [11] proposes a novel optimization strategy of English classroom education ecosystem based on mobile learning system. Reference [12] makes a survey of this area through questionnaire, analyzes the statistics through SPSS software and applies the research findings to construct a MALL pattern in college EFL learners’ autonomous learning and in hope of integrate the learning pattern with college English education.Based on this, this paper proposes the research on mobile English learning system based on iOS, takes the mobile client equipped with iOS operating system as the hardware condition for system operation, uses MVC to establish a three-tier system structure, and divides it according to the difficulty of learning resources, so as to improve the positioning and feedback speed of the system to the content required by users and reduce the delay time of system operation. Finally, the system operation and function implementation effect are tested. The results show that the system designed in this paper can meet the needs of English learning, and the feedback delay of the system is significantly lower than that of the traditional method, which has a certain application value.


## 2. Value Analysis of Realizing Mobile English Learning

In today’s era with network as the core, using mobile devices for learning has become one of the most common ways in our daily life. The goal of mobile learning is to enable people to learn anytime and anywhere. People can use the advanced smart phones to learn independently and supplement knowledge in their leisure time. At present, it is self-evident that education attaches importance to English learning. With mobile learning, you can learn English words, grammar, listening, and speaking ability at any time and communicate on this platform. In the process of learning, you can communicate with learners on the network at any time if you do not understand or have doubts, so as to fundamentally improve English. English subject itself has many forms, such as listening, speaking, reading, and writing, which makes learning more complex and difficult. Network learning overcomes the regional pronunciation differences of language and makes English learning more standardized. As a second language teaching, English is very important, and mobile learning just adapts to the complex learning environment of English with its mobility, timeliness, and fragmentation [13–15]. In addition, with the development of early distance education, the original way of learning only by correspondence in the classroom is far from meeting the needs of educational development under the new situation. People urgently need to carry out autonomous learning in a more advanced way in today’s information society. In this context, the fourth generation of distance education represented by mobile learning was born at this time. Its advantages are mainly reflected in mobility, efficiency, timeliness, universality, personalization, and so on.


### 2.1. Mobility

The main reason why mobile learning is called mobile is that the equipment used is mobile, which is different from the learning mode of fixed classroom in the early stage. The biggest feature of these mobile devices is portability and being easy to use. In recent years, with the development of modern science and technology, the workmanship of mobile devices is becoming more and more beautiful and fine, and the functions are becoming more and more powerful. These devices have become a necessary product in people’s daily life. People can use this device to freely control their time to study and truly achieve the purpose of learning anytime and anywhere.


### 2.2. Efficiency

In early classroom correspondence teaching, teachers forced learners to learn in a passive learning environment, which was inefficient. But in recent years, the rich resources on the Internet and flexible learning methods make learning more interesting and efficient. If learners have any questions when learning on the Internet, they can communicate with their peers on the Internet in time. In this way, efficiency naturally goes up.


### 2.3. Trans Spatiotemporal

Since the proposal of mobile learning, learning is no longer just to impart knowledge in colleges and universities but to achieve the purpose of learning anytime and anywhere. Learners and teachers have got rid of the constraints of the traditional learning environment only in the classroom and can learn, communicate, and answer questions anywhere. So that learning has the characteristics of cross time and space.


### 2.4. Personalization

Learners do not just listen to the teacher talk about the course content every day but can freely grasp the progress, content and duration of learning according to their own time and learning ability. This greatly improves the controllability of learning, gives learners the space to customize freely, and makes learning more personalized.There are many advantages of mobile learning, but mobile learning also has its own disadvantages. The most obvious is that in the process of mobile learning, the loading or transmission delay of learning resources is too high, which affects learners’ enthusiasm and learning efficiency.


## 2.1. Mobility

The main reason why mobile learning is called mobile is that the equipment used is mobile, which is different from the learning mode of fixed classroom in the early stage. The biggest feature of these mobile devices is portability and being easy to use. In recent years, with the development of modern science and technology, the workmanship of mobile devices is becoming more and more beautiful and fine, and the functions are becoming more and more powerful. These devices have become a necessary product in people’s daily life. People can use this device to freely control their time to study and truly achieve the purpose of learning anytime and anywhere.


## 2.2. Efficiency

In early classroom correspondence teaching, teachers forced learners to learn in a passive learning environment, which was inefficient. But in recent years, the rich resources on the Internet and flexible learning methods make learning more interesting and efficient. If learners have any questions when learning on the Internet, they can communicate with their peers on the Internet in time. In this way, efficiency naturally goes up.


## 2.3. Trans Spatiotemporal

Since the proposal of mobile learning, learning is no longer just to impart knowledge in colleges and universities but to achieve the purpose of learning anytime and anywhere. Learners and teachers have got rid of the constraints of the traditional learning environment only in the classroom and can learn, communicate, and answer questions anywhere. So that learning has the characteristics of cross time and space.


## 2.4. Personalization

Learners do not just listen to the teacher talk about the course content every day but can freely grasp the progress, content and duration of learning according to their own time and learning ability. This greatly improves the controllability of learning, gives learners the space to customize freely, and makes learning more personalized.There are many advantages of mobile learning, but mobile learning also has its own disadvantages. The most obvious is that in the process of mobile learning, the loading or transmission delay of learning resources is too high, which affects learners’ enthusiasm and learning efficiency.


## 3. Design of Mobile English Learning System Based on iOS

This paper focuses on the design of mobile learning system based on iOS, so it takes the mobile client equipped with iOS operating system as the hardware basis to carry out relevant research.


### 3.1. Building System Framework

This paper’s mobile English learning system adopts a three-tier architecture, including data access layer, business logic layer, and presentation layer. The data access layer is the bottom layer of the three-tier architecture. It is used to store data and provide access interface to data. It is composed of database and database management system. The presentation layer presents the system interface to users, provides data receiving and request sending interfaces, and is the top layer of the three-tier architecture. On the one hand, the business logic layer is connected to the presentation layer to receive the request sent by the user through the presentation layer; on the other hand, it is connected to the data access layer. After processing the user’s request, it is parsed into database access instructions and sent to the data access layer. At the same time, when the data access layer returns data, it will be logically processed through the business logic layer, and the processed data will be sent to the presentation layer for display to users. The business logic layer is located in the middle of the three-tier architecture. The division of the three-tier architecture in the mobile English learning system is shown in Figure1.Figure 1
System architecture design.The architecture of mobile English learning takes MVC as the main design mode [15]. MVC is a model proposed by Trygve Reenskaug in 1978, which aims to divide modules according to the functions of each basic part of software. It is divided into three parts:(1)
Model: the abstraction of data is used to represent the manifestation of specific data in business logic(2)
Controller: the business logic of the program is also the part of forwarding and processing requests. It connects the model and view and is a key link in the MVC pattern(3)
View: the interface part is used to display information to the user and respond to the user’s inputFigure2 shows the relationship between various parts in the MVC pattern.Figure 2
MVC mode.Among them, model abstracts and objectifies the underlying database data, which avoids a series of strong dependencies caused by the direct operation of the database by the service layer, resulting in program rigidity and poor scalability, and makes it easier for developers to operate and manage. The underlying database of mobile English learning system adopts MongoDB [14, 15], and its data is stored in the form of document and expressed as JSON string. The mobile English learning system uses Mongoose technology to objectify JSON strings to form a data model. View is a user interface that shows the functions of the whole program to users in a graphical way. The user can see the content expressed by the system to the user through the user interface or initiate various requests through the interactive function on the user interface to obtain the corresponding feedback results. According to the requirements of the system, for the website for training schools, its user interface is displayed on iOS by the page of HTML5. The user’s interface operation sends iOS requests to the service layer through JavaScript, and the service layer provides the interface content through iOS response. For the student oriented learning system, the user interface runs on the mobile device in the form of program, and the user operation and the response of the service layer are realized through the network communication interface provided by the mobile device. The controller is the service layer responsible for the data flow processing and control of the whole system. As can be seen from Figure 2, the controller has direct interaction with view and model, and the function of the controller is mainly to interact with view. For the data management and analysis subsystem, the view in the mobile English learning system is generated by the controller according to the request sent by the user and returned to the client browser, rather than the user interface written on the client in advance. For the learning system, the view is written in advance on the client. The part of view interacting with customers is to send requests to the controller through view. The controller returns data by processing requests. Secondly, the controller is also responsible for interacting with the model. View sends a request to the controller. If the data in the database needs to be displayed, the controller will obtain the data in the model and return it to view. If the request only requires updating the data in the model, the controller only notifies the model to update the data. According to the previous user demand analysis for mobile English learning system, the user’s requests are diverse, so the logic to be processed is also complex. Using MVC mode can separate the levels, make the whole system appear concise and clear, enhance the system’s robustness, and control the possibility of system errors. Figure 3 shows a sequence diagram of a user acquiring a specified learning resource.Figure 3
Sequence diagram of user acquiring resources.In Figure3, we have simplified it to the greatest extent, but although it is only a simple request, it also goes through a more complex data processing process in the whole system. In Figure 3, the database on the right can be regarded as a model in MVC mode, the server can be understood as a controller, and the left is a collection of interfaces. The user logs in through the operation intention of the interface. After receiving this message, the server creates a login interface and returns it to the user. After entering the username and password, the user clicks login, and a login request is sent to the server. At this time, the server will call the authentication method of the database for verification and send a successful login message to the server. After receiving the message, the server will not directly return it to the user but build the course main interface to return it to the user. In the view of the user, the page jumps to the course main interface, indicating that the login is successful. Next, the user needs to select the courses he wants to learn. First, he needs to get the list of courses he can learn. Therefore, his operation triggers the server to obtain the method of all course lists. The server will call the find() method of the database to return all course objects to the server, and the server will return them to the user as a course list. When the user gets the list, he can select one of them. At this time, the method that the server obtains the course according to the course ID is triggered, and then the Findbyld () method of the database is called to obtain the specific course and return it to the user.


### 3.2. Classification of Learning Resources

English learning includes basic knowledge learning and oral expression. Therefore, in the model layer, divide the data from the perspectives of vocabulary and reading, and establish corresponding databases to ensure that the system can give timely and accurate feedback to the learning requests sent by the view layer.


#### 3.2.1. Classification of Vocabulary Difficulty Level

The system ignores the influence of word idioms on vocabulary difficulty when calculating vocabulary difficulty. Focus on the frequency of the word, the length of the word itself, the difficulty of pronunciation, and so on. This paper defines the difficulty of vocabulary as the difficulty of the word itself [16]. Vocabulary difficulty refers to the difficulty of the dictionary itself. The difficulty is mainly calculated according to the vocabulary factors, such as the frequency of vocabulary use, the length of words, and the number of syllables. For all learners, the difficulty of the same dictionary is the same. The formula of lexical difficulty can be expressed as(1)Hi=Pi0.7Li×0.3Yi,where Hi represents the difficulty of i word, Li represents the length coefficient of i word, Yi represents the syllable length coefficient of i word, and Pi represents the difficulty coefficient of i word determined according to the word frequency.In order to avoid the word length being too long or too short and ensure that it is within the quantifiable range, we must normalize the word length and calculate the corrected length of the word. Suppose that the maximum length, minimum length, and median length of words in the database are recorded asLmax, Lmin, and Lmid, respectively. When Li is Lmax, Lmin, and Lmid, respectively, Li is assigned as 100, 0, and 50, respectively. When Li is other values, the calculation method of copy results can be expressed as(2)Li=5050+Li+LmidLmax−LmidLi>Lmid50Li+LmidLmid−LminLi<Lmin.The average syllable length represents the length of each phonetic symbol of a word. The length of the word occupied by each phonetic symbol of the word is calculated as follows:(3)PY=YiLi,where py is the ratio of the length of words to the length of phonetics.In order to normalize, it is necessary to count theYi values of all words in the dictionary according to the length of each word and the phonetic length and obtain the maximum and minimum values, which are recorded as Ymaxand Ymin, respectively. When the actual average length Yi of phonetic is equal to Ymax and Ymin, respectively, Yi is given the correction length of 100 and 0, respectively, then the calculation method of the corrected phonetic length of i word is as follows:(4)Yi=0Yi=Ymin100Yi=Ymax1000Yi−YminYmax−YminYmin<Yi<Ymax.In order to calculate the influence of word frequency on vocabulary difficulty, this paper uses the Gutenberg plan, which counts the words of all electronic publications with a large vocabulary and is more persuasive for the provided word frequency, as the source of word frequency [17]. Download and save the word frequencies of all words in the Gutenberg plan. According to the constructed dictionary, extract the word frequencies of the words in the dictionary from the downloaded Gutenberg plan dictionary and sort the words according to the frequency. Divide the sorted frequencies into 10 groups, record them as 10 levels, and set the vocabulary difficulty coefficients of 10 levels as 0.01, 0.02, 0.03, and 0.04, respectively until 0.1. The vocabulary difficulty with high word frequency is the lowest, and the difficulty with the lowest word frequency is the highest.According to the above calculation, the vocabulary difficultyHi will be limited to 0–100, and then this paper will locate the vocabulary difficulty at level 10, as shown in Table 1.Table 1
Classification criteria of vocabulary difficulty level.
Serial numberDifficulty levelDivision criteria10Hi = [0, 0.1)21Hi = [0.1, 0.2)32Hi = [0.2, 0.3)43Hi = [0.3, 0.4)54Hi = [0.4, 0.5)65Hi = [0.5, 0.6)76Hi = [0.6, 0.7)87Hi = [0.7, 0.8)98Hi = [0.8, 0.9)109Hi = [0.9, 1.0]


#### 3.2.2. Classification of Article Readability

Article readability refers to the degree to which the English text is read and understood. Some people call it readability. This paper uses the readability of the article to measure the difficulty of the article. On the whole, the factors that determine the readability of articles can be divided into three categories: the factors of English articles themselves, learners themselves, and learning environment [18]. Because the text factor is static, while the learner’s own factor and learning environment factor are dynamic, this paper can only start from the English article’s own factor in order to quantify the text difficulty. Because the existing readability formulas have different defects, this paper considers using a new method to judge the text difficulty and regards the text difficulty judgment as a classification problem.In fact, the task of text classification system is to automatically associate to its corresponding category according to the attributes of article feature items when the classification category is determined. According to the understanding of mathematics, text classification is the process of mapping the elements in one set to the elements in another set. It associates the text without category with the determined classification system. However, the association rules of text classification are based on the determined classification system. The system automatically calculates the characteristic attribute information of each category to which the marked text belongs and establishes the discrimination formula and discrimination rules according to the classification regularity to realize the classification of texts without marked category information.In order to establish the criteria, the text type of data must be converted into a format that the computer can recognize. Because feature selection extracts feature items from all features of each type of text that can reflect and distinguish this type of text from other texts, feature selection in text classification requires many known types of text. Words are the most basic feature items of text representation, and different words have different effects on text representation. Common words have a very high frequency in most texts and have a low discrimination effect in classification. Therefore, this paper filters out English stop words through preprocessing [19], including punctuation, functional words, and function words, such as “the,” “at,” “in,” and “of,” so as to dry other words in the text. On this basis, this paper selects the vector space model (VSM) as the text representation method [20] and represents text as a vector:(5)Z=t1W1,t2W2,t3W3…tiWi,where Z represents the text information, ti is the semantic unit, in this task, ti represents i word in the text after word stemming, and Wi is the weight of i feature item.In the vector space model, the contribution of each feature item to the classification is different, so it is necessary to calculate the weight. In this paper, the improved TF-IDF is used to calculate the weight value:(6)wki=tfki×logNi/nk+Li∑k=1Nitfki×logNi/nk+Li2,where wki is the weight value of feature ki, tf (ki) is the frequency of feature ki in text document Z, Ni is the total number of English texts, and nk is the number of texts with feature ki in English text set.In order to better judge the difficulty of the article, this paper improves the weight calculation formula. When investigating the difficulty of feature items in text classification, it is to add the characteristics of the feature items themselves, that is, the difficulty of wordswd(ki). The weight is calculated as follows:(7)Wki=wki+wdki∑k=1Nitfki.Similarly, according to the classification of words, the text difficulty is set to level 10. Support vector machine (SVM) is used for text classification. The steps are as follows:(1)
Select training corpus, and equal proportion of training texts should be selected for each category(2)
Preprocessing and feature selection, stemming the text corpus, removing the stop words, then extracting the remaining words, constructing the feature item dictionary, and indexing are the next step(3)
In step 3, we have statistical calculation, counting word frequency and document frequency, and preparing for feature item weight calculation(4)
The text feature weight is calculated by formula7(5)
Use open source libsvml52 l for training(6)
The text to be classified is operated in steps 2, 3, and 4; using the open source libsvm for testing, each new article has a categoryIn this way, the learning resources are classified according to the difficulty and corresponding to the corresponding database.


### 3.3. Resource Request Matching

In order to achieve high matching between access requests and learning resources, this paper uses regular ex compression to realize the process and uses a single string to describe and match a string that conforms to the corresponding request rules [21].First, regular expressions are usually used to retrieve and replace text that matches a pattern of the request. A powerful and easy-to-use regular expression re module is built inPython for string operation. Re supports regular expressions, which can match or replace text, and allows users to construct matching patterns by using a series of ordinary characters and special characters to describe matching patterns. On this basis, the regular expression interpretation engine is used to traverse the database, match the appropriate resource content, and use the pattern as the separator to decompose the string into sub strings. Because of this characteristic, it solves a large number of common tasks of text processing, which is efficient and convenient [22].Regular expression is composed of some ordinary characters and metacharacters. Its structure has three parts: anchor, character set, and modifier:(8)fq=e,d,o,where q is the access request and e, d, and o represent anchor, character set, and modifier, respectively.Using regular expressions and strings, the first thing we can do is to match and check whether the string can meet the filtering rules of regular expressions. Then, we can filter and obtain the content consistent with the user’s needs from the matched text string in combination with regular expressions. In the regular expression, the search () method is to find and match any position of the database string at one time and return one result found first, not all matching results at one time. In the search () method, there are two optional parameters of string, POS and endpos, which specify the string’s starting and ending positions, which correspond to the two poles of 10 databases with different difficulties. The default values are 0 and 9, respectively. If the matching is successful, the resource in the database is returned; otherwise, it is none. Figure4 shows the flowchart of learning resource matching based on the vocabulary and articles extracted in this paper.Figure 4
Flowchart of learning resource matching.


### 3.4. Construction of System Request Response Mechanism

When a view request is sent, the service management system of the mobile English learning system needs to analyze it to distinguish the type and parameters of the request. The system needs to distinguish different types of requests to ensure that the system can extract the learning content in the database consistent with the request darkness, routing control. After entering the processing program, some requests require the system to return a complete page to the user, while others only need to return data and display it in the view module of the system to complete the response to the request. For returning a complete page, we can process it by returning a static HTML file. For returning some data, we will use the design method of RESTFul API [23, 24], as shown in Figure 5.Figure 5
Request response sequence diagram.


#### 3.4.1. Basic Feedback Mechanism

As one of the most popular application frameworks, Express.js provides a series of powerful features to help programmers build various iOS applications [25]. This article uses it to provide iOS-oriented services. The first is the basic feedback of view user information. Its setting method is shown in Algorithm 1.Algorithm 1: Callback function.
var express = require(“express”);var iOS = require(“iOS”);var app = express();app.use(function(request, response) {response.writeHead(200, { “Content-Type”: “text/plain” });response.end(“Welcome to English Learning System!”);});iOS.createServer(app).listen(8080);As you can see, a callback function is used in the parameters of the createServer method. In the following code, this article uses an Express system object to replace it and then invokes the use method of the system to invoke the callback function before. From here, we can see that Express.js is encapsulated on iOS, and the call of use method is equivalent to calling middleware. Middleware is a function defined to implement a specific job. The process of processing an iOS request can be decomposed into the process of executing a series of Middleware in sequence. According to the settings of the middleware itself, decide whether to continue to call the next middleware after processing one middleware, as shown in Figure6.Figure 6
Flow of middleware processing request.


#### 3.4.2. Resource Feedback Mechanism

In the process of middleware processing, call the next middleware through the call of the next method until the next method is no longer called and the response is returned, or an error occurs in the middle and enters the exception handler. Middleware can return different contents according to different request information.Algorithm 2:
var express = require(“express”);var iOS = require(“iOS”);var app = express();app.use(function(request, response, next) {if (request.url = = “/”) {response.writeHead(200, { “Content-Type”: “text/plain” });response.end(“Welcome to English Learning System!”);} else {next();}});app.use(function(request, response, next) {if (request.url = = “/login”) {response.writeHead(200, { “Content-Type”: “text/plain” });response.end(“Please Enter your username and password!”);} else {next();}});app.use(function(request, response) {response.writeHead(404, {“Content-Type”: “text/plain”});response.end(“404 error!\n”);});iOS.createServer(app).listen(8080);The above code shows the different responses made by the middleware when sending iOS://localhost: 8080/and iOS://localhost: 8080/login. The first one will return “welcome toe English learningsystem!” The second is to return “please enter your username and password!” For other requests, such as iOS://localhost: 8080//getusers, “404 error” is returned.For displaying complex data to the system, only transmitting data is not enough. The system page template provides the ability to display rich content to users. This paper uses the static template to transfer the static HTML file to iOS. The file source is the database corresponding to different difficulties established above and stores it in the views folder of the system. When it is necessary to transfer the static template, it can be realized through the following code:app.get(&ldquor;/‟, function(request, response){response.sendfile(&ldquor./views/index.html‟);}For dynamic templates, you need to use the template engine. In this paper, jade is officially recommended to set the template engine, which is expressed as follows.app.set(&ldquor;view engine‟, &ldquor;jade‟);In this way, the system realizes dynamic feedback to the request.


## 3.1. Building System Framework

This paper’s mobile English learning system adopts a three-tier architecture, including data access layer, business logic layer, and presentation layer. The data access layer is the bottom layer of the three-tier architecture. It is used to store data and provide access interface to data. It is composed of database and database management system. The presentation layer presents the system interface to users, provides data receiving and request sending interfaces, and is the top layer of the three-tier architecture. On the one hand, the business logic layer is connected to the presentation layer to receive the request sent by the user through the presentation layer; on the other hand, it is connected to the data access layer. After processing the user’s request, it is parsed into database access instructions and sent to the data access layer. At the same time, when the data access layer returns data, it will be logically processed through the business logic layer, and the processed data will be sent to the presentation layer for display to users. The business logic layer is located in the middle of the three-tier architecture. The division of the three-tier architecture in the mobile English learning system is shown in Figure1.Figure 1
System architecture design.The architecture of mobile English learning takes MVC as the main design mode [15]. MVC is a model proposed by Trygve Reenskaug in 1978, which aims to divide modules according to the functions of each basic part of software. It is divided into three parts:(1)
Model: the abstraction of data is used to represent the manifestation of specific data in business logic(2)
Controller: the business logic of the program is also the part of forwarding and processing requests. It connects the model and view and is a key link in the MVC pattern(3)
View: the interface part is used to display information to the user and respond to the user’s inputFigure2 shows the relationship between various parts in the MVC pattern.Figure 2
MVC mode.Among them, model abstracts and objectifies the underlying database data, which avoids a series of strong dependencies caused by the direct operation of the database by the service layer, resulting in program rigidity and poor scalability, and makes it easier for developers to operate and manage. The underlying database of mobile English learning system adopts MongoDB [14, 15], and its data is stored in the form of document and expressed as JSON string. The mobile English learning system uses Mongoose technology to objectify JSON strings to form a data model. View is a user interface that shows the functions of the whole program to users in a graphical way. The user can see the content expressed by the system to the user through the user interface or initiate various requests through the interactive function on the user interface to obtain the corresponding feedback results. According to the requirements of the system, for the website for training schools, its user interface is displayed on iOS by the page of HTML5. The user’s interface operation sends iOS requests to the service layer through JavaScript, and the service layer provides the interface content through iOS response. For the student oriented learning system, the user interface runs on the mobile device in the form of program, and the user operation and the response of the service layer are realized through the network communication interface provided by the mobile device. The controller is the service layer responsible for the data flow processing and control of the whole system. As can be seen from Figure 2, the controller has direct interaction with view and model, and the function of the controller is mainly to interact with view. For the data management and analysis subsystem, the view in the mobile English learning system is generated by the controller according to the request sent by the user and returned to the client browser, rather than the user interface written on the client in advance. For the learning system, the view is written in advance on the client. The part of view interacting with customers is to send requests to the controller through view. The controller returns data by processing requests. Secondly, the controller is also responsible for interacting with the model. View sends a request to the controller. If the data in the database needs to be displayed, the controller will obtain the data in the model and return it to view. If the request only requires updating the data in the model, the controller only notifies the model to update the data. According to the previous user demand analysis for mobile English learning system, the user’s requests are diverse, so the logic to be processed is also complex. Using MVC mode can separate the levels, make the whole system appear concise and clear, enhance the system’s robustness, and control the possibility of system errors. Figure 3 shows a sequence diagram of a user acquiring a specified learning resource.Figure 3
Sequence diagram of user acquiring resources.In Figure3, we have simplified it to the greatest extent, but although it is only a simple request, it also goes through a more complex data processing process in the whole system. In Figure 3, the database on the right can be regarded as a model in MVC mode, the server can be understood as a controller, and the left is a collection of interfaces. The user logs in through the operation intention of the interface. After receiving this message, the server creates a login interface and returns it to the user. After entering the username and password, the user clicks login, and a login request is sent to the server. At this time, the server will call the authentication method of the database for verification and send a successful login message to the server. After receiving the message, the server will not directly return it to the user but build the course main interface to return it to the user. In the view of the user, the page jumps to the course main interface, indicating that the login is successful. Next, the user needs to select the courses he wants to learn. First, he needs to get the list of courses he can learn. Therefore, his operation triggers the server to obtain the method of all course lists. The server will call the find() method of the database to return all course objects to the server, and the server will return them to the user as a course list. When the user gets the list, he can select one of them. At this time, the method that the server obtains the course according to the course ID is triggered, and then the Findbyld () method of the database is called to obtain the specific course and return it to the user.


## 3.2. Classification of Learning Resources

English learning includes basic knowledge learning and oral expression. Therefore, in the model layer, divide the data from the perspectives of vocabulary and reading, and establish corresponding databases to ensure that the system can give timely and accurate feedback to the learning requests sent by the view layer.


### 3.2.1. Classification of Vocabulary Difficulty Level

The system ignores the influence of word idioms on vocabulary difficulty when calculating vocabulary difficulty. Focus on the frequency of the word, the length of the word itself, the difficulty of pronunciation, and so on. This paper defines the difficulty of vocabulary as the difficulty of the word itself [16]. Vocabulary difficulty refers to the difficulty of the dictionary itself. The difficulty is mainly calculated according to the vocabulary factors, such as the frequency of vocabulary use, the length of words, and the number of syllables. For all learners, the difficulty of the same dictionary is the same. The formula of lexical difficulty can be expressed as(1)Hi=Pi0.7Li×0.3Yi,where Hi represents the difficulty of i word, Li represents the length coefficient of i word, Yi represents the syllable length coefficient of i word, and Pi represents the difficulty coefficient of i word determined according to the word frequency.In order to avoid the word length being too long or too short and ensure that it is within the quantifiable range, we must normalize the word length and calculate the corrected length of the word. Suppose that the maximum length, minimum length, and median length of words in the database are recorded asLmax, Lmin, and Lmid, respectively. When Li is Lmax, Lmin, and Lmid, respectively, Li is assigned as 100, 0, and 50, respectively. When Li is other values, the calculation method of copy results can be expressed as(2)Li=5050+Li+LmidLmax−LmidLi>Lmid50Li+LmidLmid−LminLi<Lmin.The average syllable length represents the length of each phonetic symbol of a word. The length of the word occupied by each phonetic symbol of the word is calculated as follows:(3)PY=YiLi,where py is the ratio of the length of words to the length of phonetics.In order to normalize, it is necessary to count theYi values of all words in the dictionary according to the length of each word and the phonetic length and obtain the maximum and minimum values, which are recorded as Ymaxand Ymin, respectively. When the actual average length Yi of phonetic is equal to Ymax and Ymin, respectively, Yi is given the correction length of 100 and 0, respectively, then the calculation method of the corrected phonetic length of i word is as follows:(4)Yi=0Yi=Ymin100Yi=Ymax1000Yi−YminYmax−YminYmin<Yi<Ymax.In order to calculate the influence of word frequency on vocabulary difficulty, this paper uses the Gutenberg plan, which counts the words of all electronic publications with a large vocabulary and is more persuasive for the provided word frequency, as the source of word frequency [17]. Download and save the word frequencies of all words in the Gutenberg plan. According to the constructed dictionary, extract the word frequencies of the words in the dictionary from the downloaded Gutenberg plan dictionary and sort the words according to the frequency. Divide the sorted frequencies into 10 groups, record them as 10 levels, and set the vocabulary difficulty coefficients of 10 levels as 0.01, 0.02, 0.03, and 0.04, respectively until 0.1. The vocabulary difficulty with high word frequency is the lowest, and the difficulty with the lowest word frequency is the highest.According to the above calculation, the vocabulary difficultyHi will be limited to 0–100, and then this paper will locate the vocabulary difficulty at level 10, as shown in Table 1.Table 1
Classification criteria of vocabulary difficulty level.
Serial numberDifficulty levelDivision criteria10Hi = [0, 0.1)21Hi = [0.1, 0.2)32Hi = [0.2, 0.3)43Hi = [0.3, 0.4)54Hi = [0.4, 0.5)65Hi = [0.5, 0.6)76Hi = [0.6, 0.7)87Hi = [0.7, 0.8)98Hi = [0.8, 0.9)109Hi = [0.9, 1.0]


### 3.2.2. Classification of Article Readability

Article readability refers to the degree to which the English text is read and understood. Some people call it readability. This paper uses the readability of the article to measure the difficulty of the article. On the whole, the factors that determine the readability of articles can be divided into three categories: the factors of English articles themselves, learners themselves, and learning environment [18]. Because the text factor is static, while the learner’s own factor and learning environment factor are dynamic, this paper can only start from the English article’s own factor in order to quantify the text difficulty. Because the existing readability formulas have different defects, this paper considers using a new method to judge the text difficulty and regards the text difficulty judgment as a classification problem.In fact, the task of text classification system is to automatically associate to its corresponding category according to the attributes of article feature items when the classification category is determined. According to the understanding of mathematics, text classification is the process of mapping the elements in one set to the elements in another set. It associates the text without category with the determined classification system. However, the association rules of text classification are based on the determined classification system. The system automatically calculates the characteristic attribute information of each category to which the marked text belongs and establishes the discrimination formula and discrimination rules according to the classification regularity to realize the classification of texts without marked category information.In order to establish the criteria, the text type of data must be converted into a format that the computer can recognize. Because feature selection extracts feature items from all features of each type of text that can reflect and distinguish this type of text from other texts, feature selection in text classification requires many known types of text. Words are the most basic feature items of text representation, and different words have different effects on text representation. Common words have a very high frequency in most texts and have a low discrimination effect in classification. Therefore, this paper filters out English stop words through preprocessing [19], including punctuation, functional words, and function words, such as “the,” “at,” “in,” and “of,” so as to dry other words in the text. On this basis, this paper selects the vector space model (VSM) as the text representation method [20] and represents text as a vector:(5)Z=t1W1,t2W2,t3W3…tiWi,where Z represents the text information, ti is the semantic unit, in this task, ti represents i word in the text after word stemming, and Wi is the weight of i feature item.In the vector space model, the contribution of each feature item to the classification is different, so it is necessary to calculate the weight. In this paper, the improved TF-IDF is used to calculate the weight value:(6)wki=tfki×logNi/nk+Li∑k=1Nitfki×logNi/nk+Li2,where wki is the weight value of feature ki, tf (ki) is the frequency of feature ki in text document Z, Ni is the total number of English texts, and nk is the number of texts with feature ki in English text set.In order to better judge the difficulty of the article, this paper improves the weight calculation formula. When investigating the difficulty of feature items in text classification, it is to add the characteristics of the feature items themselves, that is, the difficulty of wordswd(ki). The weight is calculated as follows:(7)Wki=wki+wdki∑k=1Nitfki.Similarly, according to the classification of words, the text difficulty is set to level 10. Support vector machine (SVM) is used for text classification. The steps are as follows:(1)
Select training corpus, and equal proportion of training texts should be selected for each category(2)
Preprocessing and feature selection, stemming the text corpus, removing the stop words, then extracting the remaining words, constructing the feature item dictionary, and indexing are the next step(3)
In step 3, we have statistical calculation, counting word frequency and document frequency, and preparing for feature item weight calculation(4)
The text feature weight is calculated by formula7(5)
Use open source libsvml52 l for training(6)
The text to be classified is operated in steps 2, 3, and 4; using the open source libsvm for testing, each new article has a categoryIn this way, the learning resources are classified according to the difficulty and corresponding to the corresponding database.


## 3.2.1. Classification of Vocabulary Difficulty Level

The system ignores the influence of word idioms on vocabulary difficulty when calculating vocabulary difficulty. Focus on the frequency of the word, the length of the word itself, the difficulty of pronunciation, and so on. This paper defines the difficulty of vocabulary as the difficulty of the word itself [16]. Vocabulary difficulty refers to the difficulty of the dictionary itself. The difficulty is mainly calculated according to the vocabulary factors, such as the frequency of vocabulary use, the length of words, and the number of syllables. For all learners, the difficulty of the same dictionary is the same. The formula of lexical difficulty can be expressed as(1)Hi=Pi0.7Li×0.3Yi,where Hi represents the difficulty of i word, Li represents the length coefficient of i word, Yi represents the syllable length coefficient of i word, and Pi represents the difficulty coefficient of i word determined according to the word frequency.In order to avoid the word length being too long or too short and ensure that it is within the quantifiable range, we must normalize the word length and calculate the corrected length of the word. Suppose that the maximum length, minimum length, and median length of words in the database are recorded asLmax, Lmin, and Lmid, respectively. When Li is Lmax, Lmin, and Lmid, respectively, Li is assigned as 100, 0, and 50, respectively. When Li is other values, the calculation method of copy results can be expressed as(2)Li=5050+Li+LmidLmax−LmidLi>Lmid50Li+LmidLmid−LminLi<Lmin.The average syllable length represents the length of each phonetic symbol of a word. The length of the word occupied by each phonetic symbol of the word is calculated as follows:(3)PY=YiLi,where py is the ratio of the length of words to the length of phonetics.In order to normalize, it is necessary to count theYi values of all words in the dictionary according to the length of each word and the phonetic length and obtain the maximum and minimum values, which are recorded as Ymaxand Ymin, respectively. When the actual average length Yi of phonetic is equal to Ymax and Ymin, respectively, Yi is given the correction length of 100 and 0, respectively, then the calculation method of the corrected phonetic length of i word is as follows:(4)Yi=0Yi=Ymin100Yi=Ymax1000Yi−YminYmax−YminYmin<Yi<Ymax.In order to calculate the influence of word frequency on vocabulary difficulty, this paper uses the Gutenberg plan, which counts the words of all electronic publications with a large vocabulary and is more persuasive for the provided word frequency, as the source of word frequency [17]. Download and save the word frequencies of all words in the Gutenberg plan. According to the constructed dictionary, extract the word frequencies of the words in the dictionary from the downloaded Gutenberg plan dictionary and sort the words according to the frequency. Divide the sorted frequencies into 10 groups, record them as 10 levels, and set the vocabulary difficulty coefficients of 10 levels as 0.01, 0.02, 0.03, and 0.04, respectively until 0.1. The vocabulary difficulty with high word frequency is the lowest, and the difficulty with the lowest word frequency is the highest.According to the above calculation, the vocabulary difficultyHi will be limited to 0–100, and then this paper will locate the vocabulary difficulty at level 10, as shown in Table 1.Table 1
Classification criteria of vocabulary difficulty level.
Serial numberDifficulty levelDivision criteria10Hi = [0, 0.1)21Hi = [0.1, 0.2)32Hi = [0.2, 0.3)43Hi = [0.3, 0.4)54Hi = [0.4, 0.5)65Hi = [0.5, 0.6)76Hi = [0.6, 0.7)87Hi = [0.7, 0.8)98Hi = [0.8, 0.9)109Hi = [0.9, 1.0]


## 3.2.2. Classification of Article Readability

Article readability refers to the degree to which the English text is read and understood. Some people call it readability. This paper uses the readability of the article to measure the difficulty of the article. On the whole, the factors that determine the readability of articles can be divided into three categories: the factors of English articles themselves, learners themselves, and learning environment [18]. Because the text factor is static, while the learner’s own factor and learning environment factor are dynamic, this paper can only start from the English article’s own factor in order to quantify the text difficulty. Because the existing readability formulas have different defects, this paper considers using a new method to judge the text difficulty and regards the text difficulty judgment as a classification problem.In fact, the task of text classification system is to automatically associate to its corresponding category according to the attributes of article feature items when the classification category is determined. According to the understanding of mathematics, text classification is the process of mapping the elements in one set to the elements in another set. It associates the text without category with the determined classification system. However, the association rules of text classification are based on the determined classification system. The system automatically calculates the characteristic attribute information of each category to which the marked text belongs and establishes the discrimination formula and discrimination rules according to the classification regularity to realize the classification of texts without marked category information.In order to establish the criteria, the text type of data must be converted into a format that the computer can recognize. Because feature selection extracts feature items from all features of each type of text that can reflect and distinguish this type of text from other texts, feature selection in text classification requires many known types of text. Words are the most basic feature items of text representation, and different words have different effects on text representation. Common words have a very high frequency in most texts and have a low discrimination effect in classification. Therefore, this paper filters out English stop words through preprocessing [19], including punctuation, functional words, and function words, such as “the,” “at,” “in,” and “of,” so as to dry other words in the text. On this basis, this paper selects the vector space model (VSM) as the text representation method [20] and represents text as a vector:(5)Z=t1W1,t2W2,t3W3…tiWi,where Z represents the text information, ti is the semantic unit, in this task, ti represents i word in the text after word stemming, and Wi is the weight of i feature item.In the vector space model, the contribution of each feature item to the classification is different, so it is necessary to calculate the weight. In this paper, the improved TF-IDF is used to calculate the weight value:(6)wki=tfki×logNi/nk+Li∑k=1Nitfki×logNi/nk+Li2,where wki is the weight value of feature ki, tf (ki) is the frequency of feature ki in text document Z, Ni is the total number of English texts, and nk is the number of texts with feature ki in English text set.In order to better judge the difficulty of the article, this paper improves the weight calculation formula. When investigating the difficulty of feature items in text classification, it is to add the characteristics of the feature items themselves, that is, the difficulty of wordswd(ki). The weight is calculated as follows:(7)Wki=wki+wdki∑k=1Nitfki.Similarly, according to the classification of words, the text difficulty is set to level 10. Support vector machine (SVM) is used for text classification. The steps are as follows:(1)
Select training corpus, and equal proportion of training texts should be selected for each category(2)
Preprocessing and feature selection, stemming the text corpus, removing the stop words, then extracting the remaining words, constructing the feature item dictionary, and indexing are the next step(3)
In step 3, we have statistical calculation, counting word frequency and document frequency, and preparing for feature item weight calculation(4)
The text feature weight is calculated by formula7(5)
Use open source libsvml52 l for training(6)
The text to be classified is operated in steps 2, 3, and 4; using the open source libsvm for testing, each new article has a categoryIn this way, the learning resources are classified according to the difficulty and corresponding to the corresponding database.


## 3.3. Resource Request Matching

In order to achieve high matching between access requests and learning resources, this paper uses regular ex compression to realize the process and uses a single string to describe and match a string that conforms to the corresponding request rules [21].First, regular expressions are usually used to retrieve and replace text that matches a pattern of the request. A powerful and easy-to-use regular expression re module is built inPython for string operation. Re supports regular expressions, which can match or replace text, and allows users to construct matching patterns by using a series of ordinary characters and special characters to describe matching patterns. On this basis, the regular expression interpretation engine is used to traverse the database, match the appropriate resource content, and use the pattern as the separator to decompose the string into sub strings. Because of this characteristic, it solves a large number of common tasks of text processing, which is efficient and convenient [22].Regular expression is composed of some ordinary characters and metacharacters. Its structure has three parts: anchor, character set, and modifier:(8)fq=e,d,o,where q is the access request and e, d, and o represent anchor, character set, and modifier, respectively.Using regular expressions and strings, the first thing we can do is to match and check whether the string can meet the filtering rules of regular expressions. Then, we can filter and obtain the content consistent with the user’s needs from the matched text string in combination with regular expressions. In the regular expression, the search () method is to find and match any position of the database string at one time and return one result found first, not all matching results at one time. In the search () method, there are two optional parameters of string, POS and endpos, which specify the string’s starting and ending positions, which correspond to the two poles of 10 databases with different difficulties. The default values are 0 and 9, respectively. If the matching is successful, the resource in the database is returned; otherwise, it is none. Figure4 shows the flowchart of learning resource matching based on the vocabulary and articles extracted in this paper.Figure 4
Flowchart of learning resource matching.


## 3.4. Construction of System Request Response Mechanism

When a view request is sent, the service management system of the mobile English learning system needs to analyze it to distinguish the type and parameters of the request. The system needs to distinguish different types of requests to ensure that the system can extract the learning content in the database consistent with the request darkness, routing control. After entering the processing program, some requests require the system to return a complete page to the user, while others only need to return data and display it in the view module of the system to complete the response to the request. For returning a complete page, we can process it by returning a static HTML file. For returning some data, we will use the design method of RESTFul API [23, 24], as shown in Figure 5.Figure 5
Request response sequence diagram.


### 3.4.1. Basic Feedback Mechanism

As one of the most popular application frameworks, Express.js provides a series of powerful features to help programmers build various iOS applications [25]. This article uses it to provide iOS-oriented services. The first is the basic feedback of view user information. Its setting method is shown in Algorithm 1.Algorithm 1: Callback function.
var express = require(“express”);var iOS = require(“iOS”);var app = express();app.use(function(request, response) {response.writeHead(200, { “Content-Type”: “text/plain” });response.end(“Welcome to English Learning System!”);});iOS.createServer(app).listen(8080);As you can see, a callback function is used in the parameters of the createServer method. In the following code, this article uses an Express system object to replace it and then invokes the use method of the system to invoke the callback function before. From here, we can see that Express.js is encapsulated on iOS, and the call of use method is equivalent to calling middleware. Middleware is a function defined to implement a specific job. The process of processing an iOS request can be decomposed into the process of executing a series of Middleware in sequence. According to the settings of the middleware itself, decide whether to continue to call the next middleware after processing one middleware, as shown in Figure6.Figure 6
Flow of middleware processing request.


### 3.4.2. Resource Feedback Mechanism

In the process of middleware processing, call the next middleware through the call of the next method until the next method is no longer called and the response is returned, or an error occurs in the middle and enters the exception handler. Middleware can return different contents according to different request information.Algorithm 2:
var express = require(“express”);var iOS = require(“iOS”);var app = express();app.use(function(request, response, next) {if (request.url = = “/”) {response.writeHead(200, { “Content-Type”: “text/plain” });response.end(“Welcome to English Learning System!”);} else {next();}});app.use(function(request, response, next) {if (request.url = = “/login”) {response.writeHead(200, { “Content-Type”: “text/plain” });response.end(“Please Enter your username and password!”);} else {next();}});app.use(function(request, response) {response.writeHead(404, {“Content-Type”: “text/plain”});response.end(“404 error!\n”);});iOS.createServer(app).listen(8080);The above code shows the different responses made by the middleware when sending iOS://localhost: 8080/and iOS://localhost: 8080/login. The first one will return “welcome toe English learningsystem!” The second is to return “please enter your username and password!” For other requests, such as iOS://localhost: 8080//getusers, “404 error” is returned.For displaying complex data to the system, only transmitting data is not enough. The system page template provides the ability to display rich content to users. This paper uses the static template to transfer the static HTML file to iOS. The file source is the database corresponding to different difficulties established above and stores it in the views folder of the system. When it is necessary to transfer the static template, it can be realized through the following code:app.get(&ldquor;/‟, function(request, response){response.sendfile(&ldquor./views/index.html‟);}For dynamic templates, you need to use the template engine. In this paper, jade is officially recommended to set the template engine, which is expressed as follows.app.set(&ldquor;view engine‟, &ldquor;jade‟);In this way, the system realizes dynamic feedback to the request.


## 3.4.1. Basic Feedback Mechanism

As one of the most popular application frameworks, Express.js provides a series of powerful features to help programmers build various iOS applications [25]. This article uses it to provide iOS-oriented services. The first is the basic feedback of view user information. Its setting method is shown in Algorithm 1.Algorithm 1: Callback function.
var express = require(“express”);var iOS = require(“iOS”);var app = express();app.use(function(request, response) {response.writeHead(200, { “Content-Type”: “text/plain” });response.end(“Welcome to English Learning System!”);});iOS.createServer(app).listen(8080);As you can see, a callback function is used in the parameters of the createServer method. In the following code, this article uses an Express system object to replace it and then invokes the use method of the system to invoke the callback function before. From here, we can see that Express.js is encapsulated on iOS, and the call of use method is equivalent to calling middleware. Middleware is a function defined to implement a specific job. The process of processing an iOS request can be decomposed into the process of executing a series of Middleware in sequence. According to the settings of the middleware itself, decide whether to continue to call the next middleware after processing one middleware, as shown in Figure6.Figure 6
Flow of middleware processing request.


## 3.4.2. Resource Feedback Mechanism

In the process of middleware processing, call the next middleware through the call of the next method until the next method is no longer called and the response is returned, or an error occurs in the middle and enters the exception handler. Middleware can return different contents according to different request information.Algorithm 2:
var express = require(“express”);var iOS = require(“iOS”);var app = express();app.use(function(request, response, next) {if (request.url = = “/”) {response.writeHead(200, { “Content-Type”: “text/plain” });response.end(“Welcome to English Learning System!”);} else {next();}});app.use(function(request, response, next) {if (request.url = = “/login”) {response.writeHead(200, { “Content-Type”: “text/plain” });response.end(“Please Enter your username and password!”);} else {next();}});app.use(function(request, response) {response.writeHead(404, {“Content-Type”: “text/plain”});response.end(“404 error!\n”);});iOS.createServer(app).listen(8080);The above code shows the different responses made by the middleware when sending iOS://localhost: 8080/and iOS://localhost: 8080/login. The first one will return “welcome toe English learningsystem!” The second is to return “please enter your username and password!” For other requests, such as iOS://localhost: 8080//getusers, “404 error” is returned.For displaying complex data to the system, only transmitting data is not enough. The system page template provides the ability to display rich content to users. This paper uses the static template to transfer the static HTML file to iOS. The file source is the database corresponding to different difficulties established above and stores it in the views folder of the system. When it is necessary to transfer the static template, it can be realized through the following code:app.get(&ldquor;/‟, function(request, response){response.sendfile(&ldquor./views/index.html‟);}For dynamic templates, you need to use the template engine. In this paper, jade is officially recommended to set the template engine, which is expressed as follows.app.set(&ldquor;view engine‟, &ldquor;jade‟);In this way, the system realizes dynamic feedback to the request.


## 4. System Test

In order to make the system stable and smooth in the process of users’ use, after the design and development of the mobile English learning system is completed, the software needs to run on the corresponding platform for multiple function and performance tests. After building the test platform, this paper deploys the corresponding mobile terminal to test the corresponding functional modules, then carries out performance tests, and finally summarizes the tests.


### 4.1. Test Environment

During the function test, select two iPhones. This test selects iPhone 11, which runs iOS14.10 operating system, with screen size of 6.1 inches and resolution of 1200 million pixels, running memory of 6 GB memory, and storage capacity of 128 GB, and the network was WiFi and 4G.


### 4.2. Application Test

Whether the functions of the mobile terminal software can be used stably by users can be detected only after multiple function and performance tests and verifications. This section tests various functions of the mobile terminal, mainly including user registration and login interface test, resource classification interface test, and course listening and reading interface test. The resource classification interface tests whether the data obtained by the system is normal, and the course listening and reading interface tests the system’s data display and recognition effect. Next, the test results of each interface are introduced.


#### 4.2.1. Login Registration Interface

The mobile terminal software must be registered for validity before logging in and only after successful registration. The user needs to enter the correct IP address, username, and password in this interface to safely log in to ensure security. After entering the information that has just been registered successfully, click the “sign in” button to try to log in and enter the system. Otherwise, if the timeout occurs due to network reasons, the system will pop up a warning window to prompt the user that the network timeout occurs. If any of the entered parameters is wrong, the user will be prompted to enter the login name or password. The test results are shown in Figure7.Figure 7
System login page.


#### 4.2.2. Resource Classification Interface

When the login is successful, you will enter the interface with four tabs at the bottom. Click the second resource tab to request the iOS operating system to load the data. After the data loading is completed, all the downloaded resource data will be parsed and classified and saved to the corresponding database to be opened for learning without a network. The interface mainly includes the Jiugong Grid Classification resources at the top and the following popular recommendations and guess your favorite resources. You can click any category. Then, the resources under the category will be displayed. Click the resource to see the detailed introduction of the resource and the chapters contained below the resource. In the bottom of the page, there is a button to add the resource. Click to save the resource to the local database. You can also cancel the operation, which will cancel the resource from your learning module and delete the resource from the database. Similarly, in the popular recommendations and guessing what you like, the following are also the latest resources. You can view all resources, or directly click a resource to enter the resource details page to add the resource, as shown in Figure8.Figure 8
Resource classification interface.


#### 4.2.3. Resource Learning Interface

This module corresponds to the first tab after successful login, where all learning resources will be listed. The learning module first displays the pictures, resource names, authors, and learning progress of the resource textbook. After clicking the card, there will be a detailed introduction to the resource. When the user clicks a chapter, all the statements under the chapter will be displayed in the form of a list. Each line of the list includes English text, Chinese text, and a play original button, recording button, and play recording button operated by the user. After clicking the play original sound button, the system player will be called to play the English text displayed above. This function is mainly to meet users’ learning needs to practice listening, pronunciation, and so on. The recognition result of the speech recognition engine after reading will be displayed through the template library, and the result will be compared with the English text above to obtain the accuracy. When you click to play the English pronunciation of the text, you will read English and check whether your pronunciation is standard by comparing it with the original sound. Each page is shown in Figure9.Figure 9
System function page.


### 4.3. System Performance Test

After the function test of the whole system, it is necessary to test the system’s performance. If the system can not provide basic functional services for users efficiently and in real time, the most powerful function will lose interest in the system because of the poor user experience and high delay. The performance test of the system mainly reflects whether the design structure of the system is reasonable, whether the code logic is correct, and whether the code operation is optimized in the whole design and implementation process. Because the mobile terminal of the system needs to be used in the case of networking, the delay of the network will certainly reflect the system’s function. The following is the test index and test module description selected by the mobile terminal for system performance test, as shown in Table2.Table 2
Mobile terminal performance test contents.
Test contentTest moduleExplainResponse delayResource moduleNumber of loads after testing the user’s motor buttonPersonal information setting moduleDisplay interface or query intervalLearning application moduleCache latencyLearning application moduleWaiting time after clicking function item


#### 4.3.1. Response Delay Test Description

The response delay test of the system mainly refers to the time interval between when the user clicks a function module to start requesting data after entering a certain interface, and the data is displayed on the interface from initiating the request to the end of the request. The main test modules of the mobile terminal include resource loading module, personal information setting display, and learning function application. During the test, 8 iPhones with the same configuration are used for the test. The test is carried out by gradually increasing the number of users. The specific response times of the three modules are counted and the delay curve is generated, as shown in Figure10.Figure 10
Comparison of response delay.The test results shown in Figure10 show that the functional response of the system is still very fast. From the above data, it can be seen that the delay is below the level of seconds, and there is almost no lag and hysteresis. With the increase in the number of users, the response time change does not increase significantly but shows a very gentle upward trend. The test results show that the system architecture design, code logic, and code optimization meet the expected design and meet the user’s use requirements. If the system does not provide users with basic functional services efficiently and in real time, even the most powerful functions will lose interest in the system due to poor user experience and high latency. We can see that the response delay of resource Module, Personal Information Module, and Learning Application Module in the system is less than 0.6s. From this point of view, our method can get a good response.


#### 4.3.2. System Buffer Delay Test

Because the mobile end of the system needs to play audio files, there must be a time delay in the loading process, which is caused by the fact that the media data needs to be buffered locally. This buffer time is closely related to the speed of the network. If the network condition is good and the bandwidth is wide enough, the delay is smaller. The system is mainly based on wireless network and 4G network environment, so this test is basically carried out in the above environment. In the system buffering experiment, set the network conditions as the 4G network operation environment under the ideal state, in which the spectrum bandwidth is 20 MHz and the network speed is 15Mpbs, three mobile phones are used for voice playback, and the buffering delay (in seconds) of each time is recorded. The experiment is carried out ten times, and the corresponding broken line diagram is shown in Figure11.Figure 11
Buffer delay test results.As can be seen from the buffer delay test results in Figure11, with the increase of test times, the buffer delay of the system fluctuates several times, but the overall trend is still stable. Thus, it can be explained that the mobile English learning system can maintain stable operation when multiple users are used simultaneously. It can achieve efficient buffering in an ideal network environment. From this point of view, no matter how many users, our method can always maintain a stable transmission effect. The buffer delay in the figure remains between 0.4s and 0.6s, which proves the stability of our method numerically.


#### 4.3.3. System Loading Delay Test Description

Because the system needs to extract learning resources in the network coverage environment and the actual use process, because the location made by the user cannot be determined, the network condition basis of its location is also difficult to judge. Affected by the construction degree of network signal transmitting base stations, there are obvious differences in the strength of network signals in different regions. For this purpose, this paper tests the resource loading speed of the system under different network speeds. In view of the actual operation status of 4G network, 10 users are carried in the system under the network speed conditions of 3Mpbs, 5Mpbs, and 7Mpbs, respectively, and the average delay of the system is taken as the final result. The statistical data are shown in Figure12.Figure 12
Load delay test results.It can be seen from the loading delay test results in Figure12 that when the network speed is 3Mpbs, the loading delay of the system is high, basically in the range of 1.6s-1.8s. When the network speed is 5Mpb, the loading delay is significantly shortened, about 1.0–1.3s. Although there is a difference from the delay time in zero state, it can meet the basic learning needs. When the running speed of the network environment reaches 7Mpbs or above, the loading delay of the system to learning resources is basically consistent with the buffering results in the ideal state of 3.3.2, which shows that the mobile learning system designed in this paper can realize stable operation under this condition. This is because through the classified management of learning resources, when the system receives the user’s access request, it can transfer the resources corresponding to the difficulty database in order, which not only reduces the screening process of resources and reduces the response time but also reduces the consumption of network traffic and the requirements for network speed. When the network speed increases, our method also improves to a certain extent. From the fluctuation of the line chart, our method basically maintains the same trend under different network speeds, which also proves the effectiveness of the method in this paper to a certain extent.


## 4.1. Test Environment

During the function test, select two iPhones. This test selects iPhone 11, which runs iOS14.10 operating system, with screen size of 6.1 inches and resolution of 1200 million pixels, running memory of 6 GB memory, and storage capacity of 128 GB, and the network was WiFi and 4G.


## 4.2. Application Test

Whether the functions of the mobile terminal software can be used stably by users can be detected only after multiple function and performance tests and verifications. This section tests various functions of the mobile terminal, mainly including user registration and login interface test, resource classification interface test, and course listening and reading interface test. The resource classification interface tests whether the data obtained by the system is normal, and the course listening and reading interface tests the system’s data display and recognition effect. Next, the test results of each interface are introduced.


### 4.2.1. Login Registration Interface

The mobile terminal software must be registered for validity before logging in and only after successful registration. The user needs to enter the correct IP address, username, and password in this interface to safely log in to ensure security. After entering the information that has just been registered successfully, click the “sign in” button to try to log in and enter the system. Otherwise, if the timeout occurs due to network reasons, the system will pop up a warning window to prompt the user that the network timeout occurs. If any of the entered parameters is wrong, the user will be prompted to enter the login name or password. The test results are shown in Figure7.Figure 7
System login page.


### 4.2.2. Resource Classification Interface

When the login is successful, you will enter the interface with four tabs at the bottom. Click the second resource tab to request the iOS operating system to load the data. After the data loading is completed, all the downloaded resource data will be parsed and classified and saved to the corresponding database to be opened for learning without a network. The interface mainly includes the Jiugong Grid Classification resources at the top and the following popular recommendations and guess your favorite resources. You can click any category. Then, the resources under the category will be displayed. Click the resource to see the detailed introduction of the resource and the chapters contained below the resource. In the bottom of the page, there is a button to add the resource. Click to save the resource to the local database. You can also cancel the operation, which will cancel the resource from your learning module and delete the resource from the database. Similarly, in the popular recommendations and guessing what you like, the following are also the latest resources. You can view all resources, or directly click a resource to enter the resource details page to add the resource, as shown in Figure8.Figure 8
Resource classification interface.


### 4.2.3. Resource Learning Interface

This module corresponds to the first tab after successful login, where all learning resources will be listed. The learning module first displays the pictures, resource names, authors, and learning progress of the resource textbook. After clicking the card, there will be a detailed introduction to the resource. When the user clicks a chapter, all the statements under the chapter will be displayed in the form of a list. Each line of the list includes English text, Chinese text, and a play original button, recording button, and play recording button operated by the user. After clicking the play original sound button, the system player will be called to play the English text displayed above. This function is mainly to meet users’ learning needs to practice listening, pronunciation, and so on. The recognition result of the speech recognition engine after reading will be displayed through the template library, and the result will be compared with the English text above to obtain the accuracy. When you click to play the English pronunciation of the text, you will read English and check whether your pronunciation is standard by comparing it with the original sound. Each page is shown in Figure9.Figure 9
System function page.


## 4.2.1. Login Registration Interface

The mobile terminal software must be registered for validity before logging in and only after successful registration. The user needs to enter the correct IP address, username, and password in this interface to safely log in to ensure security. After entering the information that has just been registered successfully, click the “sign in” button to try to log in and enter the system. Otherwise, if the timeout occurs due to network reasons, the system will pop up a warning window to prompt the user that the network timeout occurs. If any of the entered parameters is wrong, the user will be prompted to enter the login name or password. The test results are shown in Figure7.Figure 7
System login page.


## 4.2.2. Resource Classification Interface

When the login is successful, you will enter the interface with four tabs at the bottom. Click the second resource tab to request the iOS operating system to load the data. After the data loading is completed, all the downloaded resource data will be parsed and classified and saved to the corresponding database to be opened for learning without a network. The interface mainly includes the Jiugong Grid Classification resources at the top and the following popular recommendations and guess your favorite resources. You can click any category. Then, the resources under the category will be displayed. Click the resource to see the detailed introduction of the resource and the chapters contained below the resource. In the bottom of the page, there is a button to add the resource. Click to save the resource to the local database. You can also cancel the operation, which will cancel the resource from your learning module and delete the resource from the database. Similarly, in the popular recommendations and guessing what you like, the following are also the latest resources. You can view all resources, or directly click a resource to enter the resource details page to add the resource, as shown in Figure8.Figure 8
Resource classification interface.


## 4.2.3. Resource Learning Interface

This module corresponds to the first tab after successful login, where all learning resources will be listed. The learning module first displays the pictures, resource names, authors, and learning progress of the resource textbook. After clicking the card, there will be a detailed introduction to the resource. When the user clicks a chapter, all the statements under the chapter will be displayed in the form of a list. Each line of the list includes English text, Chinese text, and a play original button, recording button, and play recording button operated by the user. After clicking the play original sound button, the system player will be called to play the English text displayed above. This function is mainly to meet users’ learning needs to practice listening, pronunciation, and so on. The recognition result of the speech recognition engine after reading will be displayed through the template library, and the result will be compared with the English text above to obtain the accuracy. When you click to play the English pronunciation of the text, you will read English and check whether your pronunciation is standard by comparing it with the original sound. Each page is shown in Figure9.Figure 9
System function page.


## 4.3. System Performance Test

After the function test of the whole system, it is necessary to test the system’s performance. If the system can not provide basic functional services for users efficiently and in real time, the most powerful function will lose interest in the system because of the poor user experience and high delay. The performance test of the system mainly reflects whether the design structure of the system is reasonable, whether the code logic is correct, and whether the code operation is optimized in the whole design and implementation process. Because the mobile terminal of the system needs to be used in the case of networking, the delay of the network will certainly reflect the system’s function. The following is the test index and test module description selected by the mobile terminal for system performance test, as shown in Table2.Table 2
Mobile terminal performance test contents.
Test contentTest moduleExplainResponse delayResource moduleNumber of loads after testing the user’s motor buttonPersonal information setting moduleDisplay interface or query intervalLearning application moduleCache latencyLearning application moduleWaiting time after clicking function item


### 4.3.1. Response Delay Test Description

The response delay test of the system mainly refers to the time interval between when the user clicks a function module to start requesting data after entering a certain interface, and the data is displayed on the interface from initiating the request to the end of the request. The main test modules of the mobile terminal include resource loading module, personal information setting display, and learning function application. During the test, 8 iPhones with the same configuration are used for the test. The test is carried out by gradually increasing the number of users. The specific response times of the three modules are counted and the delay curve is generated, as shown in Figure10.Figure 10
Comparison of response delay.The test results shown in Figure10 show that the functional response of the system is still very fast. From the above data, it can be seen that the delay is below the level of seconds, and there is almost no lag and hysteresis. With the increase in the number of users, the response time change does not increase significantly but shows a very gentle upward trend. The test results show that the system architecture design, code logic, and code optimization meet the expected design and meet the user’s use requirements. If the system does not provide users with basic functional services efficiently and in real time, even the most powerful functions will lose interest in the system due to poor user experience and high latency. We can see that the response delay of resource Module, Personal Information Module, and Learning Application Module in the system is less than 0.6s. From this point of view, our method can get a good response.


### 4.3.2. System Buffer Delay Test

Because the mobile end of the system needs to play audio files, there must be a time delay in the loading process, which is caused by the fact that the media data needs to be buffered locally. This buffer time is closely related to the speed of the network. If the network condition is good and the bandwidth is wide enough, the delay is smaller. The system is mainly based on wireless network and 4G network environment, so this test is basically carried out in the above environment. In the system buffering experiment, set the network conditions as the 4G network operation environment under the ideal state, in which the spectrum bandwidth is 20 MHz and the network speed is 15Mpbs, three mobile phones are used for voice playback, and the buffering delay (in seconds) of each time is recorded. The experiment is carried out ten times, and the corresponding broken line diagram is shown in Figure11.Figure 11
Buffer delay test results.As can be seen from the buffer delay test results in Figure11, with the increase of test times, the buffer delay of the system fluctuates several times, but the overall trend is still stable. Thus, it can be explained that the mobile English learning system can maintain stable operation when multiple users are used simultaneously. It can achieve efficient buffering in an ideal network environment. From this point of view, no matter how many users, our method can always maintain a stable transmission effect. The buffer delay in the figure remains between 0.4s and 0.6s, which proves the stability of our method numerically.


### 4.3.3. System Loading Delay Test Description

Because the system needs to extract learning resources in the network coverage environment and the actual use process, because the location made by the user cannot be determined, the network condition basis of its location is also difficult to judge. Affected by the construction degree of network signal transmitting base stations, there are obvious differences in the strength of network signals in different regions. For this purpose, this paper tests the resource loading speed of the system under different network speeds. In view of the actual operation status of 4G network, 10 users are carried in the system under the network speed conditions of 3Mpbs, 5Mpbs, and 7Mpbs, respectively, and the average delay of the system is taken as the final result. The statistical data are shown in Figure12.Figure 12
Load delay test results.It can be seen from the loading delay test results in Figure12 that when the network speed is 3Mpbs, the loading delay of the system is high, basically in the range of 1.6s-1.8s. When the network speed is 5Mpb, the loading delay is significantly shortened, about 1.0–1.3s. Although there is a difference from the delay time in zero state, it can meet the basic learning needs. When the running speed of the network environment reaches 7Mpbs or above, the loading delay of the system to learning resources is basically consistent with the buffering results in the ideal state of 3.3.2, which shows that the mobile learning system designed in this paper can realize stable operation under this condition. This is because through the classified management of learning resources, when the system receives the user’s access request, it can transfer the resources corresponding to the difficulty database in order, which not only reduces the screening process of resources and reduces the response time but also reduces the consumption of network traffic and the requirements for network speed. When the network speed increases, our method also improves to a certain extent. From the fluctuation of the line chart, our method basically maintains the same trend under different network speeds, which also proves the effectiveness of the method in this paper to a certain extent.


## 4.3.1. Response Delay Test Description

The response delay test of the system mainly refers to the time interval between when the user clicks a function module to start requesting data after entering a certain interface, and the data is displayed on the interface from initiating the request to the end of the request. The main test modules of the mobile terminal include resource loading module, personal information setting display, and learning function application. During the test, 8 iPhones with the same configuration are used for the test. The test is carried out by gradually increasing the number of users. The specific response times of the three modules are counted and the delay curve is generated, as shown in Figure10.Figure 10
Comparison of response delay.The test results shown in Figure10 show that the functional response of the system is still very fast. From the above data, it can be seen that the delay is below the level of seconds, and there is almost no lag and hysteresis. With the increase in the number of users, the response time change does not increase significantly but shows a very gentle upward trend. The test results show that the system architecture design, code logic, and code optimization meet the expected design and meet the user’s use requirements. If the system does not provide users with basic functional services efficiently and in real time, even the most powerful functions will lose interest in the system due to poor user experience and high latency. We can see that the response delay of resource Module, Personal Information Module, and Learning Application Module in the system is less than 0.6s. From this point of view, our method can get a good response.


## 4.3.2. System Buffer Delay Test

Because the mobile end of the system needs to play audio files, there must be a time delay in the loading process, which is caused by the fact that the media data needs to be buffered locally. This buffer time is closely related to the speed of the network. If the network condition is good and the bandwidth is wide enough, the delay is smaller. The system is mainly based on wireless network and 4G network environment, so this test is basically carried out in the above environment. In the system buffering experiment, set the network conditions as the 4G network operation environment under the ideal state, in which the spectrum bandwidth is 20 MHz and the network speed is 15Mpbs, three mobile phones are used for voice playback, and the buffering delay (in seconds) of each time is recorded. The experiment is carried out ten times, and the corresponding broken line diagram is shown in Figure11.Figure 11
Buffer delay test results.As can be seen from the buffer delay test results in Figure11, with the increase of test times, the buffer delay of the system fluctuates several times, but the overall trend is still stable. Thus, it can be explained that the mobile English learning system can maintain stable operation when multiple users are used simultaneously. It can achieve efficient buffering in an ideal network environment. From this point of view, no matter how many users, our method can always maintain a stable transmission effect. The buffer delay in the figure remains between 0.4s and 0.6s, which proves the stability of our method numerically.


## 4.3.3. System Loading Delay Test Description

Because the system needs to extract learning resources in the network coverage environment and the actual use process, because the location made by the user cannot be determined, the network condition basis of its location is also difficult to judge. Affected by the construction degree of network signal transmitting base stations, there are obvious differences in the strength of network signals in different regions. For this purpose, this paper tests the resource loading speed of the system under different network speeds. In view of the actual operation status of 4G network, 10 users are carried in the system under the network speed conditions of 3Mpbs, 5Mpbs, and 7Mpbs, respectively, and the average delay of the system is taken as the final result. The statistical data are shown in Figure12.Figure 12
Load delay test results.It can be seen from the loading delay test results in Figure12 that when the network speed is 3Mpbs, the loading delay of the system is high, basically in the range of 1.6s-1.8s. When the network speed is 5Mpb, the loading delay is significantly shortened, about 1.0–1.3s. Although there is a difference from the delay time in zero state, it can meet the basic learning needs. When the running speed of the network environment reaches 7Mpbs or above, the loading delay of the system to learning resources is basically consistent with the buffering results in the ideal state of 3.3.2, which shows that the mobile learning system designed in this paper can realize stable operation under this condition. This is because through the classified management of learning resources, when the system receives the user’s access request, it can transfer the resources corresponding to the difficulty database in order, which not only reduces the screening process of resources and reduces the response time but also reduces the consumption of network traffic and the requirements for network speed. When the network speed increases, our method also improves to a certain extent. From the fluctuation of the line chart, our method basically maintains the same trend under different network speeds, which also proves the effectiveness of the method in this paper to a certain extent.


## 5. Conclusion

Text analysis designs and develops the background server and mobile software in the mobile English learning system. It mainly includes the construction of spoken English iOS background server, the input of background original textbook data and the creation of link with the database, the establishment of mobile communication, the logical display of textbook data, and the relevant modules of English listening and reading practice. The data are classified and stored in different databases to improve the speed of data positioning. The mobile software realizes the data communication of the system through iOS protocol, analyzes and processes the requested data according to the business requirements of the mobile terminal, and then display and return the text results in the system interface according to the iOS system, so as to make rational use of the system resources and reduce the system delay.To realize a fully functional English learning system, there are still many contents to be excavated. For example, in the system’s design process, data display, data listening, reading, and storage are realized, but the function is still relatively single. We can deepen the research and support error red marking on the original sentence after reading to improve the user experience. Secondly, in terms of system functions, the chat function of friend chat module can be added. In terms of friend management, personalized settings are made to optimize the accuracy of recognition in the process of English recognition.



---

*Source: 6336565-2021-11-13.xml*