ESTIMATION OF PHOTOVOLTAIC POTENTIAL AT THE URBAN LEVEL FROM 3D CITY MODEL (SOLAR CADASTER): CASE OF CASABLANCA CITY, MOROCCO

Nowadays, the use of solar energy in buildings, especially photovoltaic energy, has undergone a great evolution in the world, thanks to various technological advances and to incentive programs. Related to this topic, the solar cadaster is an important interactive tool to predict the solar potential in an urban environment. The main objective of this research work is to estimate the photovoltaic energy potential of roofs based on aerial photogrammetry and GIS processing. The location chosen for the study is the Maarif district located in the city of Casablanca in order to raise awareness of the public and decision makers to this energy potential through a geoportal that will be developed for this purpose. The tool proposed in this research work makes it possible to evaluate the solar irradiation on a part of the territory of Casablanca with a sufficiently satisfactory precision and reliability, this thanks to the precise reconstruction of the territory in 3D urban model called digital surface model (DSM) at 50 cm resolution by techniques known as photogrammetry which makes it possible to carry out measurements extracted from a stereoscopic pairs, by using the parallax and the correlation between the digital images taken from various points of view. The analysis was used on the basis of specific algorithms and several factors including geographical location, shade, tilt, orientation, roof accessibility and topography which are the main factors influencing the productivity of solar panels.


INTRODUCTION
In Morocco, an emerging country, the share of fossil fuels in the energy mix is significant, estimated at about 70% (Alhamwi et al.,2015). In addition to their harmful role towards the environment, their rapid depletion is irreversible and it is necessary to find alternative solutions to replace them. The use of renewable energies can be a solution to reduce the energy bill while preserving the environment. At the level of an urbanized territory, photovoltaic energy takes a seat of a leadership renewable energies and seems a good idea to produce electricity while thinking of the sustainable development.
In this context, the objective of this project is to present a methodology to evaluate and map the photovoltaic potential in an urban environment through the establishment of a solar cadaster on a part of the territory of the city of Casablanca which is the Maarif district as illustrated in (figure 1).

LITERATURE REVIEW
To implement photovoltaic modules in an urban environment, it is necessary to conduct a study to assess whether the installation is profitable at the chosen site, there are several authors who study the potential of photovoltaic implementation. Each of them uses different methods and criteria. In a research work aimed at studying large-scale urban photovoltaic energy performance (Carneiro et al., 2009) uses a hybrid approach based on raw LiDAR data and digital vector data of roofs extracted from a 3D urban model of the city of Geneva. The objective of that work was the evaluation of solar radiation in urban areas, while this study aims in addition to this quantification to evaluate the electrical energy that can be produced on the roof of each building. According to another study aimed at determining solar radiation and roof surfaces suitable for the installation of photovoltaic modules (Bergamasco and Asinari, 2011) use free data from several sources, the heterogeneity of the acquisition of these data is a factor affecting their degree of certainty, unlike our case where the data are homogeneous with a relatively satisfactory degree of certainty. On the other hand (Nguyen et al, 2012) presents a methodology based on LiDAR data to model an urban environment in 3D to make an automatic analysis of solar PV deployment at a regional scale. The study focused in particular on the accurate modelling of the urban area following a segmentation of LiDAR data, however the quantification of the solar potential did not make use of a multicriteria and GIS analysis taking into account the factors influencing its productivity. Based on LiDAR data to model an urban environment (Ávila et al., 2016), use a GIS model combined with a multicriteria analysis to assess the urban photovoltaic potential, this also allowed to identify the optimal sites for the installation of photovoltaic modules. In another study whose objective is to identify the surfaces of building roofs useful for the installation of solar panels (Lópeza et al., 2016) use a processing methodology based on photogrammetry techniques combined with thermo-graphic information for the 3d modelling of the site, this will allow an automatic classification of the surfaces according to their energy productivity which is derived from their geometric characteristics (orientation, inclination and surface).

