Skip to main content

Can we optimize locations of hospitals by minimizing the number of patients at risk?



To reduce risk of death in acute ST-segment elevation myocardial infraction (STEMI), patients must reach a percutaneous coronary intervention (PCI) within 120 min from the start of symptoms. Current hospital locations represent choices made long since and may not provide the best possibilities for optimal care of STEMI patients. Open questions are: (1) how the hospital locations could be better optimized to reduce the number of patients residing over 90 min from PCI capable hospitals, and (2) how this would affect other factors like average travel time.


We formulated the research question as a facility optimization problem, which was solved by clustering method using road network and efficient travel time estimation based on overhead graph. The method was implemented as an interactive web tool and tested using nationwide health care register data collected during 2015–2018 in Finland.


The results show that the number of patients at risk for not receiving optimal care could theoretically be reduced significantly from 5 to 1%. However, this would be achieved at the cost of increasing average travel time from 35 to 49 min. By minimizing average travel time, the clustering would result in better locations leading to a slight decrease in travel time (34 min) with only 3% patients at risk.


The results showed that minimizing the number of patients at risk alone can significantly improve this single factor but, at the same time, increase the average burden of others. A more appropriate optimization should consider more factors. We also note that the hospitals serve also for other operators than STEMI patients. Although optimization of the entire health care system is a very complex optimization problems goal, it should be the aim of future research.

Peer Review reports


Although the number of patients with ischemic heart disease has decreased in Finland cardiovascular disease remains the most common cause of death [1]. From the health care service system point of view, patients with ST segment elevation myocardial infarction (STEMI) type of cardiovascular disease present challenges as they need to be treated within a given time limit in a facility with capabilities for invasive treatment or face potentially fatal consequences [2,3,4]. Patients living closer to a percutaneous coronary intervention (PCI) capable cardiac unit (henceforth PCI cardiac unit) have higher chance of survival than those who live far away [5]. Current health care system is under pressure to cut costs and optimize the health care services better. This may lead to reducing the number of hospitals including those that provide acute treatment for myocardial infarction patients.

The optimization of distance from place of residence to appropriate care is critical when a delay means loss of function or even death [4]. This time dependency is apparent in vascular emergencies such as acute coronary syndrome, and particularly in STEMI, where the electrocardiogram findings show specific signs of imminent heart muscle necrosis. The guidelines for STEMI treatment currently call for invasive PCI within 120 min from symptom onset [4, 6]. These lifesaving procedures can only be performed in dedicated PCI cardiac units by experienced specialized cardiologists.

In Finland, PCI cardiac units (n = 22) exist in larger hospitals of all mainland hospital districts, but only the five university hospitals have capability to provide PCIs on a 24/7 basis. Other hospitals, health centers, and ambulance services can provide thrombolysis when primary PCI is not immediately available. However, pre-hospital diagnosis (e.g., obtained by utilizing telemedicine) and early transfer to PCI is the preferred option as it reduces delay and results in better outcomes [4, 7]. The locations of PCI capable hospitals are relevant for care of other urgent medical conditions as well and can be considered to represent the “backbone” of optimal acute hospital network.

Studies focusing on prehospital delays have assumed that health care systems are expected to treat patients with PCI within 90 min from the first medical contact when initial point of care is at a PCI cardiac unit [5]. Other travel times to PCI cardiac units (such as 60 min) have also been used [8]. The definition of the threshold for transport time may vary when in-facility delays (door-to-balloon-time) are taken into consideration [2] yet it remains a significant determinant of patient outcomes.

In this paper, we perform theoretical study how the location of the hospitals would change if they were optimized by minimizing the patients at risk of residing over 90 min from the PCI capable hospital in 2015–2018. We assess optimized hospital locations with an interactive web tool built for this purpose, that optimizes the location by clustering algorithm with real patient data and their location. The optimization result is shown visually on map using the Web-tool described in [9], see Fig. 1.

Fig. 1
figure 1

Average travel time from postal code areas to both current and the optimized locations of cardiac units capable of percutaneous coronary intervention (named health centers in the Web-tool)



To analyze a specific group with critical time-dependency, we identified Finnish population with diagnosed ST-elevation myocardial infarctions in 2015–2018 from Finnish Care Register for Health Care. This register is maintained by Finnish Institute of Health and Welfare and includes practically all hospital discharges from both public and private hospitals. STEMIs were defined as hospitalizations with ICD-10 codes I21.0-I21.3. Thus, we excluded other myocardial infarctions requiring less urgent invasive care (classified either as a non-ST-elevation infarction or of an unspecified type). Every individual with at least single hospitalization for STEMI in 2015–2018 was included, 17,563 in total. Those with location information were selected; eventually forming a study population of 17,346 adults.

