Global phosphorus recovery from wastewater for agricultural reuse

Phosphorus is a nutrient necessary for the development of crops and is thus commonly applied as fertilizer to sustain agricultural production. It occurs naturally, in indefinite quantities of uncertain quality in phosphate rock formations, but also accumulates in urban and livestock wastewater wherefrom it is often lost as a pollutant. Recovering phosphorus from wastewater, however, is feasible through struvite crystallization technologies and has the potential to reduce phosphorus pollution of the environment as well as lower the agricultural demand for artificial P fertilizers. In this study, we developed a model to assess the global potential of P fertilizer recovery from wastewater and to visualize its trade at sub-national resolution. Results show that humans discharge a maximum of 3.7 Mt P into wastewater, thereby potentially satisfying 20 % of the global fertilizer demand. Provided 2015 market dynamics, however, the model determines that only 4 % of this discharge is technologically and economically recoverable in a market that offers cheap rock phosphate products also. The results of this study demonstrate that in the current economic context, phosphorus recovery from wastewater offers only a small contribution to resolving global phosphorus issues. Nevertheless, this recovery offers many wastewater treatment facilities the opportunity to contribute to creating sustainable communities and protecting the environment locally, while reducing their own operational costs. 1 Importance of phosphorus Phosphorus (P) is an element necessary for the development of all living beings as it forms an unsubstitutable, key structural component of DNA and RNA. It is also a limiting nutrient, and therefore growth is often restricted by the lack of naturally available P. While P-related malnutrition in humans is uncommon, inhibited plant growth due to soil phosphorus deficiency is a much more prevalent issue (MacDonald et al., 2011). For this reason, phosphorus is often applied to croplands in the form of organic fertilizers or synthetically as single or triple superphosphate, or mono-ammonium or di-ammonium phosphate (DAP). These fertilizers are easy to transport and distribute over fields, while also readily absorbed by plants. The most essential resource for the production of artificial phosphorus fertilizers is phosphate rock. The rates at which we exploit phosphate rock formations is out of proportion to the rates at which they form – essentially classifying phosphate rock as a non-renewable resource. Peak production of phosphate ore could occur as early as 2030 (Cordell et al., 2009), with economically extractable P resources becoming scarce or exhausted within the next 50 to 100 years (Smil, 2000; Steen, 1998; Van Vuuren et al., 2010). Other authors predict more optimistically that reserves will last another 300–400 years (van Kauwenbergh, 2010). After this depletion, it will likely be economically infeasible to exploit the remaining ore as it will be too costly to process due to its poor quality (i.e. low phosphorus and high heavy metal content). Gradual depletion of economically extractable reserves will result in further reduction in accessibility to fertilizer by smallholder and subsistence farmers that comprise areas already struggling to Published by Copernicus Publications on behalf of the European Geosciences Union. 5782 D.-J. D. Kok et al.: Global phosphorus recovery from wastewater for agricultural reuse cope with food shortages (Pande and Savenije, 2016). SubSaharan Africa is one such region, as nearly 75 % of its agricultural soils are nutrient deficient, contributing significantly to the crop yield gaps (Sanchez et al., 1997). The prospect of phosphorus depletion ultimately threatens global food security, and regions of poor soil nutrition levels are especially vulnerable to its effects. 1.1 The environment, humanity, and phosphorus The introduction of intensified (P) fertilization during the Green Revolution of the 1960s demonstrated P’s significant potential to improve crop yields but also the dangers it poses to the environment. Through seepage and runoff processes (Bouwman et al., 2009), as well as the discharge of improperly treated wastewater (Van Drecht et al., 2009; Morée et al., 2013), phosphorus and other nutrient excesses come into contact with open surface water. As a limiting nutrient, even the smallest quantity of P in water can spark the growth of large algal blooms. These algal blooms have a detrimental effect on aquatic ecosystems by causing the suffocation of aquatic life through eutrophication, resulting in a loss of habitat and biodiversity (EPA, 2010). Such deoxygenated “dead zones” can be found in both lakes and seas, and affect an estimated 245 000 km2 of marine ecosystems (Corcoran et al., 2010). If excess fertilization and water pollution is a major threat to water quality around the world, then why not extract this excess from the water system and put it back in the food chain? Proper nutrient management practice in tandem with nutrient recovery from rural and urban water systems may potentially be an important strategy to reduce phosphorus pollution by reducing phosphorus discharge to the environment while simultaneously increasing phosphorus supply for food production. There exist a broad range of sources that contribute the phosphorus loads in wastewater. Excrements, detergents, care products, dishwashing liquids, pharmaceuticals, and food preparation wastes are an example of some of the most significant of these. Aside from this, there also exists a multitude of technologically feasible phosphorus recovery options (Egle et al., 2016). Unfortunately, these technologies are often deemed too costly to implement and operate while their recovery efficiencies vary, among others, with local wastewater composition and existing wastewater treatment infrastructure. Adoption of these technologies is therefore often challenged by (perceived) economic infeasibility or lacking economic incentives and social stigma. It must be recognized, however, that the economic feasibility of recovery is not globally homogeneous, but varies in space and time. Spatially, the global accretion of phosphorus in wastewater provides recovered products with a (diffused) location-defined competitive advantage over the geographically concentrated rock phosphate mines (Fig. 1), while temporally, the appeal Figure 1. Estimated global phosphorus reserve distribution. The vast majority (73 %) of estimated natural reserves lie in Moroccan and west Saharan territories (USGS, 2017). for recover will improve over time with the increasing price trends for rock-based fertilizers (e.g. DAP) (Fig. 2)1. 1.2 Turning brown waste to green gold To our knowledge, there exist no studies that evaluate the spatially dependent feasibility for phosphorus recovery from wastewater, at sub-national resolution, in a global and economically dynamic context. Insights provided by such a study, however, could accelerate the efficient transitioning to a more sustainable phosphorus fertilizer market by illustrating where recovery may economically be most feasible. We therefore aim to determine the total phosphorus recovery potential from wastewater, as well as the economic feasibility for this recovery, in a global assessment. This is achieved by integrating geospatial data, statistics, and findings from other studies into a model that identifies and connects phosphorus recovery and demand sites based on location, quantities, and prices. Because of the wide array of pathways to phosphorus recovery, the subject of this investigation is constrained to the recovery of phosphorus from urban and livestock wastewater as a struvite and compost pellet fertilizer product only. Phosphorus lost via other fluxes (e.g. municipal solid waste) are therefore excluded from this assessment. The sole reason for focusing on recovery through struvite crystallization is because of the fertilizer potential of struvite as well as the current industrial-scale implementation of the technology itself (Cornel and Schaum, 2009). 2 Materials and methods The phosphorus cycle is delineated by a combination of both social and physical attributes and as such demands a coupled human–water systems perspective. A socio-hydrological ap1Over the past 15 years the phosphorus price of DAP has increased from 665 to 1552 USD t−1. In that same period, the price has been as high as 5217 USD t−1 (2008) and as low as 656 USD t−1 (2002) (IndexMundi, 2017). Hydrol. Earth Syst. Sci., 22, 5781–5799, 2018 www.hydrol-earth-syst-sci.net/22/5781/2018/ D.-J. D. Kok et al.: Global phosphorus recovery from wastewater for agricultural reuse 5783 Figure 2. Nominal phosphate rock and DAP price trends (IndexMundi, 2017). The rock phosphate and DAP price trend can be characterized as gradually increasing and being vulnerable to market dynamics (i.e. the 2007 global economic recession). proach is endeavoured as both these attributes are here expressively and emphatically accounted for (Sivapalan et al., 2012). The social component, however, of this coupled human–phosphorus system is confined to the characteristics of a distinct economic nature. The materials and methods employed in assessing the recovery potential of P from wastewater at global scale is therefore interdisciplinary and extensive, largely covering economics within a sciences context. In general, the methodology can be summarized to consist of three phases, which are also used to define the order of the materials and methods section: 1. Identification of sites and quantities – identifying the locations of wastewater accumulation sites and agricultural croplands and assessing the potential associated phosphorus production and demand quantities; 2. Determination of node prices – approximating the minimum production costs of recovering P fertilizers at the wastewater accumulation (recovery) sites, and the maximum paying prices for P fertiliz