STUDY AREA AND DATA SOURCE
On the Moroccan territory, the city of Casablanca occupies an area equal to 786 km² with a population density amounting to 4275 inhabitants/km². It is located on the Atlantic coast in the northwest of the kingdom, between 33°49 and 33°64 N and between 7°45W and 7°75W and about 80 km south of Rabat, the administrative capital of Morocco. Administratively, it is composed of sixteen districts, one of which is the district of Maarif, the subject of this study. It occupies an area of 12.4 km2 and according to the 2014 census, the number of inhabitants is about 170,689.
Regarding climatic data, Casablanca has a Mediterranean climate with a strong oceanic tendency. The annual cumulative rainfall amounts to 426 mm and the average annual temperature is 18.88 °C. During the year, the city is lit 9 to 10 hours a day in summer and 5 to 6 hours a day in winter.
Considering its economic situation, the city has a multiple typology of buildings. For example, residential buildings such as houses, commercial buildings such as shopping malls, hypermarkets and stores, sports buildings and other types. Due to its industrial and commercial development, Casablanca is considered to be the most polluted city in Morocco (Inchaouh and Tahiri, 2017), given the significant number of environmental problems it suffers from such as the problem of greenhouse gases caused mainly by the transport and industry sector and the problem of overexploitation of natural resources, the use of renewable energies can be an excellent recourse to remedy these problems.
Concerning the data used for this study, they come from the Urban Agency of Casablanca, these data come from a photogrammetric restitution in the form of files containing points of elevation of the ground, the contours of the roofs of buildings, the hydrography and aerial images. Sun position data is downloaded directly from www.sunearthtools.com as Excel tables. It should be noted that an important part of the data is the result of GIS processing.

METHODOLOGY AND ANALYSIS
The methodology is based on a model that identifies the optimal location for the installation of photovoltaic modules and estimates the electrical energy production in an urban area. Although photovoltaic panels can be placed on roofs and facades of buildings, this study will only analyze the possibility of rooftop installations. The procedure will be based on a three-dimensional model of the study area generated from aerial photogrammetry techniques from stereoscopic pairs (Poli and Caravaggi, 2012). Once the acquisition data is processed by specific algorithms, a numerical model of the surface of the agglomeration will be created as well as the restitution of the roofs. This type of data has been the basis of various previous works as it allows the use of both the topography of the terrain and the geometric shapes of the building structures. With this model, we later determine the surface of the roofs, estimate the solar radiation and consequently the installed power and energy produced.
For the calculation of the available surface of roofs where to place the photovoltaic modules, it is necessary to establish the criteria that determine the appropriate locations. Some studies do not take into account the morphology of the roofs and consider it horizontal regardless of its shape, but if we want to obtain more precise results, we have to take into account criteria such as the slope and the orientation without excluding the shadows effects (Le Genusa et al., 2011). After defining the selection criteria, the determination of the surface of the roofs will be done using a Boolean multicriteria analysis with the characteristics that all the sites must satisfy.
Regarding the estimation of solar radiation, it is possible to use existing online climate databases such as SunEarthTools which is The International Archives of the Photogrammetry, Remote Sensing and Spatial Information Sciences, Volume XLVI-4/W3-2021 Joint International Conference Geospatial Asia-Europe 2021 and GeoAdvances 2021, 5-6 October 2021, online dedicated to solar energy consumers and designers. However, the objective of this study is to map this quantity using algorithms integrated into ArcGIS software that have proven effective in similar studies using the DSM as input data. The last calculations made are the installed photovoltaic potential and the determination of the electrical energy produced annually. The simulation of productivity takes into account the different types of photovoltaic modules that exist on the market, depending on the model chosen, the results will be different because the efficiency is not the same for all.
Finally, all the results obtained for the buildings in the area are integrated into a geospatial database including the surface of the roof, its useful surface for the installation of photovoltaic modules, the installed power and the energy that can be produced, the whole of this data combined with other information will constitute a solar cadaster.

Figure 2.
Descriptive flowchart of operations for establishing a solar cadaster.