For every individual in our study population, we obtained postal code area of residence using the personalized ID codes provided by the respective authorities. There are 3038 postal codes in Finland which are larger in sparsely populated areas. To have more accurate home locations of the individuals, we applied a 1 km × 1 km population density grid information from the National Land Survey of Finland and converted the postal code areas to a set of randomized GPS coordinates as follows. We first calculated weighted average of the center points of all grid cells located within a single postal code area. We then allocated number of individuals with STEMI to the GPS coordinates for their respective postal code areas.

Secondary and tertiary care hospitals with PCI cardiac units (n = 22) were identified with their corresponding coordinates based on the addresses. In the Web-tool, these units are named health centers, as the tool is designed to be general and not limited only to STEMI patients. We also identified the five university hospitals as they have 24/7 capability for providing PCIs.

Travel times between GPS coordinates of postal code areas and PCI cardiac units were calculated applying open street data. We define individuals with travel time of 90 min or more to the nearest PCI cardiac unit at risk for not receiving PCI in case of STEMI (henceforth patients at risk). These individuals are presented in the Web tool with red color, while those whose travel time remain under the threshold of 90 min are depicted blue; see Fig. 2.

Fig. 2
figure 2

Choice of the cost function has significant impact on the optimization result. Three hospital allocations are shown: the current (left), optimized for minimal travel-time (middle), and optimized for minimum number of patients at risk (right)

Clustering method

The optimization is defined as a clustering problem where the input is the home locations of the patients, and the output is the locations of the optimized health centres. The process includes three main components (Fig. 3): clustering algorithm, travel time estimation, and mathematical function that provides the objective for the clustering algorithm.

Fig. 3
figure 3

Main components of the clustering include the clustering algorithm, travel time estimation, and the objective (cost function) for the clustering

K-means is by far the most common clustering algorithm and would be applicable as such since the data is numeric. Furthermore, the data contains a reasonably small number of clusters (22 at most) of which most are not isolated from the others. Thus, the data would fit rather well for k-means especially if repeated multiple times [10]. However, we do not want to compromise the quality and use improved variant called random swap, which is shown to find the best clustering structure even in cases when k-means would fail [11]. High-speed scalable variant of random swap is also available if faster processing time would be needed [12].

While the choice of the algorithm matters for the precision, the choice of the cost function is much more important for the application. We consider two choices: (1) minimizing for travel time, and (2) minimizing for the patients at risk. They are mathematically defined as follows. Optimizing for travel time is simply a linear function which increases with the time. The further the patient is from the hospital, the higher the travel time and the higher its cost in the model.

Minimizing the patients at risk is a bit trickier. In principle, a simple thresholding would assign cost 0 for every patient reaching the hospital within the limit (90 min), and cost 1 for others. However, binary threshold tends to reduce the flexibility of k-means type of algorithms and often lead to inferior optimization result [13]. For this reason, we soften the threshold by using Sigmoid function. The effect is the same as with the linear function: shorter travel times have smaller cost, but there is rapid increase around the threshold value. The benefit of the smoother curve is to avoid possible pitfalls of the algorithm in the optimization.

The effect of these two cost functions is demonstrated in Fig. 4. In case of Euclidean distance, optimal location for the centre would be the geometric average of all patients which happens to be in the middle of the blue points. The same typically happens when optimizing for travel time as it is directly dependent on the distance. Optimizing for risk, however, tend to move the hospital locations closer to the border of the blue points to reach more of the red points within the time limit.

Fig. 4
figure 4

Two cost functions implementing the two different objectives: linear function minimizing travel time (left), and Sigmoid function minimizing patients at risk

Travel time estimation

Standard k-means operates with numerical data uses Euclidean distance. However, we use travel distance calculated using road network because simple Euclidean (Bird’s) distance can cause major inaccuracies. It may work well in flat areas with extensive road network [14] but large errors were reported in [15] of about 30% with SiunSote data in North Karelia, Finland, in the region of many lakes and rivers. Travel time is then estimated from the travel distance. The use of travel distance instead of Euclidean can also have significant impact on the clustering, see Fig. 5. Other affecting factors are speed limitations and traffic congestions.

Fig. 5
figure 5

The effect of the distance function on the clustering: Euclidean distance (left), nearest centre according to travel distance (middle), effect on the final clustering (right)

The drawback of travel distance is that it is time consuming to compute. The shortest path itself can be easily calculated using road network in linear time but the optimization process may require millions of such operations and the location of the centres are dynamically changing during the process. Fortunately, we do not need to know the actual path but only its length, and more importantly, the length of every path does not need to be exact. It is enough we have their expected length with reasonable accuracy, but we want to have it fast.

