View full-text article in PMC Sensors (Basel). 2016 Jan 23;16(2):145. doi: 10.3390/s16020145 Search in PMC Search in PubMed View in NLM Catalog Add to search Copyright and License information © 2016 by the authors; licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons by Attribution (CC-BY) license (http://creativecommons.org/licenses/by/4.0/). PMC Copyright notice Algorithm 4: Algorithm for Next Location Prediction. Input: ΣD,sA Output: p* 1sAc = symbol at the last position of sA. 2sAp = sequence preceding sAc in sA. 3Find σ=(sp,sc,ss,u) with the highest p-sim(sp,sAp) s.t. sc∋sAc ; ∀σ∈ΣD 4The ties are broken by picking σ with the highest u. 5p*← place p of ss