Real‐time detection of aerobics posture based on strain sensor

The Internet of Things is a network that realizes the intelligent connection between things. It is another major industry after the computer industry and the Internet industry. It is also a collection of computer technology, communication technology, sensor technology, storage technology, and many other leading technologies in an integrated industry, the application industry is very wide. This article mainly introduces the real-time detection of aerobics posture based on strain sensors. This paper proposes a real-time detection method of motion posture based on strain sensors, using flexible rods to simulate the joints of aerobics athletes. Through the survey of the motion posture by the strain sensor, the relevant data and parameters are collected, and then the data are processed, and the data are finally transmitted to the terminal. Since the stress of a specific point on the surface of the flexible rod is proportional to the curve of that point, strain gauges can be used to detect curve changes at multiple points in real time and draw the change curve on the computer. The experimental structure of this paper shows that the use of BP neural network to process the measurement data improves the accuracy of real-time detection. The error distance between the sampling point and the actual value is less than 0.3 cm. In addition, through the real-time detection of the motion posture, it can be concluded that good Body posture is the basic requirement of aerobics, and it is of great significance to improve the effect of improving the quality of movement and artistic expression.

Body posture refers to the external performance of various parts of the body, such as the head, upper limbs, trunk, and lower limbs, during the movement. Aerobics belongs to the skill-led category of difficult-to-beauty performance. It requires practitioners to have strong physical control. However, in exercise, aerobic exercise belongs to the skill-oriented category, and aerobic exercise requires the operator to have strong physical control. Good body posture is the basic requirement of aerobics and the key to the performance of "health, strength, and beauty" in aerobics. It is of great significance to improve the effect of improving the quality of movement and artistic expression.
By introducing wave-shaped fluid channels (reducing hysteresis through viscoelastic relaxation of elastomers), the hysteresis performance of ionic liquid-based sensors can be improved. From the simulation of the visco-superelastic behavior of the elastomer channel, Choi D Y proved that the wave-shaped structure can provide lower energy dissipation than the planar structure under a given deformation. The resistance response of the ionic liquid-based wave (ILBW) sensor is deterministic, has no hysteresis, and closely matches the theoretically estimated curve. However, due to the high complexity of the data, the error will be relatively large [1]. The introduction of the wavy fluid channel can improve the hysteresis performance of the liquid sensor, which is of great help to the timeliness of the sensor, but this article does not use a liquid sensor. The application of computing and communication intelligence has effectively improved the monitoring and control quality of smart grids. He Y uses deep learning technology to use historical measurement data and usage to determine the behavioral characteristics of foreign direct investment attacks and to detect FDI attacks in real time. In this way, the detection mechanism he proposed effectively relaxes the assumption of possible attack scenarios and achieves a high accuracy rate. In addition, he proposed an optimization model to characterize the behavior of an FDI attack, which damages the limited number of state measurements performed by the power system due to power theft. However, the effect of this behavior is not very effective [2]. The Internet of Things (IoT) is a dynamic global information network composed of objects connected to the Internet, which have become an integral part of the Internet in the future. Perera C surveyed more than one hundred IoT smart solutions on the market and carefully checked them to identify the technologies, functions and applications used. Based on the application field, he classified these solutions into five categories: (1) smart wearable devices; (2) smart wearable devices. (3) Smart city; (4) Smart environment; (5) Smart enterprise. This survey is intended to serve as a guide and conceptual framework for future research on the Internet of Things to inspire and inspire further development. However, due to certain errors in the survey, the results will not be so accurate [3].Through the combination of the Internet of Things and smart wearable devices, this article will design a smart wearable device that can be combined through the Internet of Things to design and analyze the posture of aerobics.
The innovation of this article lies in (1) Through the detection of aerobics exercise posture, it is analyzed that the body posture training should be grasped from all parts of the body to be targeted. In the exercises, the standard of movement is required, from simple to complex, step by step, In order to form a good body posture. (2) Real-time receipt of aerobics posture through the strain sensor, and then return to the terminal after processing. The use of strain sensors can make the data more time-sensitive, and the final picture of aerobics postures will be clearer. The most important thing is that its noise reduction ability is very efficient. (3) Summarize the basic theory of human body posture measurement, inertial navigation and posture calculation, and design the human body motion posture measurement program.