To keep the optimization efficient, we therefore use the overhead graph method in [15] to provide rapid estimation for both travel-distance and travel-time. This method has two stages. First, a pre-processed graph is built using the data (patient) locations and the road network to identify most important traffic points, which will be the nodes of the graph. Second, rapid calculation of any travel time (or distance) during the optimization process is done using a look-up table and simple multiplication of the Euclidean distance and an overhead (detour index) provided by the graph.

The effect of the graph is that the processing time of the optimization is reduced from 1.2 h to only 2.9 s per iteration (up to 10,000) in case of SiunSote data in North Karelia using a graph with 512 nodes. The huge speed-up is achieved at the cost of 2% inaccuracy in the distance estimation using memory for 512 × 512 = 0.25 MB look-up for the graph [15]. The process and two sample graphs are shown in Fig. 6.

Fig. 6
figure 6

Fast travel time estimation using overhead graph [15]. The two-stage process is shown (left), and two example graphs (right) optimized for Finland (1024 nodes) and for North Karelia region (256 nodes)


The optimization is implemented as a Web tool. The data is pre-calculated and stored within the system, and all the reported combination in this paper have been pre-calculated. The system allows testing also new parameter combinations; see Fig. 7. These include different risk thresholds (30, 45, 60, 75, 90 min), different optimization functions (Euclidean distance, travel distance, travel time, patients at risk), different methods for distance estimation (Euclidean, estimated by the overhead graph, actual travel distance), different graph sizes (16, 32, 64, 128, 256, 512, 1024). The system also allows user to select the number of iterations (50, 100, 2000, 10000) with reporting the estimated processing times varying from 20 s (50 iterations) to 20 min (10000 iterations).

Fig. 7
figure 7

Control parameters for the optimization include risk threshold, distance function, and graph size. Pre-calculations selections are also listed in the optimization goals for faster analysis

The number of health centres can also be changed either by adding new ones on map, or by removing any existing centre. The location of any centre can be manually changed by drag-and-drop. User can lock certain health centres and optimize only the location of the others. The optimization always starts from the current set of locations shown on map after the manual operations. The algorithm is not sensitive to the initialization and only the locking and the number of centres has significant effect to the outcome of the optimization.

The solutions are visualized on map by showing either the original locations or optimization locations (or both), possibility to show coloured points (heat map) so that red dot indicates patients at risk. Numerical summary is provided by reporting various statistics including the number of patients, the number of patients at risk, average travel time and distance. These are reported as averages of all population, and for each unit separately. However, the visualisation on the map is the easiest way to analyse the optimization result.

The front end of the Web system is implemented by HTML and CSS (styling) and Javascript (interactive elements). The pre-optimized centre locations are stored in MariaDB database, which is a free and open-source community fork of MySQL. Server-side backend is mostly implemented by with PHP but also some parts with Java, Python and few critical parts in C including travel time estimations and the core clustering functions. The system runs on a Centos 7 Linux server with 16 Xeon W-2255 processing cores an 512 GB memory. It is accessible by all stakeholders via passwords.


Table 1 summarizes the main results of the optimization. The numbers are the averages over all patient locations. We first observe that the results are always the best for the same measure that was used as the optimization function. For example, if we want to minimize travel distance, the best result (34.7 km on average) would be achieved by using travel distance as the cost function in the clustering. The second observation is that the number of patients at risk can be improved significantly. With 90 min risk threshold, the number patients at risk reduces from 832 (5%) to 135 (1%) when optimizing for the patients at risk using the corresponding optimization function (Sigmoid). The difference is remarkable.

Table 1 Average travel time, distances, and the number of patients at risk when optimized for different cost functions

Effect of the road network

The effect of using road network is demonstrated further in Fig. 8. There are five university hospitals in Finland (Helsinki, Turku, Tampere, Kuopio, Oulu). If we map every patient to the nearest university hospital, we will get the division shown by the black lines if Euclidean distance is used. The difference when using travel distance seems marginal in this example but when applied in the optimization algorithm, the effect becomes significant. The optimized locations in many cases are close to their current locations in cities like Vaasa, Seinäjoki and Kokkola when the road network is used. However, with Euclidean distance hospitals would be located into arbitrarily places like Jumisko and Tervola in Lapland, or island in Alajärvi lake.

Fig. 8
figure 8

Accessibility of the hospitals depends on the road network. The division by the five university hospitals are presented by the black borders (Euclidean distance) and by colouring the patient locations (travel distance). They look quite similar but their effect on the optimization is significant

Effect of optimization function

Results when optimization for the patients at risk are further demonstrated in Fig. 9 with three risk thresholds (30 min, 60 min and 90 min). Reducing the risk threshold from 90 to 60 min would reach the same level (5%) as the current location with 90 min threshold. This means that the same number of people can reach the hospital in 1 h time with optimized locations compared to 1 h 30 min.