Abstract. Phosphorus is a nutrient necessary for the development of crops and is thus commonly applied as fertilizer to sustain agricultural production. It occurs naturally, in indefinite quantities of uncertain quality in phosphate rock formations, but also accumulates in urban and livestock wastewater wherefrom it is often lost as a pollutant. Recovering phosphorus from wastewater, however, is feasible through struvite crystallization technologies and has the potential to reduce phosphorus pollution of the environment as well as lower the agricultural demand for artificial P fertilizers. In this study, we developed a model to assess the global potential of P fertilizer recovery from wastewater and to visualize its trade at sub-national resolution. Results show that humans discharge a maximum of 3.7 Mt P into wastewater, thereby potentially satisfying 20 % of the global fertilizer demand. Provided 2015 market dynamics, however, the model determines that only 4 % of this discharge is technologically and economically recoverable in a market that offers cheap rock phosphate products also. The results of this study demonstrate that in the current economic context, phosphorus recovery from wastewater offers only a small contribution to resolving global phosphorus issues. Nevertheless, this recovery offers many wastewater treatment facilities the opportunity to contribute to creating sustainable communities and protecting the environment locally, while reducing their own operational costs.
1 Importance of phosphorus Phosphorus (P) is an element necessary for the development of all living beings as it forms an unsubstitutable, key structural component of DNA and RNA. It is also a limiting nutrient, and therefore growth is often restricted by the lack of naturally available P. While P-related malnutrition in humans is uncommon, inhibited plant growth due to soil phosphorus deficiency is a much more prevalent issue (MacDonald et al., 2011). For this reason, phosphorus is often applied to croplands in the form of organic fertilizers or synthetically as single or triple superphosphate, or mono-ammonium or di-ammonium phosphate (DAP). These fertilizers are easy to transport and distribute over fields, while also readily absorbed by plants. The most essential resource for the production of artificial phosphorus fertilizers is phosphate rock.
The rates at which we exploit phosphate rock formations is out of proportion to the rates at which they form -essentially classifying phosphate rock as a non-renewable resource. Peak production of phosphate ore could occur as early as 2030 (Cordell et al., 2009), with economically extractable P resources becoming scarce or exhausted within the next 50 to 100 years (Smil, 2000;Steen, 1998;Van Vuuren et al., 2010). Other authors predict more optimistically that reserves will last another 300-400 years (van Kauwenbergh, 2010). After this depletion, it will likely be economically infeasible to exploit the remaining ore as it will be too costly to process due to its poor quality (i.e. low phosphorus and high heavy metal content). Gradual depletion of economically extractable reserves will result in further reduction in accessibility to fertilizer by smallholder and sub-Published by Copernicus Publications on behalf of the European Geosciences Union. 5782 D.-J. D. Kok et al.: Global phosphorus recovery from wastewater for agricultural reuse sistence farmers that comprise areas already struggling to cope with food shortages (Pande and Savenije, 2016). Sub-Saharan Africa is one such region, as nearly 75 % of its agricultural soils are nutrient deficient, contributing significantly to the crop yield gaps (Sanchez et al., 1997). The prospect of phosphorus depletion ultimately threatens global food security, and regions of poor soil nutrition levels are especially vulnerable to its effects.

The environment, humanity, and phosphorus
The introduction of intensified (P) fertilization during the Green Revolution of the 1960s demonstrated P's significant potential to improve crop yields but also the dangers it poses to the environment. Through seepage and runoff processes , as well as the discharge of improperly treated wastewater (Van Drecht et al., 2009;Morée et al., 2013), phosphorus and other nutrient excesses come into contact with open surface water. As a limiting nutrient, even the smallest quantity of P in water can spark the growth of large algal blooms. These algal blooms have a detrimental effect on aquatic ecosystems by causing the suffocation of aquatic life through eutrophication, resulting in a loss of habitat and biodiversity (EPA, 2010). Such deoxygenated "dead zones" can be found in both lakes and seas, and affect an estimated 245 000 km 2 of marine ecosystems (Corcoran et al., 2010). If excess fertilization and water pollution is a major threat to water quality around the world, then why not extract this excess from the water system and put it back in the food chain? Proper nutrient management practice in tandem with nutrient recovery from rural and urban water systems may potentially be an important strategy to reduce phosphorus pollution by reducing phosphorus discharge to the environment while simultaneously increasing phosphorus supply for food production.
There exist a broad range of sources that contribute the phosphorus loads in wastewater. Excrements, detergents, care products, dishwashing liquids, pharmaceuticals, and food preparation wastes are an example of some of the most significant of these. Aside from this, there also exists a multitude of technologically feasible phosphorus recovery options . Unfortunately, these technologies are often deemed too costly to implement and operate while their recovery efficiencies vary, among others, with local wastewater composition and existing wastewater treatment infrastructure. Adoption of these technologies is therefore often challenged by (perceived) economic infeasibility or lacking economic incentives and social stigma. It must be recognized, however, that the economic feasibility of recovery is not globally homogeneous, but varies in space and time. Spatially, the global accretion of phosphorus in wastewater provides recovered products with a (diffused) location-defined competitive advantage over the geographically concentrated rock phosphate mines (Fig. 1), while temporally, the appeal for recover will improve over time with the increasing price trends for rock-based fertilizers (e.g. DAP) (Fig. 2) 1 .

Turning brown waste to green gold
To our knowledge, there exist no studies that evaluate the spatially dependent feasibility for phosphorus recovery from wastewater, at sub-national resolution, in a global and economically dynamic context. Insights provided by such a study, however, could accelerate the efficient transitioning to a more sustainable phosphorus fertilizer market by illustrating where recovery may economically be most feasible. We therefore aim to determine the total phosphorus recovery potential from wastewater, as well as the economic feasibility for this recovery, in a global assessment. This is achieved by integrating geospatial data, statistics, and findings from other studies into a model that identifies and connects phosphorus recovery and demand sites based on location, quantities, and prices.
Because of the wide array of pathways to phosphorus recovery, the subject of this investigation is constrained to the recovery of phosphorus from urban and livestock wastewater as a struvite and compost pellet fertilizer product only. Phosphorus lost via other fluxes (e.g. municipal solid waste) are therefore excluded from this assessment. The sole reason for focusing on recovery through struvite crystallization is because of the fertilizer potential of struvite as well as the current industrial-scale implementation of the technology itself (Cornel and Schaum, 2009).