The 3D urban model
To evaluate the photovoltaic potential at the urban agglomeration scale, a 3D urban model is very useful (Carneiro et al, 2009). The selection of suitable roofs for the installation of photovoltaic panels requires a representation of the geometry of buildings and any other topographic objects in the study area. This type of analysis has increased the demand for more detailed urban models and the acquisition of data from high resolution remote sensing technologies, such as airborne LiDAR (Xu Z, 2012) or Aerial Photogrammetric techniques (Poli and Caravaggi, 2012) or both combined.
In our case we will use a 3D modelling (DSM) at 50 cm resolution based on the photogrammetric techniques using appropriate algorithms in order to generate the data essential to our study area. The method of producing the DSM is based on an automatic correlation procedure on the digital pixel counts of several stereo images. This technique makes it possible to find homologous points between the different images and thus to calculate, for each pixel using the parallax, the altitude at this point. This method requires two or more overlapping stereoscopic images over the study area, as well as a number of well distributed calibration points known in coordinates(X,Y,Z).
The photogrammetric mapping will allow the subsequent generation of the elements composing the soil and the above ground element with an appropriate classification (outline of building, tree, road, etc).

Multicriteria analysis
To calculate the useful roof area for the installation of photovoltaic modules, a multicriteria Boolean analysis is essential to determine the optimal locations and eliminate unsuitable areas.
The analysis takes into consideration the factors influencing the productivity of photovoltaic modules which are: -The loss of energy caused by the inclination and orientation of the roofs.
-The surface of the roofs affected by the shadows generated by any surrounding element.
-The roof area allowing access to the photovoltaic modules.
-The extraction of inappropriate buildings.
These criteria will be determined in the form of raster maps from the DSM calculated previously and the photogrammetric restitution. In the analysis, it is necessary to determine the conditions that must satisfy each of the factors (restrictions). In this method, a value of 1 is automatically assigned when the factors meet the established conditions and a value of 0 when they do not. The processing is performed using ArcGIS software.