Fig. 9
figure 9

Results of the optimization with three different thresholds. The colours of the locations are red for the patients at risk when using 30 min (left), 60 min (middle) and 90 min (right) thresholds

We can also see that that many optimized centre locations would move to sparsely population especially in North Finland. The reason is that most patients in south are safe when considering the higher 90 min threshold, which leads the optimization algorithm trying to catch the remaining patients at risk. This optimization, however, comes at a cost of increasing the average travel time of all patients. The optimization does not care if people need to travel 49 min (on average) instead of 35 min, as long as the time is below 90 min, see Table 1.

Detailed effect in Central and South Finland are also demonstrated in Fig. 10 for the 90 min threshold. The optimization in Jyväskylä and Joensuu area are understandable from the logistics point of view, but the South Finland situation shows the effect of this optimization function. The optimized centre now in Mäntsälä is reached by all patients within 90 min. However, their original average travel time increases from 13, 22, 32 (Helsinki), 26 (Lahti) and 31 (Hämeenlinna) to 46 min (Mäntsälä). This does not make much sense. The results with 30 min threshold cause fewer radical changes but the patient at risk as such seems unsuitable cost function.

Fig. 10
figure 10

Optimizing patient at risk has many dubious side effects. Jyväskylä and Joensuu hospital would be moved to logistically better locations at Tikkakoski and Kontiolahti. South Finland reconstruction would leave only one hospital in Helsinki area and far away in Mäntsälä

Travel distance or travel time as the optimization goal can also provide better locations and reduce those attributes, but the difference is less significant. Optimizing travel distance reduced the average distance from 36.6 km to 34.7 km (-5%), whereas optimizing travel time reduced average time from 35.3 min to 34.0 min (-3.7%). This would also reduce the number of patients at risk from 832 to 519 (when optimized for distance) and 488 (when optimized for time), respectively, and seems more suitable for patient at risk as well.

How many hospitals?

Currently there is considerations to optimize the resources by cutting out some of the hospitals. We therefore study next how the reduction of the number of hospitals would affect the measures. Figure 11 shows that we could remove several hospitals without big change if the locations were optimized. We could still reach patients at risk at 1% level even if the number of hospitals was reduced from 22 to 19. Further reduction to 14 would still achieve better than the original 5% after which the proportion of patients at risk starts to increase radically.

Fig. 11
figure 11

Effect of the number of hospitals when optimized for patients at risk (90 min)

In real-life, we cannot relocate the hospitals just like that, and a more realistic question would be which PCI would be least harmful to cut-off? The two most speculated ones have been the two smallest, Savonlinna and Länsi-Pohja (Kemi), which urges us to test what would happen if they were removed. The results in Fig. 12 and Table 2 show their removal would have remarkable 20% increase in the patients at risk (from 832 to 1,117) which can be seen the red points in those regions. The algorithm would re-optimize the remaining 20 hospitals so that Savonlinna and Kemi would retain their own PCI units.

Fig. 12
figure 12

Effect of removing two hospitals (20 remaining). Savonlinna and Kemi (those most speculated to be axed) are removed in the middle. Re-optimizing the remaining 20 hospitals are shown on right

Table 2 The effect of removing two selected hospitals, and if only university hospitals were retained. Total patients: 17,346

Optimizing the travel time

Optimizing for the travel time seems more meaningful than optimizing for patients at risk. Let us therefore study this optimization result in more detail. The optimized locations are shown in Fig. 13. The main observation is that most optimized locations are very close to the original locations. It shows that they are roughly at the places they should be, and well optimized from the STEMI patient point of view. The average travel time is 35 min and was reduced only by about 1 min by better optimization. The number of patients at high risk (90 min threshold) would be reduced more; from 5 to 3%.

Fig. 13
figure 13

Optimization result using average travel time as the cost function

The optimization algorithm kept most locations almost intact. Even logistics tuning in Jyväskylä and Joensuu would not happen when minimizing the average travel time instead of the patients at risk (targeting to reduce the worst cases). There are few changes the algorithm makes though as shown in Fig. 13.

  1. 1.

    Rovaniemi and Hämeenlinna are removed.

  2. 2.

    Capital area would have only two units instead of three, and one of them would be in Lohja.

  3. 3.

    The released resources would be allocated to Åland, Nivala and Kuusamo.

  4. 4.

    Mikkeli and Savonlinna would be merged and re-located in Juva in the middle.