Euler angle method
Euler's theorem states that the position of a rigid body after rotating around a fixed point in space can be obtained after a limited number of rotations. In the definition of Euler rotation, the motion of a rigid body in space is decomposed into three rotations around three specific coordinate axes, and the angle of the three rotations is the Euler angle [4]. Suppose that the coordinate system OX 0 Y 0 Z 0 is rotated and transformed to obtain the coordinate system OX 1 Y 1 Z 1 . Equation (1) describes the detailed process of three rotations. The brackets indicate that a new coordinate system is obtained by rotating a certain angle around a certain axis, and finally, a coordinate system with the same origin as the OX 0 Y 0 Z 0 origin is formed [5].
In order to facilitate the use of mathematical formulas to express the rotation process and improve the efficiency of calculations, Euler angles are usually transformed into a rotation matrix or a quaternion form [6]. The posture matrix determined by Euler angles can be decomposed into three basic rotation matrices and multiplied in sequence. These three basic coordinate transformation matrices are called the main rotation matrix and are defined in the following standard form: Rotate angle a around X axis: Rotate angle b around Y axis: Rotation angle c around the Z axis: The determining factors of the attitude matrix also include the rotation order. When the navigation sequence is used to express Euler angles, the zyx rotation order is often used, that is, the carrier coordinate system is rotated around the z-axis, y-axis, and x-axis in turn, and the rotation is generated. The three angles are the Euler angles [7].
(1) Rotation matrix method: The more classic method used to describe the Euler angle rotation process is the rotation matrix method. Equations (2)-(4) define three kinds of rotation matrices obtained by rotating around different rotation axes, called the main rotation matrix [8]. When a rigid body rotates in space, the position after rotation can be calculated by the product of the three main rotation matrices, which is the attitude rotation matrix. The rotation matrix is usually a 3*3 matrix [9]. (2) Quaternion method: The quaternion method is the most commonly used pose description method. The quaternion is composed of four elements, including a scalar element and three vector elements [10]. The basic form of quaternion is: where e x , e y , e z , respectively, represent the projection components of the vector e on the three axes of the coordinate system oxyz, and θ is the rotation angle. A quaternion is composed of two parts, a real number and three elements, and can be divided into scalar and vector parts. A quaternion can be expressed by the following formula, namely:

Basic requirements of aerobics posture
(1) Head posture: The head posture is the key to the charm of the action, and it is also an important part of the body posture. It is coordinated with the action of the body posture, and then matched with the facial expression to achieve the beauty of aerobics and posture [11].  relaxed, the arms should be straight, and the amplitude should be large; when the shoulders are shaken, there must be speed, strength, and flexibility [13]. There are many kinds of arm movements, and the correct arm posture plays an important role in the perfection of the whole body posture and the artistic style of movements. Arm posture: arm movements are composed of lifting, flexion and extension, swing, winding, looping, and vibration. When doing arm movements, the parts are required to be accurate, the route is clear, the amplitude is in place, the strength is appropriate, and the ability to control is strong [14]. Hand posture: The hand is the extension and performance of the arm. Hand types include palm (joint palm, open palm, flower palm, standing palm) and punch (solid punch, hollow punch). The change of hand shape cannot only make the arm movements more colorful and lively and show the beauty, but also help to strengthen the strength of the movements [15]. Hand posture requirements: When making a parallel palm, the thumb is buckled inward; when holding a hollow fist, the thumb contacts the index finger and the middle finger to form a ring, the other fingers are gently bent into a natural posture, and the palm is empty. The hand shape should change obviously in the complete set of movements, the transition should be natural, and the posture should be graceful [16].