Materials and methods
The phosphorus cycle is delineated by a combination of both social and physical attributes and as such demands a coupled human-water systems perspective. A socio-hydrological ap-1 Over the past 15 years the phosphorus price of DAP has increased from 665 to 1552 USD t −1 . In that same period, the price has been as high as 5217 USD t −1 (2008) and as low as 656 USD t −1 (2002) (IndexMundi, 2017). proach is endeavoured as both these attributes are here expressively and emphatically accounted for (Sivapalan et al., 2012). The social component, however, of this coupled human-phosphorus system is confined to the characteristics of a distinct economic nature. The materials and methods employed in assessing the recovery potential of P from wastewater at global scale is therefore interdisciplinary and extensive, largely covering economics within a sciences context.
In general, the methodology can be summarized to consist of three phases, which are also used to define the order of the materials and methods section: 1. Identification of sites and quantities -identifying the locations of wastewater accumulation sites and agricultural croplands and assessing the potential associated phosphorus production and demand quantities; 2. Determination of node prices -approximating the minimum production costs of recovering P fertilizers at the wastewater accumulation (recovery) sites, and the maximum paying prices for P fertilizers at the agricultural (consumption) sites; 3. Modelling international trade in phosphorus, involving a. Determination of global market price, i.e. determining an international, free-market price for phosphorus as a function of phosphorus quantities and prices, as well as the distances between the different sites; b. Visualizing trade flows, i.e. creating a realistic network of P-trade fluxes at subnational resolution.
The main tools employed in this investigation are Geographic Information System (GIS) tools, used to prepare the spatial data (Q-GIS 2.14) (Quantum GIS Development Team, 2017), and Python 3.6, used to build the trade network model.

Identification of sites and quantities
Phosphorus trade occurs between production and demand sites, and therefore two groups of actors are identified in the model: P producers and P consumers. The first group, P producers, consists of three types of actors: 1. Urban wastewater treatment facilities -nodes recovering P from domestic wastewater (i.e. phosphorus excreted, used, and discharged by humans); 2. Livestock keepers -nodes recovering P from animal manure (i.e. manure and liquid waste produced by farm cows, chicken, and swine, while stabled); 3. Phosphate mines -nodes extracting P from rock phosphate reserves.
The three actor types recover phosphorus in different forms, yet all act on the same phosphorus market. The only objective characteristic that the model will use to distinguish one type of product from another is the absolute elemental P value of the product (i.e. US dollars per mass P; USD mass −1 P). Since both mines and recovery sites have the same purpose in the model (i.e. supplying phosphatic fertilizers), both node types are grouped as "production nodes".

Phosphorus production
The location and phosphorus production quantities of Pproduction nodes are determined by integrating geospatial datasets with statistics and findings from other studies. As phosphorus is not "produced" by organisms, but only consumed and excreted, or used (i.e. detergents), we will refer to the annual amount of phosphorus discharged in wastewater per individual as the "phosphorus throughput rate" (kg head −1 a −1 P). Wastewater phosphorus has variable sources ranging from human excrements to detergents, toothpaste, dishwashing liquids, medicines, food preparation wastes, food leftovers, etc. These sources are not considered individually. Instead we assume that each individual person, globally, offers an equal contribution to the phosphorus load in wastewater. We combine approximations for these rates from different studies with population density maps for humans (CIESIN, 2016), cattle, swine, and poultry (Robinson et al., 2014), to determine the spatial distribution of phosphorus excretion rates globally. This spatial distribution of the mass phosphorus produced per unit area, per annum (kg km −2 a −1 ) represents the phosphorus production density (a map). Its determination per unit area on this map is summarized for as follows (Eq. 1): where S is the maximum organic phosphorus production density (kg km −2 a −1 ), D is the population density (heads km −2 ), P is the phosphorus throughput rate 5784 D.-J. D. Kok et al.: Global phosphorus recovery from wastewater for agricultural reuse (kg head −1 a −1 ), and E is the estimated base recovery efficiency (-). For humans, the phosphorus throughput rate (P ) is assumed to be globally homogeneous, fixed at 0.77 kg head −1 a −1 . This is in close relation to other published findings (0.77, Gilmour et al., 2008;0.78, CRC, 2005;0.2-0.7, Mihelcic et al., 2011;0.7, Smil, 2000). For livestock, the throughput rate (P ) is taken to be a function of slaughter weight (FAOSTAT, 2018) following the methodology of Sheldrick et al. (2003). Manure recovery efficiencies (E) are taken as follows: cattle (31 %), swine (80 %), poultry (77 %) (Sheldrick et al., 2003). For humans, it is assumed that 100 % of the phosphorus discharged as domestic wastewater reaches the treatment facility. The actual recovery efficiencies will vary per recovery technology implemented at the wastewater treatment plants (WWTPs) (Sect. 2.2.). The production density maps for livestock and humans are presented in Fig. S1a and b in the Supplement. As a final step, the phosphorus production densities per land area are converted into point nodes using GIS tools (see Sect. 2.1.3). The spatial variation in recovered P-production potential is therefore marked by global variation in population and livestock densities.
The locations for the P-mining industry are, instead, geographically concentrated. Data on P-production values and mine site locations are acquired from a USGS (2002) dataset. This dataset is adjusted to match the USGS-reported phosphate production estimates for different simulation years.