Losses energy caused by inclination and orientation
Depending on their position, the productivity of solar photovoltaic modules varies considerably. As a result, the modules are installed on horizontal roofs with a certain inclination and orientation to maximize their efficiency (Ávila et al, 2016). For sloped roofs, the panels should be located in areas where energy losses from the system are as low as possible.
The position of photovoltaic modules is defined by two angles that will influence the amount of solar radiation that will receive the installed system: • Inclination: Angle formed by the plane of the module and the horizontal plane. The angle of inclination to optimize annual energy production is generally a few degrees lower than the local latitude (about 33°57').
• Orientation: An angle formed by the horizontal projection of the normal to the plane of the module and the optimal direction (southern direction).
However, the limits on inclination can be calculated according to the minimum efficiency allowed for the orientation of the surface using the method explained by the Institute for Diversification and Saving of Energy (IDAE, 2015) according to the following equation.
These limits make it possible to assess the adequacy of the studied surface for the installation of the PV modules and to determine the ideal geometry of the support platforms, the productivity losses should not exceed 20% if the solar panels are installed directly on the roofs.
To calculate the slope and orientation of the roofs of the buildings, a mask representing the contours of the roofs resulting from the restitution will be applied on the DSM layer. The tilt of The International Archives of the Photogrammetry, Remote Sensing and Spatial Information Sciences, Volume XLVI-4/W3-2021 Joint International Conference Geospatial Asia-Europe 2021 and GeoAdvances 2021, 5-6 October 2021, online the roofs is calculated with the DSM of buildings applying the ArcGIS tool to generate slopes. The units of measurement used in the calculation will be the degrees and the range of values of the resulting slopes will be between 0 and 90°.
Finally, the resulting raster layer (The inclination and orientation losses index) is obtained by reclassifying the losses of tilt and orientation, a value of 1 will be automatically assigned to cells corresponding to losses less than or equal to 20% (Basic document HE,2009).

Losses energy caused by shadows
Shadows play an important role in the design of photovoltaic installations. Although solar panels can operate with diffuse radiation, shading should be avoided, especially during peak hours to maximize energy production (Echlouchi et al., 2017).
To calculate shadows, the ArcGIS "Hillshade" tool is used to determine the illumination area from the DSM taking into account the position of the Sun and the topography of the site (La Genusa et al., 2011). It allows estimating whether an area is shaded or not in a given time. To facilitate the calculation, we will be limited to the days of the equinox and solstice.
To calculate the shading, we will need data relating to the position of the Sun which in this tool are defined by the angles of azimuth and elevation. These values are obtained from the solar position data table provided by the site 'www.sunearthtools.com' with an interval of 1 hour corresponding to the year 2020.
The processing generates raster layers in grayscale, the resulting shadow and lighting values range from 0 to 255 where the shadow areas correspond to the value 0. Since we are only interested in the shaded areas and to facilitate the calculation operations, the values of each map will be classified into two classes using the raster calculator of the ArcGIS software, so the value 1 is assigned to pixels ranging from 1 to 255 (areas without shading) while that the value 0 represents the areas affected by shadows. Once the individual shading maps are generated, they will be combined to give the shading map throughout the year. Finally, the area of shadows that affect only the buildings is delimited with the building polygon mask.

Roofs accessibility area
To facilitate the maintenance of photovoltaic installations and the accesses for extinguishing fires, the access areas are important and must be preserved. These zones set requirements which essentially amount to two access routes one meter wide on sloping roofs and a perimeter strip of at least one meter on flat roofs. The accesses being zones to be removed from the total surface of the roof, the application of the buffer tool on the vector layer representing the buildings will allow us to generate them, these zones will be converted into a raster layer where the value 1 is assigned to cells outside these areas and 0 inside these areas.

Elimination of inappropriate buildings
Inappropriate buildings in the densely populated urban residential area consisting mainly of decrepit housing units and deteriorated or incomplete infrastructure situations will be ignored as part of this study as well as those with a particular character preserved.

Useful surface of roofs
Using the ArcGIS software raster calculator tool, the spatial combination of the different raster layers related to the predefined criteria will allow us to determine the useful area for the installation of photovoltaic modules at the level of each roof using the following formula (Ávila et al., 2016). Where: LIO = layer representing the loss of energy by inclination and orientation. SL = layer representing the areas affected by the shadow. RA = layer representing the accessibility of the roof. IB = layer representing inappropriate buildings.

Assessment of the solar radiation
Solar radiation received at roof level is an important factor in the productivity of solar panels. The global solar radiation calculated for each roof is equal to the sum of the direct and diffuse solar radiation received according to the algorithm integrated in the ArGIS software and using the DSM as input value (Fu and Rich, 2002).
β :The transmissivity of the atmosphere (averaged over all wavelengths) for the shortest path (in the direction of the zenith).
-m(θ) :The relative optical path length, measured as a proportion relative to the zenith path length.
-SunDurθ,α : The time duration represented by the sky sector. For most sectors, it is equal to the day interval (for example, a month) multiplied by the hour interval (for example, a half hour). For partial sectors (near the horizon), the duration is calculated using spherical geometry.
-SunGapθ,α : The gap fraction for the Sun map sector.
-AngInθ,α : The angle of incidence between the centroid of the sky sector and the axis normal to the surface. -Weightθ,α :The proportion of diffuse radiation originating in a given sky sector relative to all sectors.
-AngInθ,α : The angle of incidence between the centroid of the sky sector and the intercepting surface. When generating the solar radiation map, ArcGIS's "Solar Radiation Zone" tool will be used to determine the amount of solar radiation reaching a surface in a specific period of time (T. Santos, 2014). The radiation calculated for a given zone is given in global irradiation (direct + diffuse) in units of Wh / m2 and is determined according to the DSM. Solar analysis takes into account changes in the position of the Sun and the effect of buildings or any other topographic element. The following parameters are defined: • The latitude is used in the calculation of the declination and the solar position its value is calculated automatically (33 ° 57 ').
• The solar radiation determination period may vary from one to several days or a full year.
• Topographic parameters such as slope and orientation according to the DSM of the area. • The diffuse proportion of radiation depends on atmospheric conditions. Its value varies from 0 to 1, but generally for a clear sky, an appropriate value is usually 0.3. • Transmittance refers to the relationship between the amount of energy received in the atmosphere and that ultimately reaching the surface of the earth. By default, for clear skies, its value is 0.5 although the values go from 0 to 1 (without transmission and complete transmission respectively).  The results show that the development of the solar renewable energy sector in the city of Casablanca is very favorable thanks to a solar potential that can be deduced from the statistics carried out, thus the city is endowed with 4326 hours of sunshine per year and of 3 KWh / m 2 / day of irradiation on average.