A R T I C L E
(3) Trunk posture: The torso is the most expressive part of aerobics. The torso is composed of chest, abdomen, waist, back, hips, and hips. In aerobics, the requirements of the trunk posture: stand up chest, tuck in abdomen, stand up waist, let the whole person stand upright on a vertical line, make the movements clear and rapid, and maintain the stability and integrity of the body. The stability of the body refers to the support of the abdominal and back muscles, which directly affects the completion of the complete set of actions [17]. (4) Lower limb posture: All feet that leave the ground and do a certain short stay (except for big kicks) require the instep to be stretched; when kicking, the feet are in a natural state and the ankle joints relax [18].

Real-time detection method of motion posture
The dyskinesia caused by cerebral palsy is significantly different from that of healthy people, and the dyskinesia caused by different degrees of injury also has its own characteristics [19]. The limb movement monitoring based on dynamic sensors uses different sensors to measure the dynamic movement of the limbs relative to the spatial sensor field. For example, accelerometer, magnetometer, etc. It is used for dynamic measurement of polar axis components and speeds such as gravity field and geomagnetic field. And transmit it to the computer of the system through communication, and then perform data processing and motion resolution analysis [20]. This project plans to use a combination of three-dimensional micro-electromechanical sensors to realize human posture detection in three-dimensional space. Among them, the three-dimensional microelectromechanical sensor combination is composed of a three-axis accelerometer and a three-axis magnetometer. It is applied to the coordinate axes of three orthogonal coordinate systems in the sensitive three-dimensional space  [21]. The movement of the human body is actually the relative movement between the edges, and each movement position is a combination of adjacent spatial angles. A threeaxis acceleration sensor should be used to measure the linear acceleration of the edge motion. The speed and displacement of the edge motion can be achieved by integration, so the relative position of the end relative to the initial torque can be taken [22]. A magnetometer is a sensor that measures the position of limbs based on the earth's magnetic field. The magnetometer itself is used to measure the power of the magnetic field in the space environment. Since the earth's magnetic field model can predetermine the magnetic field force at various points around the earth, the information measured from the end magnetometer can be compared with it to determine the position of the end of the magnetometer relative to the earth's magnetic field [23].

Gesture recognition algorithm
Canny is a technology that extracts useful structural information from different optical objects. It can also reduce the amount of data in image processing [24]. It is widely used in various machine vision systems. Canny believes that various vision systems have roughly the same requirements for edge detection, so an edge detection method that can solve these requirements can be widely used in various situations [25]. Generally, there are the following criteria for edge detection: (1) Optimal detection: That is, the detection should accurately detect as much edge information as possible in the picture. (2) The edge point corresponds to the detection point one-to-one: that is, the detected edge point should accurately fall on the center position of the edge point [26]. (3) The edge detected in the image should only be marked once, and the noise of the image will not affect the edge detection, resulting in error information. In order to meet these requirements Canny uses the variational method, a method of finding functions that optimize specific functions. In the Canny operator, this optimized function is represented by four exponential function terms, which are close to a derivative of the Gaussian function [27].
The realization of Canny operator can be divided into 4 steps: (1) Smooth the picture to achieve the purpose of filtering out noise Since image noise is the most important factor affecting the image, the same is true for the effect of image edge detection. In order to prevent edge detection from making mistakes, the noise of the image must first be removed as much as possible. The Gaussian filter is used to smooth the picture. Use Gaussian filter and image convolution to smooth the image. This step is to slightly smooth the image to reduce the effect of obvious noise [28]. The Gaussian filter kernel formula can be expressed as: Here you need to select a 5 × 5 Gaussian filter, θ = 1 , to perform convolution with the image:

A R T I C L E
Among them, B represents the image matrix, and * represents the convolution operation. (2) Non-maximum suppression Through the previous steps, the boundary of the image will become blurred. In order to make the boundary clear, a non-maximum suppression method is used. Generally speaking, it is to compare the gradient values of adjacent points in the gradient direction of this point in the picture, and only keep the maximum value points [29].