The reason of putting one hospital in Åland is merely an artefact of it being island. The number of STEMI cases in the data was just 37. Their distance to Turku hospital is only 160 km but it takes about 6 h by ferry. These cumulate and causes a creation of a new PCI unit there. Turku hospital itself serves for 1,395 patients with an average distance of 28 km. In real-life, the few critically ill patients receive mostly care in Sweden due to the autonomous governance of the Åland islands and the proximity to Sweden.

Main result is that most hospitals are at excellent locations considering the STEMI patients already.

The other changes were caused by the optimization. The joint volume in Mikkeli (428) and Savonlinna (221) were about at the same as those of its surrounding hospitals Joensuu (602), Kuopio (787) and Jyväskylä (720). The merge is therefore as expected. Hämeenlinna (719) had similar volume but it is within < 1 h highway connection to Tampere, and likely therefore removed. New locations in Nivala (352) and in Kuusamo (123) are in areas without any major cities, and hospital, nearby. For minimizing the average travel time, the algorithm decided to allocate one PCI facility for both. It also considered Sodankylä more beneficial location for PCI unit than Rovaniemi due to long distances in the North.

Detailed statistics of the original and optimization locations are summarized in Tables 3 and 4. The current hospital locations in the Capital area follow the municipality borders as all three are in different municipality (Helsinki 13 min; Vantaa 22 min; Espoo 33 min). After optimization, only one remains in Helsinki (Tapaninvainio) roughly halfway between Helsinki downtown and Vantaa. The average travel time of patients to this location is clearly the shortest (22 min) among all optimized hospital locations. The second Capital hospital location is in Lohja (42 min). It covers large portion of the less dense areas from Hanko to Forssa, including also the westmost parts of Espoo (Finn).

Table 3 Statistics of the current hospitals
Table 4 Statistics of the new locations optimized for travel time

The volumes of the centres have somewhat changed due to the merges and by creating new centres in the sparsely populated areas. First, the volume of the smallest units in Kemi (263) and Savonlinna (221) have increased. The first one is moved slightly to North at Keminmaa (443) and covers now also Rovaniemi which increased its volume. The new centre at Juva (625) also has higher volume serving for both Savonlinna and Mikkeli. The three new centres are all small: Nivala (352), Sodankylä (189) and Kuusamo (123). From accessibility point of view, they are all well motivated but whether such low volumes would be economically feasible considering the overall health care services of the hospitals, is an open question.


We have analysed how optimizing hospital locations could improve patient access in diseases with critical time-dependency. To achieve this, we used Web tool designed to optimize spatial locations of PCI capable hospitals to promote timely access for STEMI patients. Three optimization goals were applied: 1) number of STEMI patients at risk to reside in areas with travel time of 90 min or over, 2) average travel distance, and 3) average travel time. For each of these goals, we observed the results of the optimized models against those of the current locations of PCI capable hospitals.

Our findings suggest that the network of PCI capable hospitals in Finland is rather well distributed along the country but could be still fine-tuned for better access. The results also suggest that possible closure of two smallest units (Savonlinna and Kemi) would increase the number of STEMI patients with travel time to PCI capable hospitals over the 90 min threshold by 34% (from 832 to 1,117).

Regarding optimization of travel times, the optimization result suggested several changes to the current hospital network. The removal of Hämeenlinna, the merging of two smaller units (Mikkeli and Savonlinna) into a new facility location at Juva, relocation of Rovaniemi to better serve the Northern parts. The optimization, however, did not consider the treatment capacity of the hospital and their emergency care services.

Accessibility may also be hampered furthermore by factors such as congested traffic or cultural factors causing delays in seeking care. Further studies should take into consideration factors such as regional variation of cardiovascular diseases and the population projections regarding ageing and internal migration. Despite considerable improvements in cardiovascular health, the population in Northern and Eastern parts of Finland still is burdened by these diseases more than the Southwestern parts.

The web tool provides a visual interface in which the effects of the abovementioned factors and different political decisions can be tested. The optimized models used in this study were restricted to a few selected parameter combinations but could be extended to consider more parameters such as lower and upper limits for the volume for the PCI units. One promising direction would be to optimize locations of other disease groups beyond the acute STEMI patients and finding disease combinations that would be most efficiently treated in the hospitals with similar service provision profiles.

The hospital network in Finland is predominantly publicly financed and its facilities constructed in the decades succeeding WWII as in other Western countries, but in early 2000s the network was considered outdated. Several efforts at centralization of these functions led to mergers and closures of secondary care facilities after 2013 [16]. However, the population projections show that further actions are needed as the number of elderly people is rapidly increasing, internal migration to larger cities continues, and shortage of health care workforce is common in sparsely populated regions. Specialized secondary and highly specialized tertiary care constitute the largest single cost component of the national health budget. Further consolidation of the hospital network would yield considerable returns but may be life-threatening in certain clinical conditions as the extended distances in the sparsely populated Finnish rural areas present considerable challenges.