Phosphorus consumption
Similar to the phosphorus production density, the phosphorus demand density map represents per unit area the yearly amount of phosphorus required by agriculture (kg km −2 a −1 ). It is determined following a comparable methodology to that of phosphorus production, where crop densities, as approximated through crop harvested area maps (Monfreda et al., 2008), are related to phosphorusrequirement rates (UNIDO and IFDC, 1998). The crop phosphorus requirement rates (kg km −2 harvest −1 ) as reported by UNIDO and IFDC (1998), however, are determined for optimal yield. Provided that no farmer is going to fertilize for optimal yield when he or she knows that these yields are unachievable provided persistent regional water limitations, the actual P demand is proportionally reduced to the potential water-constrained yield. This assessment is made for six major crops: maize, wheat, rice, sorghum, soy bean, and potato. The water-constrained yield is determined by adapting the evaporation-transpiration deficit equation (Steduto et al., 2012) to the following (Eq. 2): where Y a is the actual yield (kg km −2 a −1 ), Y m is the optimal yield (kg km −2 a −1 ), K y is the crop coefficient (-), E a is the cumulative actual evaporation-transpiration per year (mm a −1 Area −1 ), T g is the duration of the crop growing period (days), A H is the fractional area harvested (-), E m is the evaporation-transpiration for optimal yield per harvest (mm a −1 km 2 ), and C (-) is a correction factor. In this investigation, E m is assumed to be equal to the crop water requirement for optimal yield. Global approximations of K y and E m values were retrieved for different crops from FAO sources (2015), and E a was approximated from MODIS evapotranspiration products (NASA, 2005). A summary of the data used and their sources is presented in Table S2 of the Supplement. Equation (2) is an adaptation of the original evaporationtranspiration deficit equation. The original equation is designed for a single growing period, yet much of the other input data is yearly. As the beginning and ending of a crop's growing season will vary globally, it is not possible to combine global yearly harvest area maps with monthly evaporation data. Reformulation was therefore necessary to account for a difference in temporal scales of the input data. For the adaptation, it is assumed that of the yearly evaporation, an amount proportional to the duration of a crops growing period is evaporated during the crop growing season (E a · T g 365 ). This value is then further reduced by multiplication with the fractional crop harvested area (A H ) to account for evaporation from other land-cover types in the area as well. Finally, as these simple manipulations introduce a significant error, a correction factor (C) was added to globally scale potential yields greater than optimum (i.e. > 1) back down to optimum (= 1) and to achieve a total, global phosphorus demand that approaches observed values for these crops.
In this investigation, we assume no change in soil-stored phosphorus. The yearly phosphorus demand per area therefore reflects only the crops' yearly phosphorus uptake as a function of a crop's water-constrained yield and harvested area. This phosphorus demand is described as a linear regression between yield and P fertilizer requirement through Eq. (3): where D PT is the calculated phosphorus demand density (kg ha −1 a −1 ), P n opt is the crop specific (n) P requirement for optimal yield (kg ha −1 ), and A H is the crop harvested area (ha −1 ). The parameters per crop are again summarized in Table S2. The six crops evaluated make up roughly 56 % of the global demand (Heffer, 2009). To estimate the global demand quantity, inclusive of all crops, the value of each pixel on the map for the six crops is divided by 0.56 (56 %). Although this method introduces uncertainties to spatial demand distribution, it does allow for a more accurate estimate of the actual, total, global phosphorus demand quantities. The demand density maps for agriculture are presented in Fig. S1c.

From raster to nodes
The areas of major production and consumption densities, determined in Sects. 2.1.1 and 2.1.2, are aggregated into nodes that are described by a coordinate position, a class (group: urban or livestock, or crop type), and a quantity of yearly phosphorus supply or demand. Each node is systematically positioned in the centre of a larger area of uninterrupted high phosphorus production or demand density as determined by the raster map calculations performed in steps 2.11 and 2.12. To avoid the aggregation of administratively separate regions into a single node, the areas of continuous high demand or production density are separated by national boundaries for smaller countries, and first level administrative borders (e.g. states and provinces) for large countries (e.g. USA, India, Russia, Canada). Nodes with a production value of less than 3 kt yr −1 are considered insignificant in the global context and are therefore excluded from further consideration in the economic analysis. This constrains the total number of actors, reduces the complexity of the network, decreases the processing time, and improves visualization of the results. This preselection reduced the global P-recovery quantity by 15 %, while reducing the number of actors by 76 %. The trade model thus only accounts for trade from 24 % of all potential recovery sites, which, nevertheless, represent 85 % of the global recovery potential.

Determination of node prices
Throughout this investigation, prices are presented as the price per tonne of phosphorus in each fertilizer product (USD t −1 ). This is because struvite fertilizers (14 % P), conventional artificial fertilizers (DAP: 22 % P), and compost pellets (1 % P) are, although different in form and P contents, acting on the same phosphorus market. In the model market, they are discriminated only based on their total phosphorus content and, as such, their values are determined based solely on the mass of P that they contain.
Whether trade is possible between a demand and a production node depends on the transportation and production costs of the production node and the maximum bid price of the demand node. Despite three different producers having been identified (Sect. 2.1), each creating their own unique fertilizer products, they are all subjected to the same economic constrictions. The production cost of each producer is defined by (i) an investment cost for infrastructure and (ii) a variable cost per mass P recovered. Additionally, they are imposed with (iii) a transportation cost for selling. The sum of these costs determines how attractive a producer is to the individual, agricultural demand nodes.

Cost for recovery
The cost for recovery (i.e. production cost) varies depending on the recovery technology, whose feasibility for implementation, in turn, depends on wastewater composition and existing infrastructure. In this study, municipal wastewater composition is assumed roughly globally homogenous. The Sustainable Development Goals (SDG) dataset on percentage of urban population with access to sanitation is then used to approximate how well developed the existing sanitary infrastructure is in different parts of the world (WHO/UNICEF JMP, 2015). This estimation is then used as an indicator for the feasibility to implement certain recovery technologies. How the SDG dataset is used to interpret the feasibility for implementation of specific recovery technologies is presented below.
A high national percentage of urban population with access to sanitation (> 90 %) is likely to be indicative of highly developed countries that observe stricter effluent standards and that therefore have, or are working towards upgrading, conventional WWTPs for biological nutrient recovery (BNR) or chemical phosphorus removal. The phosphorus recovery costs for these highly developed nodes are those associated with the investment in a large Ostara ® Pearl Reactor for struvite precipitation. The production cost for this highly developed group is reduced by the savings in uncontrolled struvite scaling maintenance and sludge handling costs that are associated with controlled struvite precipitation (Shu et al., 2006). Although other struvite recovery technologies are available, Ostara ® Pearl Reactors were chosen given their commercially effective implementation in various countries. There exist other recovery technologies that allow for absolute greater recovery amounts (see Egle et al., 2016), but few of these are potentially economically competitive producers of pure P fertilizer products.
Areas with intermediate urban access to sanitation (40 %-90 %) are assumed to be serviced by simple, centralized wastewater treatment facilities. The technology investment cost for these nodes are the same as for the highly developed infrastructure group but excluding this time the sludge handling cost savings. The recovery efficiency is again assumed to equal 20 % of the influent P.
Low urban access to sanitation (< 40 %) is taken to be indicative of low sanitary development and thus offers the flexibility to adopt more novel, less water-dependent forms of sanitation. The technology applied for these areas are source-separating and dry-composting toilets, where urine and faecal compost are collected separately. The urine is collected by 40 000 L tank trucks and processed at a centralized struvite precipitation facility. Faecal compost is collected, dried, and processed into compost pellets, also at a central facility. A 90 % efficiency is easily achieved when struvite is precipitated from source-separated urine (Wilsenach et al., 2007). It is furthermore assumed that all of the faecal phosphorus is retained in the composting, drying, and pelletization processes.
For livestock nodes the collected manure is also composted, dried, and pelletized. As opposed to the sourceseparated faeces of dry composting toilets, the pelletization of manure from livestock farms occurs not at a centralized facility, but on-site. This is assumed feasible provided the high volumes of manure produced by livestock in comparison to humans.
For all production nodes, a generalized phosphorus recovery cost can be described as follows (Eq. 4): where f i min is the minimum price for phosphorus produced at node i (USD t −1 ), R is the variable cost per tonne of P recovered (i.e. the magnesium cost for struvite precipitation; the pelletization cost for compost pelletization) (USD t −1 P), B fixed operational cost (USD), and S PT is the total phosphorus recovery potential (t). Furthermore, where relevant, S is the struvite scaling and sludge handling cost savings per tonne of P recovered (USD t −1 P) (i.e. for BNR plants), T i is the intracity transport cost of collection [USD t −1 ] (i.e. for urine and faeces from source-separating toilets), and ρ is the proportion of phosphorus by weight of the transported material (kg kg −1 ), which are 0.066 % and 0.46 % for urine and dried, faecal, and toilet compost respectively (Vinnerås, 2001). The annual fixed operational costs are taken as the annual costs minus the resource costs as reported in the dissertation of Egle (2016), TU Wien. For BNR plants, a struvite and sludge handling cost savings is included as 0.89 USD kg −1 of struvite removed (Shu et al., 2006). This essentially allows BNR plants to supply struvite for free (excluding transportation costs), which is a common occurrence for struvite-precipitating BNR WWTPs in the Netherlands. The additional variable cost for the dry-toilet solution is attributed to the collection of waste and a pelletization cost of 30 USD t −1 compost (Hara, 2001). A summary of these and other data values are presented in Tables S3, S4 and S5.
The intracity transport cost T i is described as follows (Eq. 5): where D ta is the average distance of a return journey for a tanker truck in servicing the city per full load (km), P d is the price of diesel (USD L −1 ), E Lt is the fuel efficiency of the tanker truck (L km −1 ), L ct is the labour wage (USD head −1 ), V Lt is the average velocity of the truck in the city (km head −1 ), and W Lt is the truck load weight (t). The transportation cost from the processing facility to the consumer is included in the final sale price (USD t −1 ) of the producer and is therefore not accounted for yet at this stage.