(3) Double threshold detection
In order to further solve the noise in the image, two thresholds are set for the image. The usual approach is to choose a high threshold and a low threshold. The end pixel rating is compared with these two thresholds. Points above the defined upper limit are marked as strong edge pixels, points below the high threshold and above the low threshold are marked as weak edge pixels, and points below the low threshold are marked as weak pixels.

Measuring principle
When the conductor or semiconductor material is mechanically deformed under the action of external force, its resistance value also changes. This phenomenon is called "strain phenomenon". Strain sensors made of strain effect have been widely used in measuring force, moment, pressure, curvature, acceleration, weight, and other parameters. Because the flexible rod can simulate the joints of athletes, the detection of the athlete's joint motion posture is actually the shape detection of the flexible rod. The change of a certain point on the flexible rod can be obtained by detecting the change of curvature of this point, and the curvature change of this point can be measured in real time with a strain gauge.

System composition
The whole system is composed of flexible base, strain gauge, bridge circuit, supporting circuit, AD card, and computer. The voltmeter should be symmetrically connected to the top and bottom of the flexible base and form a double-arm bridge with the other two equivalent resistors. After strengthening the output voltage of the electric bridge, it is collected from the computer in real time through the AD card, and the curvature of the flexible base rod is calculated, and the shape curve is drawn according to the curvature. The system composition is shown in Fig. 1.

Design of motion posture system
(1) Bridge circuit The main function of the bridge circuit is to convert the weak tilt signal into a voltage signal. At the same time, it can also eliminate the influence of tension, compression and tilt on the bending signal, so that only the net signal of bending can be measured.
When the flexible foundation rod is bent, the pressure gauge on the upper surface of the flexible foundation rod should be lengthened and the pressure gauge on the lower surface should be compressed. Since the voltmeters are arranged symmetrically, the  resistance changes of the upper and lower voltmeters are equal and opposite in polarity. Therefore, the output voltage of the bridge circuit is:

R E T R A C T E D A R T I C L E
In the formula, U is the bridge output voltage; U x is the input voltage; R is the change in the resistance of the strain gauge.
For strain gauges: In the formula, k 1 is the sensitivity coefficient of the strain gauge; ξ is the strain of the strain gauge; L, L is the length change and original length of the strain gauge when the strain gauge generates strain. Therefore: When the flexible base rod is tensioned and compressed, the voltmeters on the upper and lower surfaces are under pressure and pressure, so the changed value is the same, and the polarity is also the same. Therefore, the output voltage value of the bridge circuit is zero. Similarly, when the flexible base rotates, the upper and lower voltmeters are drawn at the same time, the change value is the same, the polarity is the same, and the bridge output voltage is also 0. Therefore, each group of voltmeters can eliminate the influence of the voltage signal, and only measure the tilt signal through the pressure and distortion after the bridge circuit.

(2) Output voltage and curvature
Because the elastic coefficient of the pressure gauge, the adhesive and the elastic coefficient of the flexible base rod are inconsistent, the voltage value of the pressure gauge is not equal to the stress of the flexible base. However, when the three tires are stable, the strain of the filter must be proportional to the strain of the flexible base rod, namely: In the formula, k 2 is the proportional coefficient; ξ 1 is the strain of the flexible rod. And the strain of the flexible base rod: where r is the radius of the flexible rod; d is the radius of curvature of the flexible rod at a certain point. Therefore: (3) Determination of proportional coefficient

R E T R A C T E D A R T I C L E
It can also be seen from Eq. (16) that if the value can be determined, the curvature of this point can be obtained through the bridge output voltage. There are many factors that affect performance, such as casting process, grid, etc. Especially the influence of certain side effects, it is difficult to use direct theoretical methods. Therefore, the scale factor in the formula should be used. Get the calibration method. The specific calibration method in the test system is: for each voltage group, first measure the output voltage of the flexible base rod bridge circuit under multiple known curve radii, and calculate each K according to Eq. (16), and then calculate. The average value is used as the scale factor for each pressure group. In this article, the output voltage of the flexible base rod when the bending radius is infinite (straight line), 100, 90, 80, 60, 40, 30, and 20 cm is measured to calibrate the coefficient.

