Research Article
Design and Simulation of Lightweight Identity Authentication Mechanism in Body Area Network
Algorithm 2
Judge whether it is an emergency.
| (1). | //INPUT: ECG signals at and | | (2) | //OUTPUT: in normal/abnormal condition | | (3) | BEGIN | | (4) | IF the result of executing the algorithm is emergency; | | (5) | Select the ECG signal at ; | | (6) | Use equation (4) to calculate the results of the cross-correlation algorithm of ECG signals at and ; | | (7) | Use equation (9) to calculate the cross-correlation coefficient; | | (8) | ELSE the result of executing the algorithm is normal; | | (9) | Select the ECG signal at ; | | (10) | Use equation (4) to calculate the results of the cross-correlation algorithm of ECG signals at and or and ; | | (11) | Use equation (9) to calculate the cross-correlation coefficient; | | (12) | IF the error between and is acceptable, ; | | (13) | The human body is in normal condition, the certification under normal condition shall be carried out; | | (14) | ELSE the error between and is not acceptable, does not hold; | | (15) | The human body is in an emergency, and the certification under emergency shall be carried out; | | (16) | END IF | | (17) | END IF | | (18) | END |
|