Maximum buyer bid price
The maximum price that demand nodes are willing to purchase phosphorus at depends on the marginal value of phosphorus. This varies per crop type and can be described as follows (Eq. 6): where f n max is the maximum price for phosphorus (USD t −1 ), Y n opt is the optimal yield (t ha −1 ), C n a is the crop price in year a (USD t −1 ), P n opt is the optimum fertilizer dosage rate (equal to total P requirement for optimal, water constrained yield) (t ha −1 ), and R n is the ratio of fertilizer cost to total production costs (-), for crop n.

Transportation cost
Lastly, the transportation costs between the production and demand sites are determined with as-the-crow-flies distances and the parameters given in Table S3 substituted into the following transport cost equation (Eq. 7): where T i,n c is the transportation cost from node i to node n (USD t −1 ), D i,n is the distance between node i and node n (km), P b is a bunker fuel price (shipping fuel) (USD t −1 ), P d is the price of diesel (USD L −1 ), E W is the fuel efficiency of a container mainliner ship (t d −1 ), E L is the fuel efficiency of a 2 × 30 tonne truck combination (L km −1 ), C F is the fixed costs per ship (USD d −1 ), L c is the labour wage (USD head −1 ), V W is the average velocity of the ship over water (km d −1 ), V L is the average velocity of the truck over land (km head −1 ), W W is the full ship weight (t), and W L is the full truck weight (t). F W and F L are the fractions of the total distance that is travelled over land and over sea. The model at present does not distinguish between the transportation over land and over sea based on observed geography. Instead the model employs a cumulative probability curve that approximates the proportion of the total distance likely to have been traversed over water, F W (Eq. 8); and over land, F L (Eq. 9). It is assumed that at least 15 % of the total dis-tance is always traversed over land.
where µ and S are function shape constants of 500 and 100 (-), respectively.

Trade model
A model is constructed to determine (i) the market price for international phosphorus trade and (ii) what amounts of phosphorus are being traded between which nodes. Market prices emerge as a function of the individual productionconsumption prices and associated supply-demand quantities, which will vary depending on which actors are included in the market scenario. The phosphorus recovery potential is therefore assessed for three different combinations of actors that represent, respectively, the current, potential near-future, and potential far-future markets: 1. Current market -mine-supplied products only. The current phosphorus market is strongly rock-phosphate oriented. When the model runs the data for a "current market" scenario, only rock phosphate products are available on the market. This scenario serves mostly a model validation purpose.
2. Future market -both mine and recovered products.
Recovered phosphorus may become a more important product in the future market. When the model runs the data for a "future market" scenario, it is assumed that both rock phosphate as well as recovered phosphorus products partake.
3. Far-future market -only recovered products. In the farfuture market, most rock phosphate reserves will have been depleted. When the model runs the data for a "farfuture" scenario, it is assumed that rock phosphates no longer take part in the market, which is then solely dominated by sustainable, recovered products.

Determination of global market price
The global market price is determined as the price at which total quantity of phosphorus demanded (sum of agricultural demand quantities) is equal to the quantity supplied (sum of P-production quantities). It is approximated as the point where global demand function (defined as cumulative phosphorus demand vs. maximum buying price) intersects the global supply function (cumulative phosphorus production vs. production price). The demand function is the locus of the maximum prices at which demand nodes are willing and able to purchase phosphorus, and the supply function is the locus of the minimum prices at which supply nodes can sell certain amounts of phosphorus without going out of business (i.e. without making a loss). Where the two curves intersect, the market for P is cleared, providing a best approximation of the market price (Arrow and Debreu, 1954). The Supplement text provides an illustration of how market prices for the three scenarios are determined following this principle, and how transportation costs complicate this method of price determination.

Quantification of trade flows
The quantity of phosphorus traded for each scenario is determined following a method of reduction and elimination. Firstly, a list of all possible combinations of supply and demand nodes is created. Each combination of supply and demand nodes is passed through two "filters" that removes some pairs on the basis of simple conditional statements. This reduces the list down to a selection of trading node pairs for each market scenario, for each year. Before anything, the first filter in the model removes the pairs that can never trade with each other based on their combination of the minimum production costs, the maximum bidding price, and transportation costs associated with the data of that year (e.g. fuel cost, wastewater flows). The second filter then removes node pairs which cannot trade with each other at a given "hypothetical market" price imposed on the network. Either the production cost may be above the imposed market price or the maximum bidding price may be below it, implying that the nodes cannot trade. If both the production cost is below the imposed market price and bidding price is above it, then the node pair is left in the list for that "theoretical" market price. After these two filters, the list of potential trade partners is reduced significantly and assessment may be made as to whether the saved pairs actually trade and then with what quantities.
In the model, phosphorus consumers will look for the cheapest suppliers. The matter becomes obscured here as, in reality, there are no cheaper or more expensive suppliers for a single market price. Supply nodes that could, however, supply at prices far lower than the set market price (due to lower production costs) have a competitive advantage over those that cannot. At the same time, agricultural demand nodes that are willing to pay much more than the hypothetical market price have a greater financial capacity to outbid those agricultural nodes whose maximum bid price is much closer to the hypothetical market price. The difference between this market price and (i) the production and transportation costs for production nodes and (ii) maximum bid price for demand nodes shows how competitive a node pair is. If a node is able to produce and transport at prices much lower than market price, and if a demand node is able to pay much more than the market price, then the model assumes that trade between these most competitive nodes occurs first. Therefore, the list of remaining node pairs is sorted according to the greatest difference between production + transport cost, and maximum bid price, with market price.
For each of node pair lists for the different "hypothetical market" prices, trade is executed and the list updated. After each trade, the list is updated in terms of total phosphorus quantity (Q) demanded by demand node (D) number n, or supplied by supply node (S) number i (D n Q , and S i Q , for demand and supply respectively). The amount traded (Q (i,n) ) between each node pair is taken to be equal to the minimum of supply or demand as formulated below (Eq. 10): The supply available and quantity demanded at each supply demand nodes are updated as follows (Eq. 11), By Eq. (11), one of the nodes will have 0 production capacity or demand after each trade, and so all possible trade combinations with that node are removed from the list of possible trade partners remaining for that hypothetical market price. The trade is recorded in a separate list of "successfully executed trades". This process is continued until the list is empty and thus all feasible trade for that price has been conducted. Plotting the cumulative phosphorus trade for each hypothetical market price simulated results in a combined version of the supply and demand curves of Sect. 2.3.1, where the apex coincides with the determined market price. The trade pairs saved in the list of "successfully executed trades" are then connected through a series of coloured vertices on maps to visualize the trade network.

