A Proposed Land Exchange Algorithm for Eliminating the External Plot Patchwork

: In many countries of the world, rural areas are characterized by a defective spatial structure of agricultural land. The most frequent defects are large fragmentation and distribution of farmland. The fragmentation of land has been an issue widely described by many authors throughout the world. The problem of the distribution of land owned by individual farmers is slightly different, since due to the complexity of the problem this issue was not widely explored in Poland (plot patchwork) or in other countries of Europe and the world. Land fragmentation and distribution of plots in rural areas has a negative effect on the proﬁtability and efﬁciency of agricultural production. Land consolidation and exchange is an operation facilitating spatial structure improvement. The authors attempted to develop a universal land exchange algorithm for eliminating the external plot patchwork. As it turns out, so far no land exchange algorithm has been developed. Speciﬁc analyses were carried out in Puchacz ó w commune, county of Ł˛eczna, Lublin voivodeship in the eastern part of Poland, covering an area of 6907.80 ha, split into 15,211 plots. The chequerboard arrays method was used. The publication presents the algorithm and its practical application using a test sample. A result of the studies is a proposal concerning the exchange of land between landowners in the villages of the commune of Puchacz ó w. Using the algorithm, the area of individual lands in the commune, after the exchange, will increase by 172.09 ha, which is 2.5% for the area of individual lands, and 1.9% for the commune.