Power installed
There are currently three main types of photovoltaic panels on the market, which are differentiated by the type of cells they contain. All the cells are produced on the basis of silicon, but the different technologies used give them very different characteristics, especially in terms of productivity. Each model has its own efficiency values as illustrated in (Table 1). These technologies share the world market with varying proportions as follows: • Polycrystalline represents 45% of the world market.
• Monocrystalline represents 40% of the world market.
In estimating the installed power, the type of photovoltaic module for which the calculation is to be carried out must be taken into account. Depending on the type of module, the algorithm will determine the installed power by applying the corresponding efficiency value in each case. In a grid-connected PV system, the installed capacity (in kWp) for each PV module technology on a given area is calculated using the formula (9) below (Wiginton et al., 2010): P=Ig * e * RA (9) Where: • P = Installed power. An example of the results of the installed power at the roof level of each building according to the type of photovoltaic module used, is presented in (Figure 6).

Energy produced
The energy produced is calculated in the same way as the installed power, which will allow us to simulate the energy productivity according to the different types of photovoltaic modules available on the market and their efficiency value.
The input data required for this calculation are the annual average global irradiation of each roof and its useful surface for photovoltaic energy production. For a grid-connected photovoltaic system, the energy that will be produced by the installed modules can be deduced according to the formula (10) (Wiginton et al., 2010): Where: Likewise, an example of the results of the annual photovoltaic energy productivity at the roof level of each building depending on the type of photovoltaic module used is illustrated in ( Figure  6).

Assign results to building
The last phase of the study consists of attributing to the polygons representing buildings in the area the compilation of the results obtained corresponding to each of them and which are mainly: • The surface of the roofs.

•
Useful roof area available for installation of photovoltaic modules.

•
Installed power according to each type of modules.

•
Energy produced according to each type of modules.
To associate the values to the buildings, the results of each raster obtained are extracted and associated according to the zonal statistical tool of ArcGIS software.
The results obtained can be made public through a geoportal which will be developed using web mapping technology for this purpose, in the form of interactive maps giving precise information on all the city's rooftops.

RESULTS AND DISCUSSIONS
In this study, the emphasis was on the precise evaluation of the photovoltaic energy potential using GIS treatments coupled with photogrammetric techniques. The analysis makes it possible to map this potential at the level of the study area. The last phase of the study is to attribute the compilation of the results obtained for each building in the form of a geospatial database.
By comparing the results obtained in this study with another that we carried out in the city of Nador using LiDAR (Lambarki et al., 2020), we found that the results obtained from aerial photogrammetry techniques are satisfactory for the objectives set, which is consistent with the study conducted by (Moreira et al., 2013) aiming to compare the precision of the different building modelling methods according to the different acquisition modes. This has the consequence of solving the problem of data availability on the one hand and reducing the cost of the study on the other hand.
The results show that the city of Casablanca in general and the Maarif district in particular benefit from a great solar potential with 4326 hours of sunshine per year, an average annual irradiation of 1470KWh / m 2 / year and a useful roof surface for future photovoltaic modules of around ~ 225 Ha which constitutes a deposit which can produce an energy of the order of ~ 295 GWatt/year inexhaustible. Figure 6. Example of results obtained relating to the installed power and annual energy produced by roofs using different types of photovoltaic modules.

CONCLUSION AND FUTURE WORKS
In this study, it was found that the establishment of a solar cadaster in an urban area requires a detailed analysis of a large number of variables associated with spatial entities in order to predict the photovoltaic energy potential. In this preliminary phase, the analysis of the energy balance of the roofs of buildings was carried out using a practical model. To justify its validation and precision, field experimentation is essential, which will be the subject of a future in-depth study.
The applications of solar cadaster results are important in regional energy planning by redefining the value of buildings relative to their solar potential on rooftops. Indeed, urban design in terms of orientation and shape of buildings can significantly increase energy efficiency. This will undoubtedly encourage local communities to renew practices favorable to the development of local energies and adapted to energy and climate vulnerabilities.
These results will undoubtedly raise the public's awareness of such an energy potential and encourage those responsible to invest in this type of promising energy technology, which will continue to be developed for better performance and better prices.