Simulation years
The model is set up using human population density, livestock population density, and croplands data for 2005. These data are adjusted using constant growth rates when simulating other years. For example, in extrapolating the human population density (CIESIN, 2016), and therefore phosphorus production potential, from 2005 to another year, the models employs the following equation: where P y is the population density for an area in year y, P 2005 is the population density for an area in 2005, and 0.0122 represents the 2005 to 2015 averaged, global human population growth rate of 1.22 % per year (World Bank, 2017). The social phenomena of migration and urbanization are not considered in the process. Also, contrasting growth rates of the different areas of the world are lost, as by this definition the population in each node, everywhere, grows equally. A summary of this yearly data and its sources is presented in Table S4. This is followed up by Table S5, which presents an overview of most fixed parameters.
The model script is accessible from the DANS data repository (Kok et al., 2017).

Phosphorus recovery potentials excluding economic dynamics
The phosphorus recovery potential can be assessed in three different ways depending on the constraints imposed. Firstly, and most simply, the sum of all global production densities (Sect. 2.1.1) provides an indication of the total potential of recovering all excreted phosphorus, everywhere, without regard for any economic dynamics. For 2015, these are determined to amount to 3.7 Mt P a −1 P for humans, and 17.39 Mt P a −1 for livestock. Recovering all urban phosphorus discharged as wastewater can thus potentially satisfy 20 % of the 19.1 Mt a −1 calculated agricultural demand. Recovering all phosphorus in animal manure can potentially satisfy 90 % of the total agricultural demand. The recycling of all animal manure and human excreta confirms the large potential of recovery to substitute phosphorus fertilizers ). Unfortunately, however, it is not feasible to recover every ounce of phosphorus excreted or to fertilize every crop patch everywhere. More realistically, recovery will be efficient in areas of high population or livestock density, while fertilization will mainly benefit areas of intensive agriculture. By imposing a size constraint on the nodes determined from the phosphorus density maps (Sect. 2.1.3), a more realistic assessment of the contribution of recovered products to the global P demand can be made. For 2015, the phosphorus recovery potential from high density urban sites is estimated at 1.73 Mt P a −1 , which is 48 % of the original 3.7 Mt P a −1 . This percentage approaches the percentage of global population urbanized (54 %; World Bank, 2018), partially confirming that this constraint indeed excludes smaller rural areas, thereby limiting recovery to the high-potential urban sites only. Recovery from livestock is reduced from 17.39 to 8.8 Mt P a −1 , now accounting only for the most intensive animal husbandry sites in the world. With a demand of 16.81 Mt P a −1 from areas of intense agriculture, approximately 10 % and 52 % of the demand may be satisfied by recovery from urban wastewater and livestock, respectively (62 % total), while still excluding any economic dimension.
The results of these optimistic recovery potentials are summarized, per continent, in Table 1. Some continents (i.e. South and North America) show significant disproportionalities in recoverable P from waste vs. phosphorus demand for crop production. The "virtual" phosphorus trade (e.g. soy bean products) can play an important role in determining these continental budget surpluses and deficits. In the end, however, the total phosphorus budget is only slightly off balance at 109 % of the total production potential to demand for Table 1. Approximate continental phosphorus budgets associated with maps. The "total" values represent an estimation of recovering all phosphorus on the continent, while the "major nodes" values represents that which can be recovered at sites of high potential only.

Livestock production
Human production Agricultural demand the density maps. This global 9 % surplus suggests that there is an inherent overestimation of the phosphorus production (excretion) or underestimation of the demand (agriculture), or that some degree of soil nutrient mining by the crops is considered in the phosphorus requirement values presented in "Fertilizers and Their Use" (FAO and IFA, 2000). Another explanation for this disproportionality is that non-agricultural consumers of phosphorus (e.g. medicine and detergents industries) are not considered as actors even though their consumed products are included in the wastewater discharge figures. The 9 % overestimation could suggest a 9 % share of these actors in the global phosphorus market. Including these actors would raise the demand and likely close the deficit.

Phosphorus recovery potentials including economic dynamics
Phosphorus quantities, prices, and the distances between the nodes are used to determine market prices at which phosphorus trade may occur globally. This is used to assess the more realistic, spatially dependent, and economically constrained phosphorus recovery potential. The production costs for phosphorus for the different actors are summarized in Fig. 3. In a 2015 market where sustainable products compete with rock-based fertilizers (scenario 2), the model determines that approximately 0.15 Mt can be economically recovered, thereby satisfying 0.8 % of total agricultural demand. In a market without rock-based fertilizer products, approximately 7.92 Mt can be economically recovered, satisfying 41 % of the total agricultural demand. Due to differences in total supply and demand amongst the scenarios, both the market prices and total quantities traded will vary. Optimal trade in a near-future scenario of recovered and mined phosphorus products (scenario 2) occurs at a market price of 2039 USD t −1 . For a market of only recovered products (scenario 3), where there exists a strong deficit in phosphorus supply for agriculture, optimal trade occurs at much higher Figure 3. Minimum calculated production costs per tonne of recycled P for supply nodes. Urb1-Str shows the prices for struvite from WWTP in countries with highly developed sanitation systems (BNR), where the struvite is offered for free (excluding transport costs) because of the maintenance and sludge handling savings by controlled struvite precipitation, Urb2-Str is from nations with slightly less developed sanitation systems, Urb3-Str shows sourceseparated urine collection and struvite precipitation in nations with underdeveloped sanitation systems, Urb3-Pellets is the price per tonne of P (0.1 %) in urban compost pellets, and Livestock shows the price per tonne of P in livestock pellets (0.1 % P).
prices of 5700 USD t −1 . The model price and trade determinations for 2015 and other years are summarized in Table 2.
Associated with these quantities and prices are network trade maps. Although easily created for every year and for every price, only those relating to scenario two and three, for 2015, are presented in Figs. 5 and 6, respectively. The high recovery potential and close proximity of recovery nodes to  agricultural demand nodes makes phosphorus recovery in Asia particularly competitive in both scenarios. The struvite scaling maintenance and sludge handling cost savings in developed areas (with BNR-equipped WWTPs) also results in competitive trade in Europe and the United States. Because compost pellets, which due to their low P density are far more expensive per tonne of phosphorus than other products, the market prices for phosphorus are driven upwards in the third scenario. This is a result of the model economics, where the different commodities (struvite vs. compost pellets) are treated as products acting on the same market -discriminated only based on their phosphorus content. When struvite producers observe consumers buying the relatively expensive (USD per amount of P) compost pellets due to the depletion of struvite suppliers, the initial struvite sellers will adjust their prices upwards, forcing consumers to pay more for the same amount of P simply because they can (they are profit driven). The inverse would be true also if agricultural consumers observed cheaper trades occurring among other actors. They would then demand lower prices from their pro-ducer or switch producer all together, resulting in lower market prices.