Introduction
The excessive fragmentation of plots owned by a farm is one of the major factors adversely affecting the profitability of agricultural production [1]. The spatial arrangement of land owned by individual farmers in the rural areas of southern and southeastern Poland, developed by historical processes, is characterized by farms covering a small area of land and made up of fragmented and scattered plots. Fragmentation of plots, or in other words land fragmentation, is discussed both in the domestic literature [2][3][4][5][6][7][8][9][10] and international references [11][12][13][14][15]. Normally, excessive fragmentation of land has its roots in history and social and economic reality [10]. The present-day plot boundaries are a result of long-term transformations. In the reference literature, four types of land fragmentation are distinguished depending on the type of use, form of ownership, and geometric structure of plots (area, number of plots per farm, plot shape, plot elongation, lack of access to the plot, and distance from the farmer's dwelling) [12]. All the above-mentioned defects have a Land 2021, 10, 64 3 of 15 the chequerboard arrays method which makes it possible to identify the land of out-ofvillage non-resident owners and that of local non-resident owners. The analysis covered all villages within the study area and three matrices were prepared for: The area of land, number of plots, and owners. Determining the area covered by the land of non-resident owners is essential to ensure the correct consolidation of land for the purposes of land exchange. The previous land consolidation works involved only a study of out-of-village non-resident owners in the village being consolidated, which does not form a basis for land exchange prior to consolidation. The commune of Puchaczów was selected for further specific surveys.
Specific surveys were carried out in eastern Poland in Lublin voivodeship, county of Łęczna, commune of Puchaczów ( Figure 1). The study area is situated east of the city being the seat of the county. It consists of 15 villages. The surface area of the commune is 9158.0 ha, which accounts for 14.4% of the county surface area. The area of the commune is divided into 18,052 plots, each having an average surface area of 0.51 ha. At 31 December 2019, the commune had 5403 residents and a population density of 59 people per 1 km 2 , which is less than the mean population density in Lublin voivodeship. The commune was selected on purpose since it is situated within the zone of impact of the municipality of Łęczna (county town) and the village of Bogdanka where a hard coal mine is located. These two locations specified above have a significant impact on the spatial structure of the private land. Therefore, the existing structure of fragmentation and dispersion of plots in the villages of that commune was analyzed in connection with the objective of the surveys, that is, determining the size of the plot patchwork and identifying the possibilities of eliminating the patchwork. The spatial location of the study area is illustrated in Figure 1.

Study Area
General studies regarding the land of non-resident owners were carried throughout the county of Łęczna [7]. The overall area of the county (district) is 637 km 2 and consists of six communes (communes). The study of the size of land of non-resident owners used the chequerboard arrays method which makes it possible to identify the land of out-ofvillage non-resident owners and that of local non-resident owners. The analysis covered all villages within the study area and three matrices were prepared for: The area of land, number of plots, and owners. Determining the area covered by the land of non-resident owners is essential to ensure the correct consolidation of land for the purposes of land exchange. The previous land consolidation works involved only a study of out-of-village non-resident owners in the village being consolidated, which does not form a basis for land exchange prior to consolidation. The commune of Puchaczów was selected for further specific surveys.
Specific surveys were carried out in eastern Poland in Lublin voivodeship, county of Łęczna, commune of Puchaczów ( Figure 1). The study area is situated east of the city being the seat of the county. It consists of 15 villages. The surface area of the commune is 9158.0 ha, which accounts for 14.4% of the county surface area. The area of the commune is divided into 18,052 plots, each having an average surface area of 0.51 ha. At 31 December 2019, the commune had 5403 residents and a population density of 59 people per 1 km 2 , which is less than the mean population density in Lublin voivodeship. The commune was selected on purpose since it is situated within the zone of impact of the municipality of Łęczna (county town) and the village of Bogdanka where a hard coal mine is located. These two locations specified above have a significant impact on the spatial structure of the private land. Therefore, the existing structure of fragmentation and dispersion of plots in the villages of that commune was analyzed in connection with the objective of the surveys, that is, determining the size of the plot patchwork and identifying the possibilities of eliminating the patchwork. The spatial location of the study area is illustrated in Figure  1. The existing structure of fragmentation and dispersion of plots in the villages of the commune of Puchaczów was analyzed in connection with the objective of the surveys, that is, determining the size of the plot patchwork and identifying the possibilities of eliminating the patchwork. The determination of the size and its treatment revealed possibilities for land exchange. From a technical point of view, it is possible, but the basic criterion was making these possibilities real. In previous consolidation works until 1982, the external patchwork of plots owned by private individuals in the village could not be eliminated The existing structure of fragmentation and dispersion of plots in the villages of the commune of Puchaczów was analyzed in connection with the objective of the surveys, that is, determining the size of the plot patchwork and identifying the possibilities of eliminating the patchwork. The determination of the size and its treatment revealed possibilities for land exchange. From a technical point of view, it is possible, but the basic criterion was making these possibilities real. In previous consolidation works until 1982, the external patchwork of plots owned by private individuals in the village could not be eliminated in the process of land exchange [33]. With the above-mentioned act, the legislator narrowed the notion of land exchange to the state-controlled economy only (farmer-state-controlled economy). In the process of consolidation, the problem of external plot patchwork was only partly corrected by bringing the land of non-resident owners to the boundaries of the village which they came from. Such solutions not only did not improve the management conditions but also partly deteriorated access to newly subdivided plots.
The act on consolidation and exchange of land [34] allows individuals to exchange their plots. However, the previously completed consolidation works did not involve land exchange, which can also be observed in the study area. In order to accomplish the adopted aim of the study, data from the land and buildings register was used as the study material. The descriptive part of the land and buildings register provided information on: Ownership and use of land, soil quality classes of private agricultural land, number of private land property (register items), and number of plots. In addition, the land register was a source of information on: The number and place of residence of owners, overall surface area of land, and the number of constituent plots (size of land of out-of-village non-resident owners). The cadastral map was used in specific surveys to prepare a study of non-resident owners in two villages. It was a base map for visualizing the spatial distribution of land in the external plot patchwork. In addition, an inventory of all owners whose land is located outside their place of dwelling (external plot patchwork) was made. To this end, the following information was collected: Dwelling place of the owner, overall surface area of land owned, and number of plots.

Materials and Methods
The collected database of the analyzed villages was stratified using the chequerboard arrays method, identifying the size of plots of land owned by local and out-of-village non-resident owners. Next, a study of non-resident owners was carried out indicating the mutual relations between the surface area and structure of land in terms of possible practical applications of the land exchange process.

Fragmentation of Plots
In order to reflect the actual fragmentation of plots of private land in the study area, they were classified into eight groups according to the surface area. The analysis covered the fragmentation of agricultural real property and plots of private owners only. Surveys were carried out in eight size ranges since the average area of the plot does not reflect the adequate fragmentation in respective villages. The following surface areas were selected for analyses: Plots up to 0.10 ha, plots from 0.11 up to 0.30; 0.31-0.60 ha; 0.61-0.90 ha; 0.91-1.20 ha; 1.21-1.50 ha; 1.51-1.80 ha; and above 1.81 ha. A scrupulous analysis of the index of plots for each village was necessary for surveys presenting the fragmentation of private land. Based on this index, plots with a surface area falling within a respective size range were sought. From the point of view of agricultural production organization, the fragmentation of plots has a negative effect on the resulting income. The amount of income and, at the same time, the profitability of production is determined by the size but also shape and elongation of the plot. Theoretically, the number of plots per farm depends on the surface area of the farm, structure of agricultural land, soil quality classes, and natural terrain conditions. Specific surveys revealed that in the surveyed commune ( Figure 2), the largest number of plots fell within the range of 0.11-0.30 ha, accounting for as much as 34.0% of the number of private plots in the commune. The number of plots falling within this range is the lowest, i.e., accounts for 19.6%, in the villages of Nadrybie Wieś and Nadrybie Ukazowe.
One of the reasons behind the smallest fragmentation is that the consolidation of land in those villages took place before 1982. The highest share of plots in the size range 0.11-0.30 ha was noted in Szpica, where the plots account for 40.0%. This village, apart from having a highly fragmented land, has a very unfavourable arrangement of plots, most of which are excessively elongated, which has a negative effect on the organization of the farm's space and its economic performance. The lowest level is the size range of up to 0.10 ha, comprising 3537 plots, which accounts for 23.0% of their total number. The largest share was noted in the village of Puchaczów, being the seat of the commune, characterized by the dense building development, which results in the presence of multiple small building plots. The lowest share in this size range, i.e., 5.5%, was recorded in the village of Nadrybie Dwór. The next size range being 0.31-0.60 ha included 3080 plots, which accounts for 20.2% of their total surface area. From this range until the range 1.51-1.80, the share of the number of plots is observed to decrease along with the increase in the size range. In the last range, the share of the number of plots increases to 3.3%. The largest number of plots in this range is found in the consolidated village Nadrybie Dwór (59 plots), which accounts for 23.1% of their total number in the village. The fragmentation of plots and the scattering of land is a significant problem that reduces the quality of work and life of people running farms. The studies carried out so far show that the result of excessive fragmentation is a higher cost of commuting to the field and lower income from cultivation. The exchange of land results in more rational land management and thus more effective cultivation. The Common Agricultural Policy (CAP) conducted by the European Union is focused on increasing the efficiency of agricultural production and technical progress, ensuring financial security for farmers, stabilizing the agricultural market and people living in rural areas with an appropriate level of income and living conditions. According to the European Commission, economic disparities between the current Member States, despite strong tendencies towards convergence, still persist. One of the reasons behind the smallest fragmentation is that the consolidation of land in those villages took place before 1982. The highest share of plots in the size range 0.11-0.30 ha was noted in Szpica, where the plots account for 40.0%. This village, apart from having a highly fragmented land, has a very unfavourable arrangement of plots, most of which are excessively elongated, which has a negative effect on the organization of the farm's space and its economic performance. The lowest level is the size range of up to 0.10 ha, comprising 3537 plots, which accounts for 23.0% of their total number. The largest share was noted in the village of Puchaczów, being the seat of the commune, characterized by the dense building development, which results in the presence of multiple small building plots. The lowest share in this size range, i.e., 5.5%, was recorded in the village of Nadrybie Dwór. The next size range being 0.31-0.60 ha included 3080 plots, which accounts for 20.2% of their total surface area. From this range until the range 1.51-1.80, the share of the number of plots is observed to decrease along with the increase in the size range. In the last range, the share of the number of plots increases to 3.3%. The largest number of plots in this range is found in the consolidated village Nadrybie Dwór (59 plots), which accounts for 23.1% of their total number in the village. The fragmentation of plots and the scattering of land is a significant problem that reduces the quality of work and life of people running farms. The studies carried out so far show that the result of excessive fragmentation is a higher cost of commuting to the field and lower income from cultivation. The exchange of land results in more rational land management and thus

Scattering of Private Plots
As the surveys show, in spite of the land consolidation works taking place in the commune of Puchaczów, the external plot patchwork was not eliminated. Detailed analyses showed that in the analyzed commune there are 3055 out-of-village non-resident owners, which accounts for 55.7% of the total number of private owners. In respective villages, the share of land of out-of-village non-resident owners is differentiated. The number of local non-resident owners from the commune of Puchaczów is also significant, as there are 1583 of them, which accounts for 28.9% of the number of private owners in that commune. A village with the largest number of non-resident owners is Wesołówka. Detailed surveys showed that 50.7% of private owners in that village come from other villages of the commune of Puchaczów. At the same time, the village is characterized by a very low share of the number of local non-resident owners (4.5%). In all the villages of the analyzed commune, the share of land of out-of-village non-resident owners from the study area remains at a fixed level. Only Wesołówka, as mentioned before, has a high share of land of out-of-village non-resident owners.
The spatial distribution of land of non-resident owners, using the example of the villages of Brzeziny and Turowola, is illustrated in Figures 3 and 4. The spatial distribution of land of out-of-village non-resident owners indicates that the plots are scattered throughout the territory of the commune. The intensity with which they occur is evidence of a strong presence of owners from the town of Łęczna and the city of Lublin and those living in adjoining villages. At present, the phenomenon referred to as "spilling" of the city, or suburbanization, is more and more common. Surveys carried out in this area showed that most often these are professionally active people who move to the villages, which increases the share of people of productive age in rural areas [35]. The resettlement of city residents in rural areas is both a disadvantage and an advantage. On the one hand, it can be demonstrated that new residents generate income for the commune from local taxes, contribute to the development of enterprise and rural economy or even the cultural development of the residents of villages. On the other hand, such uncontrolled suburbanization causes disturbance to spatial order [36]. The continuous development of suburban zones gives rise to the need of transforming agricultural land into building grounds but the resources of land are limited.    The spatial image of the structure of distribution of plots was developed using GIS tools. A significant phenomenon is the occurrence of land of out-of-village non-resident owners from the town of Łęczna and the city of Lublin, which points to a strong impact of these localities on the villages in the commune of Puchaczów. In the surveyed villages, there are 775 owners from the town of Łęczna and 385 from the city of Lublin. Their highest number is observed in the village of Turowola-owners from Łęczna account for 29.2% (155 people) and in the village of Stara Wieś owners from Lublin have a 12.4% share (18 people). The share of the residents of Łęczna and Lublin in the private land of the commune is due to the fact that these people are employed and live in the city and at the same time own building plots in the rural area or inherited the land from their parents. Recently, Turowola has been a village in which a great number of people decided to build their residential properties. Nowadays, the increase in income and transport mobility of city residents gives them the choice of living either in the city or in the country. A growing number of people make use of building plots situated in the villages in city suburbs. Moreover, building houses in the suburbs make the city less crowded and generate its uncontrolled development [37].
Detailed data concerning the distribution of land of non-resident owners are presented in Table 1. The data show that the number of villages from which non-resident owners living in the county of Łęczna come from is from eight in Nadrybie Wieś to 29 in Wesołówka. Non-resident owners from more than 22 villages of the county have their plots in nine villages from the commune of Puchaczów. The number of non-resident owners who come from outside the study area and from the town of Łęczna and the city of Lublin is also significant. Their share ranges from 37% in Brzeziny to 69.4% in Puchaczów. The surveys regarding the distribution of land of non-resident owners in the study area demonstrate that many people living outside the analyzed county own plots of land in that county. Table 1 does not show end totals, since localities from which non-resident owners come from recur in respective villages. If they were summed up, the result would be incorrect. The external plot patchwork (non-resident owners) in the villages of the analyzed commune, as indicated by the surveys, is a result of the rules of inheritance, dividing large estates into parcels and migration of people from rural areas to urban and industrial centers. The studies concerning the external plot patchwork show that plots of land of out-of-village and local non-resident owners in the villages of the commune of Puchaczów differ in size. Depending on the strength of impact between the villages, a higher or lower number of plots, the owners and area owned by non-resident owners is observed. Previous practice reveals that in a specific village there is no land of non-resident owners from all the surveyed villages. The external plot patchwork is surveyed using the chequerboard array method making it possible to separate the plots of land of local non-resident owners from those of out-of-village non-resident owners [38]. Due to the use of chequerboard arrays in the analysis and evaluation of the plot patchwork a matrix may be created at any level including one village, more than one village, a commune or more than one commune, depending on the level of detail we want to obtain [38]. The deficiency of land from respective villages is marked with an "x". Next, the matrix was ordered so that the biggest share of land of non-resident owners was arranged along the diagonal. Such an ordered matrix makes it possible to determine the relationship between villages and also for the whole analyzed area. Based on previous experience, it should be stated that using the above-described method in the treatment and balancing of the plot patchwork, it can be determined in a simple and clear manner how intense the scattering of private plots is. Patterns of plot patchwork occurring between villages make it possible to develop a plot patchwork elimination programme. Based on detailed analyses a land exchange proposal was prepared.

Possibility of Elimination of External Plot Patchworks
Private land situated out of the dwelling place of its owners constitutes the external plot patchwork. The use of chequerboard arrays in analyzing and evaluating the presence of local and out-of-village non-resident owners provides a possibility of creating a matrix at any level-for a village, commune, county, and voivodeship. The level depends on the range of occurrence of the plot patchwork. The only drawback of this method can be when a matrix is being developed for multiple elements of the spatial structure of land to be analyzed (number of plots, items in the register, occupied surface area, plots of agricultural land, or soil quality classes).
However, the uniformity of matrices facilitates detailed analyses and assessments of such thematically uniform matrices to the extent of the mutual impact of villages and towns/cities covered by the matrix. It makes it possible to determine when the impact of a specific locality on another one is a result of the function it performs in the socioeconomic, cultural, and administrative system of the specific area. Plot patchworks inside the village are analyzed similarly to the external plot patchworks [39]. The external plot patchwork is a complex issue characterized by spatial distribution due to the dwelling places of landowners. The scattering of land in the agricultural space shows some patterns connected to the impact of cultural and religious centers, industrial centers, cities being the seat of counties and voivodeships on rural areas. The further the village is from such centers, the number and surface area of plots of land covered by the external plot patchwork decreases. The occurrence of external plot patchwork is a complex issue due to the fact that the land is either owned by local or out-of-village non-resident owners, which is illustrated in Figure 5. The occurrence of external plot patchwork is not limited by the administrative boundaries of communes. This situation is a result of marriages or migration to urban and industrial centers by people seeking jobs. The survey regarding the occurrence of land of non-resident owners and the review of reference literature shows some patterns in the concentration and location of non-resident owners around administrative and service centers (seat of the commune authorities), religious centers, and adjoining villages. A characteristic feature is adjoining villages with mutual relationships between the surface area of land owned (local and out-of-village non-resident owners). The status of occurrence of plots of land of non-resident owners observed in the study area makes it possible to exchange them, e.g., between these villages. The surface area of land of local and out-ofvillage non-resident owners in the villages of the surveyed commune testifies to the possibility of land exchange. Such an exchange before the consolidation of land makes it possible to eliminate the external plot patchwork. Such an exchange of land, as shown by the The occurrence of external plot patchwork is not limited by the administrative boundaries of communes. This situation is a result of marriages or migration to urban and industrial centers by people seeking jobs. The survey regarding the occurrence of land of non-resident owners and the review of reference literature shows some patterns in the concentration and location of non-resident owners around administrative and service centers (seat of the commune authorities), religious centers, and adjoining villages. A characteristic feature is adjoining villages with mutual relationships between the surface area of land owned (local and out-of-village non-resident owners). The status of occurrence of plots of land of non-resident owners observed in the study area makes it possible to exchange them, e.g., between these villages. The surface area of land of local and out-of-village non-resident owners in the villages of the surveyed commune testifies to the possibility of land exchange. Such an exchange before the consolidation of land makes it possible to eliminate the external plot patchwork. Such an exchange of land, as shown by the surveys, will not only decrease the length of access to plots but at the same time in the consolidation process the households of the owner will increase by the area previously owned outside the boundaries of the village. Figure 6 presents the proposed land exchange algorithm. This simple configuration can be presented as follows: where: A-surface area of private land in the commune; B-surface area of out-of-village non-resident owners living in towns and cities; C-surface area of land of out-of-village non-resident owners living outside the analyzed county; D-surface area of land of out-of-village non-resident owners living in the county; I-surface area of land of local non-resident owners living in the county; Z-surface area of private land after the exchange.
In the case of a lack of land in the village, the land of the State Treasury can be used and exchanged. It is proposed to include the land of non-resident owners not living in the county and living in towns and cities in the consolidation works but on the condition that they are leased to local farmers. In the case of a lack of land in the village, the land of the State Treasury can be used and exchanged. It is proposed to include the land of non-resident owners not living in the county and living in towns and cities in the consolidation works but on the condition that they are leased to local farmers. The operation presented in the algorithm was used for calculating the exchange between out-of-village and local non-resident owners for the area of the county and the commune, which is presented further in the publication.

Results and Discussion
The Use of the Algorithm in the Area of the Commune of Puchaczów As demonstrated by Table 2, changes in the area of respective communes are not The operation presented in the algorithm was used for calculating the exchange between out-of-village and local non-resident owners for the area of the county and the commune, which is presented further in the publication.

Results and Discussion
The Use of the Algorithm in the Area of the Commune of Puchaczów As demonstrated by Table 2, changes in the area of respective communes are not significant. The biggest change as a result of the exchange of land of non-resident owners can be observed in the commune of Puchaczów, i.e., 172.09 ha, which accounts for 1.9% of the area of this commune. In the communes of Łęczna and Milejów, as a result of the required exchange, the change in surface area would be respectively 79.25 and −159.14 ha, which for both communes corresponds to only 1.4% of their total area. The surface area of the commune of Cyców should decrease by 76.62 ha, which accounts for 0.5% of the total surface area of the commune. The smallest changes should take place in the communes of Ludwin −46.73 ha (0.4%) and Spiczyn 31.14 ha (0.4%).  Table 3 presents the applications of the algorithm to land exchange within the commune of Puchaczów. Considering the commune as a whole, both the surface area of private land and the surface area of the whole commune will not change considerably. The area of private land in the commune, after the exchange of land of non-resident owners between respective villages, will increase by 172.09 ha, which for the surface area of private land corresponds to 2.5%, and for the surface area of the commune to 1.9%. However, differences occur in respective villages. The biggest change in the percentage share was recorded in Stara Wieś 2. Due to the exchange, the surface area of the village will increase by 81.74 ha, which corresponds to as much as 61.6% of the overall surface area of this village. In terms of surface area, the biggest change will occur in Wesołówka, where the area of the village will be reduced by 368.20 ha, which accounts for 35.2% of the total surface area of this village. Another village subject to significant changes is Ostrówek the surface area of which after the exchange will be 163.64 ha, which accounts for 27% of its total surface area. Other changes in the surface area decrease to 11.21 ha in Turowola, which accounts for 1.6% of the total surface area of the village. Of course, considering the land owned by, for example, non-resident owners living in cities or outside the county, the changes would be greater, but such non-resident owners cannot be made to exchange their plots. It is proposed that the land owned by them was first leased, especially if this is agricultural land. However, very often non-resident owners living in cities have small building plots inherited from their parents or bought for leisure and building purposes [2,3,5].
In technical and legal terms, the exchange of land is feasible. However, in order to ensure that it can be performed prior to or in the course of consolidation of land, we are required to obtain the consent of non-resident owners to proceed with land exchange. The proposed exchange of land between the owners will bring the land closer to the farmer's place of residence. This will have a significant impact on the decrease in financial outlays for access to the field. The occurrence of external plot patchwork is not limited by the administrative boundaries of communes, which is demonstrated by specific surveys carried out in the commune of Puchaczów, presented in Table 3. This situation is a result of marriages or migration to urban and industrial centers by people seeking jobs. The survey regarding the occurrence of land of non-resident owners and the review of reference literature shows some patterns in the concentration and location of non-resident owners around administrative and service centers (seat of the commune authorities), religious centers, and adjoining villages. A characteristic feature is adjoining villages with mutual relationships between the surface area of land owned (local and out-of-village non-resident owners). These mutual relationships between the surface area of land owned by owners living in respective villages are presented in detail in a matrix including all villages in the analyzed county and in a matrix prepared for the commune of Puchaczów. The matrices constitute a fundamental database allowing the exchange of land between villages. A visual specification of the possibilities of proceeding with the exchange is the graphic illustration of the occurrence of land of local and out-of-village non-resident owners informing on the possibility of proceeding with the exchange between villages in the surveyed commune. On the other hand, the study of out-of-village non-resident owners contains detailed information about the spatial distribution of plots, which is illustrated in Figures 3 and 4. In the previous consolidation works, such a study was prepared for the village being consolidated but land exchange was not carried out. Such a study was only a formal, redundant appendix, since no interest was taken in the land owned by the participants of consolidation if such land was not situated in their dwelling place. Therefore, all the consolidation works in the study area are characterized by a high share of land of outof-village non-resident owners and residents of the consolidated villages still own land in other villages. In connection with this fact, land consolidation should be preceded by land exchange. To this end, the presence of land of non-resident owners must be analyzed using chequerboard arrays which will facilitate preparing the matrices. This will allow us to differentiate between the land of local non-resident owners and that of out-of-village non-resident owners.
The spatial illustration of a plot occurring in both villages, presented in Figure 3 for Turowola and in Figure 4 for Brzeziny, at the same time shows the land of out-of-village non-resident owners included in the legend. The land is simultaneously owned by outof-village non-resident owners in one village and by local non-resident owners in the other village. The status of occurrence of plots of land of non-resident owners observed makes it possible to exchange them, e.g., between these villages. To sum up, the external plot patchwork, as demonstrated by the surveys concerning its spatial distribution, may be eliminated by the exchange, lease, and sale of land. The operation presented in the algorithm was used for calculating the exchange between the out-of-village and local non-resident owners for the area of the county and the commune, which is presented in Tables 2 and 3.

Conclusions
The proposed land exchange algorithm, not only in the process of consolidation works, should be propagated among farmers as it provides a possibility of bringing the land closer to the owner's dwelling and designing larger surface areas of the registered plots. The algorithm was tested in the area of the Puchaczów commune in 15 villages. Detailed studies have shown that both the area of individual lands and the area of the entire commune will not change significantly. The area of individual land in the commune, after the exchange of land between individual villages, will increase by 172.09 ha, which is 2.5% for the area of individual lands and 1.9% for the area of the commune. On the other hand, differentiation occurs in individual villages. To sum up, the external plot patchwork, as demonstrated by the surveys concerning its spatial distribution, may be eliminated by the exchange, lease, and sale of land.
Until now, similar algorithms have not been used for the exchange of land. It is advisable to conduct further research, which will take into account such aspects as soil class, slope, road access, or land value. The designed algorithm can be used in other areas, which was confirmed by the analyses. However, research should be expanded. Surveys can be carried out to see if farmers are interested in the exchange of land. Additionally, it is advisable to check in which areas the land exchange should be carried out in the first place. Due to its complexity, this procedure cannot be performed in the entire area at the same time.