Posture detection analysis based on strain sensor
The joint rotation angle model and the bone motion position model can be used to obtain the space position coordinates of the joint point relative to the parent joint point and the bone rotation angle during walking, and the leg motion trajectory simulation can be obtained through MATLAB. This experiment is mainly to verify the accuracy of the root node displacement estimation algorithm based on support leg detection and analyze the spatial position of the joint points in the walking cycle.
In the absence of root node displacement estimation, the coordinates of the root node are always the origin coordinates. The simulation trajectory of the left and right leg movements on MATLAB is shown in Fig. 2 (purple represents the hip joint, green represents the hip joint and knee joint, and orange represents the ankle joint). The three sets of line segments from top to bottom represent femur, tibia, and foot, respectively. From the data analysis in the figure, it can be concluded that since the coordinate position of the root node (hip joint) cannot be updated in real time, the root node cannot move when the leg completes the walking motion and cannot accurately reproduce the true trajectory of a step.
The experiment established a human root node displacement estimation algorithm based on the leg kinematics model, mainly to reflect the displacement of the root node when the human body walks more truly. Using the experimental data of the simulation Fig. 2 The trajectory of the rootless node displacement algorithm  Fig. 2, after adding the leg root node displacement estimation algorithm, the movement trajectories of the left and right legs in a cycle of walking have obvious changes. It can be seen more intuitively from the figure that the angle of each bone changes with the movement and the position coordinates of each joint in space. After adding the root node displacement estimation algorithm, according to the detection of the legs and the rotation angle of each joint, the displacement of the root node on the horizontal plane and the projection coordinates on the xoy plane can be derived.

Fitting analysis of flexible rod shape curve
When the flexible foundation rod only moves on a horizontal surface, only a set of voltmeters is needed to detect the curvature of each point. The shape curve of the flexible rod is reconstructed according to the curve of the discrete points in the flexible foundation rod. Recursive interpolation from the starting point can be used to reconstruct the plane curve. Take 7 points on the flexible base rod by recursive interpolation, as shown in Fig. 3 ("x" in Fig. 4 represents the actual position of the detection point, and "·" represents the position of the detection data).
It can be seen from the figure that after the base rod is bent, the test result of the shape curve of the flexible base rod in a flat state is shown as the dotted line in the figure. The curve is similar to the actual curve of the flexible base rod, but when used in some special occasions, it needs to be processed by an improved BP neural network. If higher accuracy is required, it will not meet the requirements, as shown in the second and third, Four, five, and seven. The results of the detection data on the detection point and the distance error with the actual coordinate are shown in Table 1.
The results show that after the improved BP neural network is used, the measurement error of the distance between the detection point and the actual value is reduced from 0.07 to 0.02 cm, and the measurement error after the entire BP network processing is no more than 0.03 cm, the accuracy of the measurement has been greatly improved. If the flexible base rod moves in space, each detection point needs two sets of voltmeters placed perpendicular to each other to detect the two mutually perpendicular curves of the element and then combine them into the curvature direction of each point. The curve shape can also adopt the interpolation recursive method, and use the vector method to find the space coordinates of each interference point. Finally, these interfaces are connected and deformed on the space curve.

