Research Article
Optimal Clustering in Wireless Sensor Networks for the Internet of Things Based on Memetic Algorithm: memeWSN
Algorithm 3: Pseudo code of procedure-replace for WSN-IoT.
1. Procedure Replace_WSN-IoT | 2. Input: populace, CH-set, k | 3. Output: CH-set, populace | 4. Initialize variables | 5. whiledo | 6. | 7. end while | 8. | 9. whiledo\ mutation and crossover / | 10. | 11. | 12. | 13. end while | 14. | 15. | 16. return new_populace, CH-set | 17. end procedure replace_WSN-IoT |
|
Algorithm 3: Pseudo code of procedure-replace for WSN-IoT. |