Abstract
The use of appropriate keyboards clearly improves the typing activity, making the task faster and the workstation more comfortable. On the contrary, intensive use of inappropriate/unergonomic keyboards may lead to musculoskeletal injuries. During the last years the design of optimal keyboards as appeared as an interesting problem from UI design. The idea is to arrange the letters on a keyboard according to a given ergonomic criteria in order to maximize typing speed, and reduce fatigue as well as typing errors. In this paper, we focus on the letter assignment problem, whose goal is to minimize the cost of the keyboard which is computed according to the Fitts law and the movement time among keys. In particular, we employ particle swarm optimization (PSO), which is one of the pioneers metaheuristics that has been largely used to solve different problems from multiple application domains.
You have full access to this open access chapter, Download conference paper PDF
Similar content being viewed by others
Keywords
1 Introduction
The letter assignment problem (LAP) is an optimization problem from UI design devoted to find optimal keyboards configurations. The goal is to arrange a set of letters according to ergonomic criterion in order to maximize typing speed, while reducing typing errors and tiredness. The problem is relevant as many repetitive stress injuries are caused by the inappropriate use of keyboards. The LAP is based on the Fitts law, which can be seen as an estimation of typing performance involving distance of keys and their width. In the optimization sphere, it is well-known that linear objective functions with linear constraints can definitely be solved with exact methods such as the simplex one. However, the LAP is an instance of the quadratic assignment problem (QAP) which is NP-Hard whose mathematical formulation involves a quadratic objective function. As a consequence, today there is no polynomial-time algorithm able to guarantee the global optimum. Then, to tackle this problem, we propose the use of metaheuristics, which are multi-purpose problem solvers devoted to particularly tackle large instances of complex optimization problems. They are commonly able to provide near-optimal solutions in a limited amount of time when the use of exact methods is too expensive. In particular, we employ particle swarm optimization (PSO), which is one of the pioneers metaheuristics that has been largely used to solve different problems from multiple application domains. Interesting results are provided where PSO is able to rapidly find optimal designs for different keyboard configurations.
2 The Letter Assignment Problem
The letter assignment problem (LAP) derives from the well-known quadratic assignment problem (QAP) which belongs to the NP-hard class of problems, no existing then evidence of a polynomial-time algorithm able to guarantee the global optimum. To this end, the use of metaheuristics appear as a suitable candidate for conveniently tackling this problem. The LAP is the defined as follows: given n letters and n keyslots, the goal is to minimize an average cost \(c_{kl}\) of pressing the letter l after the letter k. The average cost is weighted by a bigram probability denoted as \(p_{kl}\), as depicted in Eq. 1.
The \(p_{kl}\) probabilities are computed by a bigram distribution of representative corpus of text as explained in [1], while the cost is calculated by Eq. 2
where \(x_{lj}=1\) if letter l is assigned to keyslot j and \(x_{lj}=0\) otherwise. \(t_{ij}\) is the movement time (MT) from key i to key j, normally computed by Fitts’ law [5], as depicted in Eq. 3.
where \(D_{kl}\) is the distance between letters k and l and \(W_l\) represents the width of the keyslot holding l, a and b are constants that depend on the choice of input device. This function provides an estimation of the capable performance of a experience user. The LAP also involves the following constraints.
Constraint 4 is responsible for that each slot contains only one letter. Equation 5 ensures that each letter is assigned to only one slot and finally Eq. 6 guarantees the binary solutions. The technique employed to solve this problem is presented in the next section.
3 Particle Swarm Optimization
Particle swarm optimization (PSO) is one the pioneer and more tested metaheuristics [3]. It belongs to the class of population-based metaheuristics, where the population is composed of a set of agents called particles that explore promising regions of the search space in order to find optimal solutions. The classic PSO algorithm is depicted in Fig. 1
where \(V_p^d\) is the velocity of the dimension d of the particle p, \(present_p^d\) is the current dimension d of the particle p, \(pbest_p^d\) is the dimension d of the best position that p has had, \(gbest^d\) is the dimension d of the best global position of the swarm, rand is an evenly distributed random number between 0 and 1, c1 and c2 are learning factors.
3.1 Discretization
Given that LAP is a binary problem we must adapt the PSO algorithm to fit the model properly. To this end, we employ a method based on a transfer and a discretization function as detailed in [4] in which we take the probability \(p_{mutj}\) of mutating the jth column of the solution in the particle p to the actual speed. In this particular case we use the S-shape transfer function, as shown below.
Next, we generate the new binary value, based on the \(pmut_n^j\), from the discretization function as shown in Eq. 10.
where \(\alpha \) is an evenly distributed random number between 0 and 1.
4 Results and Conclusions
The PSO algorithm was tested with the 26 Letter Trapezoid Layout for touchscreens and the Zhai-Hunter-Smith’s variant of the Fitts-Bigram \((a=0.0, b=0.084, c=0.127)\), proposed in [2]. This keyboard has a search space of \(4*10^{26}\) and we assumed that the space bar is fixed at the bottom. The algorithm was able to get a fitness of 297.57437 in 5 h. Considering that the QWERTY layout has a score of 356.546251 based on the LAP metric and the known optimum found in previous research is 278.381124 [2], this is a promising result.
In this paper, we have presented ongoing work about PSO algorithms for solving the LAP. The problem is interesting as many repetitive stress injuries are caused by the inappropriate use of keyboards. As future work we expect to solve more instances of the LAP, and improve the performance of the proposed PSO. Analogous UI problems could also be solved with different metaheuristics.
References
Bi, X., Smith, B.A., Zhai, S.: Multilingual touchscreen keyboard design and optimization. Hum.-Comput. Interact. 27(4), 352–382 (2012)
Karrenbauer, A., Oulasvirta, A.: Improvements to keyboard optimization with integer programming. In: Proceedings of the 27th Annual ACM Symposium on User Interface Software and Technology, UIST 2014, pp. 621–626. ACM, New York (2014)
Kennedy, J., Eberhart, R.: Particle swarm optimization. In: Proceedings of the IEEE International Conference on Neural Networks, vol. 4, pp. 1942–1948, November 1995
Lanza-Gutierrez, J.M., Crawford, B., Soto, R., Berrios, N., Gomez-Pulido, J.A., Paredes, F.: Analyzing the effects of binarization techniques when solving the set covering problem through swarm optimization. Expert Syst. Appl. 70, 67–82 (2017)
MacKenzie, I.S., Zhang, S.X.: The design and evaluation of a high-performance soft keyboard. In: Proceeding of the CHI 1999 Conference on Human Factors in Computing Systems: The CHI is the Limit, pp. 25–31. ACM (1999)
Acknowledgments
Ricardo Soto is supported by Grant CONICYT/FONDECYT/REGULAR/1160455 and Broderick Crawford is supported by Grant CONICYT/FONDECYT/REGULAR/1171243.
Author information
Authors and Affiliations
Corresponding author
Editor information
Editors and Affiliations
Rights and permissions
Copyright information
© 2018 Springer International Publishing AG, part of Springer Nature
About this paper
Cite this paper
Soto, R., Crawford, B., Toro, J. (2018). Optimal Keyboard Design by Using Particle Swarm Optimization. In: Stephanidis, C. (eds) HCI International 2018 – Posters' Extended Abstracts. HCI 2018. Communications in Computer and Information Science, vol 850. Springer, Cham. https://doi.org/10.1007/978-3-319-92270-6_40
Download citation
DOI: https://doi.org/10.1007/978-3-319-92270-6_40
Published:
Publisher Name: Springer, Cham
Print ISBN: 978-3-319-92269-0
Online ISBN: 978-3-319-92270-6
eBook Packages: Computer ScienceComputer Science (R0)