Influencing factors of acceleration motion on attitude calculation accuracy
One of the accelerometers is a three-axis accelerometer. Similarly, it is based on the basic principle of acceleration. Acceleration is a space vector. On the one hand, to accurately understand the motion state of an object, you must measure its three coordinate axes. On the other hand, when the direction of movement of the object is not known in advance, only the three-axis acceleration sensor is used to detect the acceleration signal. Since the three-axis acceleration sensor is also based on the principle of gravity, the three-axis acceleration sensor can be used to achieve dual-axis plus or minus 90 degrees or dualaxis 0-360 degrees inclination. The accuracy of the post-correction is higher than that of the dual-axis acceleration sensor. The measurement angle is The 60-degree situation. The linear acceleration generated in free motion will affect the accuracy of attitude calculation. This paper uses horizontal sliding experiments to verify the filtering effect of the algorithm under linear acceleration. Place the attitude test unit on the surface of the water platform, drag it back and forth horizontally, and use CF and AHF to merge the data. Figure 4 shows the measured values of the three-axis accelerator in sliding motion.
Since the sideslip motion only produces linear acceleration on the x and y axes, only the pitch angle and roll angle accuracy need to be discussed. Therefore, through experiments, this article produces Fig. 5, which is a simulation diagram of the four algorithms for the estimation of the pitch and roll angles in the side-slip motion state. Among the largest errors in the evaluation, the pitch and roll angles of the EKF algorithm rank third and second. When sliding horizontally, the ideal value of the pitch and roll angles is 0 degrees. The CF algorithm has the worst filtering effect on linear acceleration, and the maximum errors of pitch angle and roll angle are 23 degrees and 44 degrees, respectively. The GDA numbers are 10 degrees and 10.4 degrees, and the algorithm in this paper is 2 degrees and 2.2 degrees, respectively. In summary, EKF and the algorithm in this paper can effectively filter out the influence of linear acceleration. Perform 10 static and dynamic tests, respectively. Table 2 shows the average statistics of the RMSE of the attitude angles calculated by different algorithms in multiple experiments. According to the data analysis in the figure and table, in the static state, there is no magnetic interference. The algorithm proposed in this paper can effectively suppress the movement of the unit's three-axis gyroscope and keep it stable. The average RMSE value of the attitude angle is less than 0.5. In a magnetic field environment, the AHF algorithm has a good influence on the azimuth angle and has a better compensation function to avoid the influence on the heading. Its average RMSE is less than 1. In a dynamic environment, AHF can accurately output three attitude angles with a maximum error of less than 2, ensuring that the human body's motion captures accurate system attitude information.

Results and discussion section
This paper adopts the real-time detection method of motion posture based on strain sensor, collects relevant data and parameters through the survey of motion posture by strain sensor, and then processes the data, and finally transmits the data to the terminal. This method is not only simple to implement and low in cost, but also capable of detecting the plane or spatial shape of the rod-shaped flexible body with high accuracy. Simple and practical technical means are provided in fields such as sports training and robotic arm motion trajectory tracking.
The design goal of this paper is the design of motion posture detection system based on strain sensor. According to the design goals, the overall design of the system block diagram was first carried out. According to the top-down thinking, the overall work was divided into modules, and then the information was searched and summarized, and the design direction was constantly revised. I searched a lot of information, including the selection and comparison of accelerometers, and the fusion algorithm of common attitudes at home and abroad, the result is that the fusion algorithm in this paper is more efficient in obtaining aerobics posture.
The detection of human motion is of great significance to human production and life. It occupies an important position in the fields of engineering, medicine, bionics, and computer graphics. The investigation of human motion has attracted great attention from researchers. However, due to the complexity of the human body structure, the flexibility of human movement and the multidisciplinary interdisciplinary nature of human movement research, the research work has become difficult. Although this dissertation has done a lot of work, the human body motion posture detection system is an ascendant subject, which involves a wide range of knowledge.

Authors' contributions
Shanshan Zhu: Writing-editing; Data analysis. The author read and approved the final manuscript.

Funding
The author(s) received no financial support for the research, authorship, and/or publication of this article.

Availability of data and materials
Data sharing does not apply to this article because no data set was generated or analyzed during the current research period.

Declarations Ethics approval and consent to participate
This article is ethical, and this research has been agreed.

Consent for publication
The picture materials quoted in this article have no copyright requirements, and the source has been indicated.

Competing interests
The authors declare that they have no competing interests.