Finland is not alone in the health care services reform as thorough restructuring of Danish hospital network began in 2007. This reform changed the hospital network structure of 40 public hospitals in 82 locations (2007) to 21 hospitals in 68 locations (2016) according to [17]. The restructuring took place in a democratic process subject to central guidelines and requirements including the central planning of specialties [18]. The permission to perform highly specialized treatments, such as PCI, is governed centrally. This reform has been deemed successful in terms of improved quality of care [19] due to stable costs and increased productivity [17].

Most of the studies on hospital network optimization have focused on geographic accessibility [20, 21]. These studies are prevalent also in the context of acute cardiovascular care [8] also in case of remote, sparsely populated regions [22, 23]. The Cardiac ARIA is a road time and distance based geographic model that determines what are the minimal services and resources required for the management of a cardiac event in any urban, rural, or remote population locations in Australia [22]. Some studies have focused on reorganizing their hospital network based on simulations on health care centralization [24] and some studies have aimed to reorganize the entire service system based on location-allocation models [25]. Huotari et al. have studied the Finnish hospital network based on accessibility if the number of maternity hospitals were reduced [26].

In Finland, municipalities with varying population base have been in principle responsible for organizing and financing health and social services for their residents [16]. Various attempts at health care and social welfare reform have been attempted in vain during the last two decades, but now a complete overhaul has been initiated and the new structures for organization and financing enters into force on Jan 1st, 2023. Currently no major plans have been initiated to further consolidate the hospital network, but as some of the new wellbeing services counties will most probably have difficulties in providing services for their residents, financial realities may necessitate these changes.

Strengths and limitations

All the components of optimization have been carefully chosen based on the long-term experience of the authors in their respective research areas. Every single component from the clustering, travel time estimation and designing the cost function are well thought. The Web tool is also well designed, carefully programmed and reasonably flexible to allow testing new combinations if wanted. We have not seen anything similar developed elsewhere.

One limitation of the system is that the optimization algorithm was mainly tuned for the patients at risk criterion, which turned out to be not feasible. Some pre-optimized results were also run for other criterion with selected parameter combinations, but entirely new results cannot be currently run for the other criterion (travel time and distance) without some re-programming.

The study was limited to all the hospitals having a PCI unit even if only the five university hospitals have 24/7 capability. Pre-optimized results were run also for these but testing entirely new parameter combination is restricted to the same patients at risk criterion as above. Considering recent findings that differentiating STEMI from other types of myocardial infarction may be unreliable based on Finnish register data [27]. It is therefore possible that we were unable to identify all STEMIs – and that our study population may have also included some infarctions with less time-dependency (non-ST-elevation myocardial infarction I21.4 or unspecified myocardial infarction I21.9).

The travel time was estimated based on estimated road network distance without considering rush hours. More accurate result could be theoretically obtained by considering the time of the day in these calculations. However, we expect it would have just a minor fine-tuning effect due to the strong averaging effect of the optimization. One might also ask if the optimized locations would be different during rush hours. However, this bares very little relevance to the facility optimization unless someone plans the operations so that the PCI units could be dynamically re-located in certain times (rush hours). Until then, having heart-attack during the rush hours is just counted as bad luck.

The data selection included patients in Åland islands which is not even part of the Finland health care system; the patients were actually dealt in Stockholm (closer than Turku). The algorithm allocated unnecessarily one hospital to Åland, and effectively, removed one hospital from the mainland. The good side is that this data revealed how such artefact may affect the result and can be taken into account in future studies if such special situations are wanted to avoid.

The patient data have also other limitations. First, the postal code precision is a bit rough but good enough in this scenario as the errors from the estimation are minor compared to the 90-min hospital accessibility threshold. Second, the data represent the past demography in 2015–2018 and optimization might be better off using predicted future population. Clever predictor might even include factors like age and socio-economic status; or whichever factors increase the likelihood for heart attack.


To answer the main question of the paper: yes, optimizing the locations of hospital by minimizing patients at risk can of course be done but we do not recommend doing so. It can theoretically reduce the patients at risk from 5 to 1% using the 90 min cutoff threshold. This itself is a good goal but it would also increase the average travel time of others. A somewhat better optimization function would be the average travel time itself as it would also reduce the number of patients at risk from 5 to 3% as a side result.

In real-life, we cannot simply re-locate hospitals into arbitrary locations. The web tool has demonstrated its power to provide important insight for the decision makers. It can reveal deficiencies of the current hospital network and indicate potential improvements. One main observation is that most hospitals are already well located for the STEMI patients’ point of view and only few were re-located by the optimization.