Model validation and sensitivity assessment
Due to the hypothetical nature of global phosphorus recovery from wastewater, model performance can only be assessed by comparing the quantities and prices produced by the model for the "mines-only scenario" (scenario 1) with observed and recorded DAP price statistics. These prices, along with the results for the other two (more hypothetical) modelling scenarios, are presented in Fig. 4. The graph of Fig. 4 shows that the model is able to adequately reproduce DAP price trends.  . The ends of the whiskers on the grey boxes for the observed prices represent the maximum and minimum prices for DAP that year, the box itself shows the upper and lower quartiles for that data, and the orange line indicates the median. For the modelled scenario the whisker-ends show the maximum and minimum prices as approximated by the model, the box indicates the most likely price range, and the orange line marks the most probable price given supply-demand ratios. Noticeable is that the model price determinations for the current mines-only scenario are in close proximity with observed price ranges. Scenario 2 and 3 are hypothetical scenarios and therefore do not have a realistic counterpart dataset that can be used for comparison. Nevertheless, they show predictable and realistic behaviour. Model sensitivity is determined through the one-at-a-time (OAT) method. Following this technique, the value of one parameter is adjusted and the model is re-run to evaluate how significant the change in model output is as a result of the parameter change. For each of the individual 31 parameters or input data, we assess how sensitive the model is to a −50 % to +50 % change in original value. We assess the impact of this change for the model-determined (i) total phosphorus trade, (ii) sustainable phosphorus trade, and (iii) optimal market price, for a 2015 market of both recovered and mined products.
The sensitivity analysis shows variable sensitivity to changes in parameter (Table S7 and Fig. S3). Provided that each different year has different input data, these sensitivi- Figure 6. Phosphorus trade network for trade in recycled P only (scenario 3) at determined phosphorus market prices of 5700 USD t −1 with 7.92 Mt being traded. All of this trade is sustainable but is only able to accommodate 41 % of demand. ties will likely also vary depending on the simulation year. For example, in a year where rock phosphate exploitation costs are high (e.g. 2008), the market may be much more dependent on recovered products than in other years. The total phosphorus trade will then likely fluctuate much more with the price of, for example, magnesium chloride, than determined in the sensitivity analysis conducted for 2005.
There is a high sensitivity of the optimal price and quantity of sustainable trade with variations in transport parameters related to overseas transport (Table S7). By far the most sensitive parameter is a ship's carry load. A 50 % decrease therein, for example, may result in up to 85 % increase in phosphorus prices. The second most sensitive is a ships velocity, where a 50 % decrease results in 42 % higher prices. Unfortunately, there is also high uncertainty around these parameters as there are innumerable shipping options (ship loads, ship fuel efficiencies, costs, etc.) for the transport of phosphorus overseas. Oppositely, the model results are shown to be insensitive to changes in recovery parameters, suggesting that at global scale the transportation cost of products have a much greater weight in determining the feasibility for trade than the production costs do. Also, the relatively small contribution of urban recovered P (maximum 10 % of global P demand, Sect. 3.1) may be a reason why the global P market prices are so insensitive to small changes in the parameters that determine the P-recovery cost.

Discussion
Many generalizations, assumptions, and simplifications have been made in this study. The lack of consideration for immediate on-site recycling, transatlantic movement, assumptions of free trade, and other economic simplifications are among those possibly contributing to errors in market price determination and patterns of trade flow. Furthermore, external costs such as those associated with environmental impacts (e.g. CO 2 emissions and energy requirements) for the various fertilizer production/recovery chains has been neglected to keep the economic analysis simple. Including these costs would likely significantly improve the favourability of phosphorus recovery from wastewater considering the reduced transportation distances and relatively CO 2 -neutral recovery technologies (Molinos-Senante et al., 2011). Many of the assumptions of this study are partially justified by the global and explorative nature of this investigation on potentials. An overview of all significant assumptions and their possible implications are presented in Table 3.
The lack of studies on the global economic potentials for recovery and phosphorus trade patterns at subnational resolution inhibits comparison of this study's primary results. The model results on total potentials and struvite pricing, however, are well aligned to those of other studies. Above we determined that in 2015, 3.7 Mt a −1 of phosphorus is discharged into wastewater, satisfying 20 % of the reported 18.52 Mt a −1 agricultural demand (Heffer and Prud'homme, 2016) and 19 % of determined 19.51 Mt a −1 agricultural demand. Smil (2000) found 3 Mt a −1 to be potentially recoverable, which would account for 20 %-25 % of the global agricultural demand. Extrapolating Smil's (2000) figure proportionally with a population growth of 1.22 % per year would result in a potential urban production of 3.6 Mt a −1 in 2015, a less than 3 % difference from the model-determined potential. Mihelcic et al. (2011), through a study on diets and phosphorus excretion, concludes that the phosphorus excretion rates per individual can vary as much as from 0.18 kg P a −1 in Table 3. An overview of the assumptions made in this study and their possible implications on the results.

Methods
Assumption In reality Implication