It seems that future attention should be targeted for better overall organization of the health care services rather than crude re-planning of their locations. STEMI cases are integrated into the other operations of hospitals and less likely to be operated as standalone units anywhere. The optimization of the entire healthcare system remains as a future goal but also a very challenging one. Nothing prevents to formulate it as an optimization problem as well, but it would be a very complex to define [28].

Availability of data and materials

The datasets analysed during the current study will be made publicly available in the UEF Machine Learning repository at


  1. Statistics Finland. Causes of death 2021. (Accessed 15 Nov, 2022).

  2. Terkelsen JA, et al. System delay and mortality among patients with STEMI treated with primary percutaneous coronary intervention. JAMA. 2010;304:763–71.

    Article  CAS  PubMed  Google Scholar 

  3. Berlin C, Panczak R, Hasler R, et al. Do acute myocardial infarction and stroke mortality vary by distance to hospitals in Switzerland? Results from the Swiss National Cohort Study. BMJ Open. 2016;6:e013090.

    Article  PubMed  PubMed Central  Google Scholar 

  4. Collet JP, et al. 2020 ESC Guidelines for the management of acute coronary syndromes in patients presenting without persistent ST-segment elevation: the task force for the management of acute coronary syndromes in patients presenting without persistent ST-segment elevation of the European Society of Cardiology (ESC). Eur Heart J. 2021;42(14):1289–367.

    Article  PubMed  Google Scholar 

  5. Di Domenicantonio R, Cappai G, Sciattella P, Belleudi V, Di Martino M, Agabiti N, et al. The tradeoff between travel time from home to hospital and door to balloon time in determining mortality among STEMI patients undergoing PCI. PLoS One. 2016;11(6):e0158336.

    Article  CAS  PubMed  PubMed Central  Google Scholar 

  6. Lawton JS et al. 2021 ACC/AHA/SCAI guideline for coronary artery revascularization: a report of the American College of Cardiology/American Heart Association Joint Committee on clinical practice guidelines. Circulation. 2021;145(3).

  7. Sørensen JT, Terkelsen CJ, Nørgaard BL, Trautner S, Hansen TM, Bøtker HE, Lassen JF, Andersen HR. Urban and rural implementation of pre-hospital diagnosis and direct referral for primary percutaneous coronary intervention in patients with acute ST-elevation myocardial infarction. Eur Heart J. 2010;32(4):430–6.

    Article  PubMed  Google Scholar 

  8. Nallamothu BK, Bates ER, Wang Y, Bradley EH, Krumholz HM. Driving times and distances to hospitals with percutaneous coronary intervention in the United States: implications for prehospital triage of patients with ST-elevation myocardial infarction. Circulation. 2006;113(9):1189–95.

    Article  PubMed  Google Scholar 

  9. Fränti P, Mariescu-Istodor R, Akram A. Web-tool for optimizing locations of health centers. Health and Social Care Information Systems and Technologies (HCist’2022). Procedia Comput Sci. 2023;219:1120–7.

    Article  Google Scholar 

  10. Fränti P, Sieranoja S. How much k-means can be improved by using better initialization and repeats? Pattern Recogn. 2019;93:95–112.

    Article  Google Scholar 

  11. Fränti P. Efficiency of random swap clustering. Journal of Big Data. 2018;5(13):1–29.

    Google Scholar 

  12. Nigro L, Cicirelli F, Fränti P. Parallel Random Swap: An Efficient and Reliable Clustering Algorithm in Java. Simulation Modelling Practice and Theory. 2022. p. 102712.

    Google Scholar 

  13. Kärkkäinen I, Fränti P. Variable metric for binary vector quantization. IEEE Int Conf on Image Processing (ICIP’04), Singapore. 2004;3:3499–502.

    Google Scholar 

  14. Boscoe FP, Henry KA, Zdeb MS. A nationwide comparison of driving distance versus straight-line distance to hospitals. Prof Geogr. 2012;64(2):188–96.

    Article  Google Scholar 

  15. Mariescu-Istodor R, Fränti P. Fast travel distance estimation using overhead graph. J Locat Based Serv. 2021;15(4):261–79.

    Article  Google Scholar 

  16. Keskimäki I, Tynkkynen LIK, Reissell E, Koivusalo M, Syrjä V, Vuorenkoski L, Rechel B, Karanikolos M. Finland: health system review. Health Syst Transit. 2019;Nro 21:2

    Google Scholar 

  17. Christiansen T, Vraengbaek K. Hospital centralization and performance in Denmark-ten years on. Health Policy. 2018;122(4):321–8. (Epub 2018 Feb 9).

    Article  PubMed  Google Scholar 

  18. Sundhedsstyrelsen (DHMA). Specialised hospital services – principles of national planning in denmark. 2015.

    Google Scholar 

  19. OECD Reviews of Health Care Quality: Denmark 2013. Rising standards. Paris: 2013.

  20. Li Z, Serban N, Swan JL. An optimization framework for measuring spatial access over healthcare networks. BMC Health Serv Res. 2015;15:273.

    Article  PubMed  PubMed Central  Google Scholar 

  21. Wang F. Measurement, optimization, and impact of health care accessibility: a methodological review. Ann Assoc Am Geography. 2012;102(5):1104–12.

    Article  Google Scholar 

  22. Clark RA, Coffee N, Turner D, Eckert KA, van Gaans D, Wilkinson D, Stewart S, Tonkin AM. Application of geographic modeling techniques to quantify spatial access to health services before and after an acute cardiac event. The cardiac Accessibility and Remoteness Index for Australia (ARIA) project. Circulation. 2012;125:2006–14.

    Article  PubMed  Google Scholar 

  23. Coffee N, Turner D, Clark RA, Eckert K, Coombe D, Hugo G, van Gaans D, Wilkinson D, Stewart S, Tonkin AA. Measuring national accessibility to cardiac services using geographic information systems. Appl Geogr. 2012;2012(34):445e455.

    Google Scholar 

  24. Kobayashi D, Otsubo T, Imanaka Y. The effect of centralization of health care services on travel time and its equality. Health Policy. 2015;119:298–306.

    Article  PubMed  Google Scholar 

  25. Mestre AM, Oliveira MD, Barbosa-Povoa AP. Location–allocation approaches for hospital network planning under uncertainty. Eur J Oper Res. 2015;240:791–806.

    Article  Google Scholar 

  26. Huotari T, Rusanen J, Keistinen T, Lähderanta T, Ruha L, Sillanpää MJ, Antikainen H. Effect of centralization on geographic accessibility of maternity hospitals in Finland. BMC Health Serv Res. 2020;20:337.

    Article  PubMed  PubMed Central  Google Scholar 

  27. Okkonen M, et al. The validity of hospital discharge register data on non-ST-elevation and ST-elevation myocardial infarction in Finland. Scand Cardiovasc J. 2020;54(2):108–14.

    Article  PubMed  Google Scholar 

  28. Wang F. Why public health needs GIS: a methodological overview. Ann GIS. 2020;26(1):1–12.

    Article  PubMed  Google Scholar 