Production and demand estimates
Crop phosphorus requirement only varies with crop type and water-constrained yield.
A particular crop yield may be constrained by other factors than water availability (e.g. soil acidity levels, micronutrient levels, management practices, etc.), also influencing the actual phosphorus demand.
Crop phosphorus requirements also depend on soil-dynamic processes determining leaching rates and sorption.
The phosphorus demand quantities will be spatially more variable and are likely overestimated.
Domestic wastewater composition is globally homogeneous, and its quantity only varies with population density.
Wastewater composition and amount vary amongst different populations. Both quantity and quality factors of wastewater depend on the amount and nature of connected industries and lifestyle characteristics of the people connected (e.g. diets and detergents use), the regional climate, and whether or not the sewerage network is a combined or separate system, etc.
Recovery efficiencies will likely be lower, provided the current assumption of western lifestyles, globally.
We can approximate the type of wastewater treatment practiced in a country based on data that show the percentage of urban population that have access to sanitary facilities.
The type of wastewater treatment at a node varies with many different socio-economic (and natural) parameters. It can hardly be approximated by using a single dataset.
Even in the near future, few people in developing countries will have access to sanitation resulting in an even lower recovery efficiency of phosphorus from developing regions than is currently predicted.
Phosphorus recovery efficiency is determined solely by the recovery technology.
Phosphorus recovery efficiency varies not just per technology, but also with the wastewater composition.
Node-specific phosphorus production potentials can potentially be higher or lower than is currently determined.
Phosphorus throughput per individual is globally homogeneous.
Phosphorus excretion rates vary enormously depending on age, diet, and gender of the individual. Phosphorus discharge relates also to population lifestyles which determine the diet (as described above) but also detergent use.
Node-specific phosphorus production potential is lower in developing countries than is currently determined.
Assume container ship as sea transport mode.
Bulk trade occurs in bulk carriers. Depending on how finished the product is (e.g. bagged and sealed as a ready-to-apply fertilizer), it may also be transported by containerships.
The sea transport cost of P can be highly variable. Trade patterns can look different depending on international politics.
Non-preferential trade Trade is not purely rational. Some countries or actors may be more or less likely to trade with each other depending on historical and current relations.
Trade patterns can look different depending on international relations.
Two actor trades Phosphorus extraction from phosphate rock and its processing into artificial fertilizers may not occur at the same site, nor by the same actor.
Often it involves many more parties. One for exploitation, for manufactory, for logistics, etc.
Trade patterns are simplified, showing only the path from site of initial production to site of final demand.
Transportation distances are calculated as straight lines as opposed to following existing infrastructure.
Phosphorus transport in reality follows existing shipping routes and road infrastructure.
The model likely underestimates the transportation cost of moving phosphorus from supply to demand areas. However, it does so consistently for both recovered as well as mined products. This nevertheless reduces recovery potential estimates. International trade is not restricted by cartographic boundaries.
Few implications for the simulated years as trade in phosphorus between the Americas and Asia is unlikely to occur due to the greater distances and relatively balanced continental phosphorus budget of North America.
Near-future and far-future scenarios do not consider development of technology.
Existing technologies are likely to become cheaper and more efficient in the future, while new technologies may also be developed.
Recovery will rates will likely be higher in the future, thereby also reducing the price of phosphorus. However, provided the uncertainty around making technological development predictions, we decided to exclude this factor from our analysis.  Morée et al. (2013) determines a P discharge of 0.2 to 1.0 Mt P a −1 from urban wastewater over the period 1950 to 2000. These are lower estimates than the ones produced in this study, suggesting that our assumptions of (i) everyone being connected to some form of sanitary infrastructure and (ii) everyone discharging phosphorus according to western throughput figures is unrealistically optimistic even for nearfuture scenarios. However, Morée et al. (2013) also determines that, over that same period, 0.08 Mt P a −1 was recycled back to agriculture, which is lower, but in a similar range to our estimated economic recovery potential of 0.13 Mt P a −1 for 2015. Bouwman et al. (2013), also using slaughter weights, determined that 17 Mt P a −1 is produced by livestock in 2000, closely matching the model-determined 17.11 Mt a −1 . Bouwman et al. (2011) notes the potential for recovery in industrialized countries, which is in line with the general trade patterns presented in Fig. 5. Koppelaar and Weikard (2013) estimate 4.2 Mt P a −1 domestic discharge, which is 25 % of their 16.7 Mt P a −1 agricultural demand. They also estimated total domestic animal manure production of 28.3 Mt P a −1 . This is distinctly higher than this study's 17.11 Mt P a −1 from livestock. This is likely in part due to the fact that they account for a much larger variety of livestock types than the cattle, poultry, and swine considered in this study.
The model estimates struvite production costs ranging from 0 to 670 USD t −1 , variable with the nature and location of the recovery site ( Fig. 3; converted prices 2 ). Phosphorus market prices for a market that also offers rock phosphate products range from 273 to 391 USD t −1 over the different years ( Fig. 4; converted prices). The supply deficit resulting from a scenario without rock phosphate products, drives these sale prices upwards to a range of 570 to 955 USD t −1 . These costs and prices, like the recovery potentials, are difficult to compare provided no found study has evaluated the prices for economic recovery potential at global scale. Instead, there exist case studies on the feasibility for phosphorus recovery at specific sites. Ueno and Fujii (2001) observed that struvite obtained from wastewater in Japan is sold to fertilizer companies at rates of 300 USD t −1 . A market study by Münch and Barr (2001) revealed that struvite can be sold in Australia for between 220 and 370 USD t −1 . Shu et al. (2006), however, estimated that the market price of struvite is around 550 USD t −1 . Based on fertilizer market estimation, Dockhorn (2009) estimated far higher prices than those mentioned before, and values recovered struvite at 900 USD t −1 . Dockhorn's high recovered product prices are approached in the model by the 2015 struvite market price, 955 USD t −1 , for a market scenario with no rock phosphate competition and a severe P supply deficit. It appears that the model-determined price range for global 2 Prices in this study are mostly represented as US dollars per tonne of phosphorus. For comparison purposes, we can convert these to DAP prices through multiplication with DAP's P density (24 %), or to struvite prices through multiplication with struvite's P density (14 %). struvite production covers the spectrum of different production costs, as determined in various different other studies.
In this investigation we consider struvite precipitation as the primary means to recover phosphorus from wastewater. In reality, there are many other recovery technologies that also offer high recovery rates (Cordell et al., 2011;Egle et al., 2016). It would be an interesting follow-up study to adapt and run the model for different phosphorus recovery technologies and visualize changes in trade patterns for the different phosphorus products.

Conclusion
Despite the simplifying assumptions, the model developed in this study generates realistic trade networks for different phosphorus supply scenarios, for different prices, at a subnational resolution. However, the credibility of model outputs is only supported by an accurate simulation of DAP prices because data and/or other studies on the purely hypothetical nature of global trade in sustainably recovered P are lacking. Nevertheless, the model sets a basis that provides some general indication of the spatially dependent recovery feasibility of phosphorus from wastewater. It is furthermore able to provide this indication for potentially any recovery technology for which there exists adequate economic data.
Model results reveal a relatively minor potential of economically profitable struvite fertilizer production from wastewater. This recovery thus appears to offer a limited contribution to resolving the global phosphorus issues of the 21st century. Nevertheless, at a more local scale , this recovery offers wastewater treatment plants the opportunity to contribute to creating sustainable communities and protecting the environment, while reducing their own operational cost. This potential exists foremost in the highly populated cities of developed countries.
Although recognizing that there is no single solution to solving phosphorus pollution and insecurity issues (Cordell and White, 2011), recovering phosphorus from all waste sources may come to provide a greater contribution as populations grow and urbanize, technologies develop, and the economically extractable phosphorus reserves deplete. For this reason, it is essential to determine how the widespread implementation of recovery technologies impacts phosphorus market dynamics. Only then can we stimulate and regulate its recovery in such a way that maximum benefits are achieved for both the environment and the urban community, as well as the livestock and agricultural sectors.
Data availability. The model script and a selection of the final results has been made publically accessible in the DANS-Easy data repository under https://doi.org/10.17026/dans-286-6b5v (Kok, 2017).