Download references


We wish to thank the project consortium and stakeholders for fruitful background discussions and the anonymous referees for valuable comments.


This study is a part of the consortium project “Improving the Information Base and Optimising Service Solutions to Support Social Welfare and Healthcare Reform (IMPRO)”. The research was funded by the Strategic Research Council at the Academy of Finland, funding decision numbers 336325, 336328 and 336330.

Author information

Authors and Affiliations



PF and RM designed the methodology used for the analysis. AA implemented the software and performed the experiments. Results were analysed and paper written jointly by all authors. PF and RM prepared the literature review of the clustering and data analysis part, MS and ER literature review of the STEMI application. All authors approved the final manuscript for submission.

Corresponding author

Correspondence to Pasi Fränti.

Ethics declarations

Ethics approval and consent to participate

Permission to use the register data was obtained from the Finnish Institute for Health and Welfare. All methods were carried out in accordance with relevant guidelines and regulations of declaration of Helsinki. The Finnish legislation (Act 552/2019) do not require informed consent for register-based research when study is solely based on registers and the study is considered important to be of public health.

Consent for publication

Not applicable.

Competing interests

The authors declare no competing interests.

Additional information

Publisher’s Note

Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.

Rights and permissions

Open Access This article is licensed under a Creative Commons Attribution 4.0 International License, which permits use, sharing, adaptation, distribution and reproduction in any medium or format, as long as you give appropriate credit to the original author(s) and the source, provide a link to the Creative Commons licence, and indicate if changes were made. The images or other third party material in this article are included in the article's Creative Commons licence, unless indicated otherwise in a credit line to the material. If material is not included in the article's Creative Commons licence and your intended use is not permitted by statutory regulation or exceeds the permitted use, you will need to obtain permission directly from the copyright holder. To view a copy of this licence, visit The Creative Commons Public Domain Dedication waiver ( applies to the data made available in this article, unless otherwise stated in a credit line to the data.

Reprints and permissions

About this article

Check for updates. Verify currency and authenticity via CrossMark

Cite this article

Fränti, P., Mariescu-Istodor, R., Akram, A. et al. Can we optimize locations of hospitals by minimizing the number of patients at risk?. BMC Health Serv Res 23, 415 (2023).

Download citation

  • Received:

  • Accepted:

  • Published:

  • DOI: