René Sandretto

Mustapha Sadni

THE FREE TRADE AGREEMENT BETWEEN THE UNITED STATES AND MOROCCO THE IMPORTANCE OF A GRADUAL AND ASSYMETRIC AGREEMENT 1 Lahsen Abdelmalki (*)

Keywords: F13 -Commercial Policy, Protection, Promotion, Trade Negotiations F17 -Trade Forecasting and Simulation C68 -Computable Politique commerciale, libéralisation, accords de libre-échange, simulation, modèle d'équilibre général calculable, Maroc, Etats-Unis Policy, Liberalization, Free trade Agreement, Simulation, CGE Model, Morocco, United-States

The agreement recently signed between Morocco and the United States foresees several modalities in dismantling tariffs. Our simulations show that the various modalities of trade liberalization may have different impacts on the welfare, the rate of growth and the sectoral trade balance of these two countries. More precisely, our findings justify the interest of a gradual and asymmetrical agreement. In addition, the FTA between the US and Morocco will have a significant impact not only on trade between the two countries, but also on their trading relationships with other countries. The most important trade diversion will affect the EU and particularly France, which is Morocco's largest trading partner. It will also adversely affect the other North African countries. The FTA will thus offer the opportunity to Morocco to diversify its markets and its capabilities, which are currently focused on the EU, particularly on France and Spain.

Introduction

Free trade agreements (FTA) between Morocco and the US will expose the Moroccan economy to increased competition on both price and quality in a range of products. This competitive pressure should provoke an increase in productivity on the part of Moroccan firms. Under such circumstances, it is quite possible that allowing US exports tariff-free access to the Moroccan market could result in substantial trade diversion. Although Moroccan consumers could enjoy lower prices, these gains could be more than offset for the economy as a whole because of the loss in tariff revenue and the purchase of goods from the United States rather than more efficient sources. In addition, there is the possibility that Morocco could experience declines in its terms of trade since its tariff reductions would be much larger than those of the United States.

The focus of the empirical analysis will be on the trade liberalization component of the FTA. The following are the specific questions to be addressed: Consequently, this study will also try to quantify the impact of the FTA on direct revenue. The quantification of the trade expansion will provide a basis for estimating the resulting revenue effects due to trade diversion from non-US to US producers and suppliers.

• First,
The agreement recently signed between Morocco and the United States foresees several modalities in dismantling tariffs. The problems with dismantling tariffs will be examined in the essential cereals, red meats and vegetables sectors where a period of transition is necessary for their survival. Indeed, the American agricultural sector is the most efficient in the world, especially for cereals. This sector was the main obstacle in the finalization of the FTA. Indeed, the Moroccan economy is largely based on the agriculture. Fifty percent of the working population are employed in the primary sector, while 70 % of farmers cultivate cereal. American products would bean extremely serious threat to Moroccan agriculture, as the US products are of very good quality and are produced at cheaper cost in part due to domestic subsidies. During the negotiations, the Moroccan party had recommended reserving cereals as a special case before total liberalization. However, the position of the US delegation was that an FTA needed to include agricultural products.

The benefit of the FTA lies in the structural changes the Moroccan agriculture would undergo to make it more competitive and to better exploit the comparative advantages of the country. The questions and the answers which are arising from this converge on the same conclusion, as we shall demonstrate namely the interest for both partners of an asymmetric agreement and a progressive dismantling, especially for Morocco The article is structured as follows: Following the Introduction, Section 2 highlights Morocco's trade relations with US compared to that with European Union (EU). Section 3 presents the methodology used to assess the necessity of an asymmetric FTA, while Section 4 describes the models used in the analysis. A description of the Global Trade Analysis Project (GTAP) 6 and World Integrated Trade Solution (WITS) models is made in this section. Section 5 presents the main results obtained from the simulations. Lastly, section 6 concludes the paper.

Trade performance of Morocco's economy

Morocco's major imports and exports are in manufacturing (around 62 % of imports and 65 %of exports in value terms in 2001). Machinery and transport equipment, textiles and chemicals are the main imports. Imports of textiles are mainly in connection with sub-contracting, particularly with partners in the EU. The rapid increase in their share of total imports of goods was mainly due to a change in the way they are entered in the accounts (how they are reflected in trade statistics). Agricultural foodstuffs and products from the mining and quarrying industries form the primary imported goods. Variations in imports of fuel primarily reflect the fluctuations in their global price.

The EU is Morocco's principal trading partner, both for imports and exports (see figures 1 and 2).

France alone provides over 20 % (24 % in 2000 and 22.5 % in 2001) of total imports.; Other major importers to Moroccan include Spain, the United Kingdom, Italy and Germany. Outside the EU, Morocco also imports goods from the United States and Saudi Arabia, while the volume of imports from other regions is negligible. France receives over one quarter of Morocco's exported goods, followed by Spain, the United Kingdom, Italy, and Germany. In terms of share of trade, the order of importance of the leading partners is the same, both for imports and exports. The high concentration of exports to the EU is mainly due to the change in the method of reflecting sub-contracting operations in the accounts. 1990 1991 1992 1993 1994 1995 1996 1997 1998 1999 2000 2001 2002 2003

US Millions $

EU 25 United States and Canada 1990 1991 1992 1993 1994 1995 1996 1997 1998 1999 2000 2001 2002 2003

US millions $

EU 25 United States and Canada

The Free trade Agreement between Morocco and the US: General Equilibrium Analytical Methodology

This section discusses in detail the methodology applied for the empirical analysis. The discussion starts by outlining the GTAP modelling and data framework. The GTAP model analysis is complemented in the study with a partial equilibrium analysis model, or SMART model, developed jointly by the World Bank and UNCTAD. The SMART methodology is therefore also described in this section. The partial equilibrium model is aimed to provide some results at the tariff lines level (6-digit level).

Rationale for a General Equilibrium Methodology

Trade policy analysis involves examining implications of trade policy instruments on the production structure in economies at the national and global level. Trade policy instruments, such as tariffs and quotas, have direct and indirect effects on the relative prices of commodities produced in a given country. As the mix of goods and services produced changes, the demand for factors of production also changes. Consequently, it is difficult to conceive a situation in any economy where the change in trade policy affects only one sector. Due to the forward and backward linkages and their related strengths existing in a particular economy, the result is always one in which the relative mix of sectoral outputs change. This, by extension, affects the relative mix of the different factors of production in the different sectors.

The country-level effects on output mix and demands for factors of production can in the context of international trade be extended to the global economy. Changes in relative prices of outputs and inputs resulting in a given country's change in trade policy are transmitted to the industries and input markets of other economies that the country trades with. Therefore, for trade policy analysis to be meaningful and for robust results to be produced, the interactions that prevail among different sectors as a result of a change in a given group of countries trade policy instruments must be taken into account. The general equilibrium methodology provides an analytical framework that allows for inter-and intra-sectoral changes in output mix, and by extension the demand for different factors of production to be captured. [START_REF] Kehoe | A Primer on Static Applied General Equilibrium Models[END_REF] succinctly captured the essence of general equilibrium models. General equilibrium models are an abstraction that is complex enough to capture the essential features of the economy, yet simple enough to be tractable. These models are popular over their partial equilibrium counterparts because they stress the interactions among different sectors. However, they are not perfect, especially the static ones, since they fail to take into account the dynamic effects that accompany changes taking place in a given economy as a result of policy change. The GTAP model falls in this class of general equilibrium models. GTAP is a multiregion computable general equilibrium (CGE) model designed for comparative-static analysis of trade policy issues [START_REF] Adams | Long-run Effects on China of APEC Trade Liberalization[END_REF]. It can be used to capture effects on output mix, factor usage, trade effects and resultant welfare distribution between countries as a result of changing trade policies at the country, bilateral, regional and multilateral levels. Since the GTAP model puts emphasis on resource reallocation across economic sectors, it is a good instrument for identifying the winning and losing countries and sectors under policy changes involving the trade aspects of FTAs.

The GTAP Database and the Study Aggregation

Data description

The GTAP model is used together with the GTAP database which, like the model, captures individual and composites of countries. In this exposition, Version 6 of the database is used. The base year for this version is 2001 and recognizes 87 regions as well as 57 sectors and 5 factors of production. Thus, for each individual or composite region, there are 57 sectors whose data is captured in the overall GTAP database. As previously indicated, not all countries are individually captured in GTAP. However, each economy is indirectly included in the database as part of a given composite region or as part of the rest of the world. Thus, global macroeconomic consistency holds. For the purpose of our study, Morocco and the US are presented separately.

Sectoral and geographical aggregations

For the present study, 87 regions have been aggregated into 5 subregions, and 57 sectors have been identified. A complete description of the sectoral and geographical aggregation is posted in Annex 1.

Scenarios tested in the CGE modelling

In order to assess the overall effect of the FTA on the Moroccan economy, we test three scenarios:

• Scenario 1: Strongly asymmetrical liberalization. All tariffs and quotas are removed by the US on imports from Morocco (duty free, quota free entrance for Moroccan exports), while Morocco reduces its tariffs on imports from the US by 10% (which roughly corresponds to a one-year liberalization impact for Morocco in the actual agreement); • Scenario 2: Intermediate asymmetrical liberalization. All tariffs are removed by the US on imports from Morocco, while Morocco reduces tariffs on imports from the US by 50%; and • Scenario 3: Full reciprocity, full liberalization. All bilateral tariffs are removed between Morocco and the US. All ad valorem tariffs, which appear in Figure 1, are reduced to zero.

These 3 scenarios are compatible with the main objectives of the Doha agenda related to market access and the reductions of all forms of export subsidies and trade-distorting domestic support.

None of the three scenarios correspond to the actual agreement, although they give some indication of the relative importance of having an asymmetric agreement. Indeed, the U.S.-Morocco FTA eliminates tariffs on 95% of bilateral trade in consumer and industrial products (including textiles) with all remaining tariffs to be eliminated within 9 years. Particular treatment is reserved for agricultural products. Some important Moroccan exports, such as clementines, tomatoes and olives, will be allowed to enter the US duty-free market on the first day of implementation. Morocco will in turn provide immediate duty-free access to American products such as pistachios, pecans, nuts, almonds, processed poultry product (with some restriction), pizza cheese and other foodstuff. For all other agricultural products, tariffs will be phased out in 5 to 15 years.

The agreement includes broad commitments in some key services, namely banking and insurance (with a 4-year protection period), distribution, express delivery, engineering, audiovisual and telecommunications.

An important characteristic of the agreement is that it includes asymmetrical commitments to Morocco's advantage, as suggested by Scenarios 1 and 2. This asymmetry is justified by the difference in the level of development of the trading partners and by the difference in the average level of the tariff schedules of the 2 countries, which amounts to more than 20% for Morocco against 4% for the US (Figure 3). Obviously, with such a difference in the tariff schedules, the gain for Morocco would be far less important than that for the US in a full liberalization scenario.

Of course, the complexity of the actual US-Morocco agreement cannot be captured by a simple scenario formula. However, inasmuch as the real agreement is a (complex) combination of these scenarios, we can expect to draw some interesting conclusions by comparing the scenarios.

The Free trade Agreement between Morocco and the US: The Partial Equilibrium Modelling Framework -the WITS/SMART Model

Rationale for a Partial Equilibrium Model

It was argued that trade policy analysis is more robust when undertaken within a general equilibrium modelling framework. This can be seen as the best option as general equilibrium models not only measure the first-round effects of simulated change, but also the second-round effects which include inter-industry effects and macroeconomic adjustments. However, as was indicated in the discussions on the GTAP modelling and database frameworks, GTAP does not provide any information at the tariff lines levels. This data could give us important information concerning the economic impact of the FTA between Morocco and the US. This section therefore describes the partial equilibrium modelling methodology that was used in the study to complement the GTAP results. The main distinction that should be noted at the outset is that as a partial equilibrium model, the inter-sectoral implications (second-round effects) of trade policy change are not taken into account as is the case in the general equilibrium model. Similarly, the inter-regional implications, such as within a regional economic communities (REC) setting, are also ignored in a partial equilibrium framework. The only point of convergence between the partial and general equilibrium models is that it is still possible within a partial equilibrium model to analyze the trade policy effects on trade creation and diversion, welfare and tariff revenues while holding everything else constant. [START_REF] Milner | Some Simple Analytics of the Trade and Welfare Effects of Economic Partnership Agreements: The Case of the EU-EAC[END_REF] provide a simple analytical framework explaining the theory behind partial equilibrium modelling and note that to adequately capture the interactions between sectors and elasticities of substitution between factors, and to simulate dynamic effects in their EPA study between the EU and the East African Community, a general equilibrium model would be desirable. However, partial equilibrium models would work as an alternative due to scarcity of individual and regional CGE models for developing countries. [START_REF] Milner | Some Simple Analytics of the Trade and Welfare Effects of Economic Partnership Agreements: The Case of the EU-EAC[END_REF] also observed that the database for general equilibrium models lacks the details on commodities needed to take into account specific sensitive and special products that are of interest to both the Sub-Saharan African countries and the EU. A partial equilibrium framework is in a better position, in spite of its shortcomings, to allow for the utilization of the now widely available trade data at the appropriate level of detail that would allow for the principle of special and differential treatment to be captured in the simulation analysis. It however remains true that although partial equilibrium models have drawbacks, as a modelling approach they have the advantage of working at very fine levels of detail such as the tariff line level.

The WITS/SMART Model

For the purposes of this study, it is proposed that the WITS/SMART model will be the applied partial equilibrium framework. WITS brings together various databases ranging from bilateral trade, commodity trade flows and various levels and types of protection. WITS also integrates analytical tools that support simulation analysis. The SMART simulation model is one of the analytical tools in WITS used for simulation purposes. SMART contains in-built analytical modules that support trade policy analysis, covering the effects of multilateral tariff cuts, preferential trade liberalization and ad hoc tariff changes. The underlying theory behind this analytical tool is the standard partial equilibrium framework that considers dynamic effects to be constant. Like any partial equilibrium model, these strong assumptions only allow trade policy analysis to be undertaken one country at a time. In spite of this weakness, WITS/SMART can help estimate trade creation, diversion, welfare and revenue effects.

Trade creation

The underlying theory is summarised below for the estimation of the trade flows and revenue effects. The exposition of the WITS/SMART theory is summarised from Laird and Yeats (1986). Trade creation captures the trade expanding aspects of liberalisation that leads to the displacement of inefficient producers in a given preferential trading area (a free trade area for instance). It is assumed that there is full transmission of price changes when tariff or non-tariff distortions (ad valorem equivalents) are reduced or eliminated. Laird and Yeats (1986) derive clearly the equation that can be used to estimate the trade creation effects. The derivation begins with the following basic trade model composed of simplified import demand and export supply functions and an equilibrating identity:

A simplified import demand function for country j from country k of commodity i:

) , , (

ik ij j ijk P P Y f M = (1)
The export supply function of commodity i of country k can be simplified as:

) ( ikj ijk P f X = (2)
The equilibrium in the trade between the two countries is the standard partial equilibrium equation:

ikj ijk X M = (3)
In a free trade environment, the domestic price 2 of commodity i in country j from country k would change with the change in an ad valorem tariff as follows: ) 1 (

ijk ikj ijk t P P + = (4)
To derive the trade creation formula, following Laird and Yeats (1986), the price equation ( 4) is totally differentiated to get:

ikj ijk ijk ikj ijk dP t dt P dP ) 1 ( + + =
(5) Equations ( 4) and ( 5) are then substituted into the elasticity of import demand equation 3 to get: 2 The transport and insurance costs are not reflected in the equation explicitly. 3) the trade creation effect is equivalent to exporting country k's growth of exports of commodity i to country j:

⎟ ⎟ ⎠ ⎞ ⎜ ⎜ ⎝ ⎛ + + = ikj ijk ijk ijk m i ijk ijk P dP t dt M dM ) 1 ( η (6)
)) / 1 )( 1 (( e i m i ijk ijk m i ijk ijk t dt M TC γ η η - + = (7)
If , then equation ( 7) can be simplified as follows:

∞ → e i γ ) 1 ( ) 1 ( ) 1 ( 0 0 1 ijk ijk ijk ijk m i ijk t t t M TC + + - + = η (8)
where TC ijk is the sum of trade created in millions of dollars over i commodities affected by tariff change and is the elasticity of import demand for commodity i in the importing country from the relevant trading partner. M m i η ijk is the current level of import demand of the given commodity i. and represent tariff rates for commodity i at the initial and end periods respectively. Trade creation then depends on the current level of imports, the import demand elasticity and the relative tariff change.

0 ijk t 1 ijk t

Trade diversion

Trade diversion as opposed to trade creation can expand or contract trade globally. Trade diversion is the phenomenon that occurs in a free trade area for example whereby efficient producers from outside the free trade area are displaced by less efficient producers in the preferential area. Consider an EPA between ECOWAS and EU for instance. Trade diversion would result if as a result of the establishment of the EPA more efficient suppliers from the rest of the world (ROW) into ECOWAS are displaced by inefficient producers from the EU. Assuming that such an EPA is formed which leads to reduction of tariffs facing the EU without any changes in the tariffs facing the ROW exporters; the theory underlying the measurement of trade diversion in SMART is also explained in Laird and Yeats (1986). To see the derivation clearly, first the expression for elasticity of substitution is given. The elasticity of substitution can be expressed as the percentage change in relative shares of imports from two different sources due to a one per cent change in the relative prices of the same product from these two sources:

( )( ) ijK ijk ijK ijk k K ijK ijk K ijK k ijk M P P P P M M M M / / / / / / ∆ ⎟ ⎠ ⎞ ⎜ ⎝ ⎛ ⎟ ⎠ ⎞ ⎜ ⎝ ⎛ ∆ = ∑ ∑ ∑ ∑ σ (9)
where k denotes imports from EU and K denotes imports from the rest of the World. Equation ( 9) can be expanded, and through substitutions and rearrangements be used to obtain the expression for trade diversion, which is expressed as: 10) can be simplified to the case of an EPA. The relative price movement terms in the equation as noted in Laird and Yeats (1986) capture the movement due to changes in tariffs or the ad valorem incidence of non-tariff distortions for the EU and the ROW. Therefore, the trade diverted to the EU in the EPA, can be captured by reducing equation ( 10) above as follows:

∑ ∑ ∑ ∑ ∑ ∑ ∆ + + ∆ = K M k ijK ijk ijK ijk ijk ijK k ijk M k K ijK ijk ijK ijk
EPA TD M EU EU EU ROW EU M EU EU ROW EU EPA t t M M M t t M M TD σ σ ⎟ ⎟ ⎠ ⎞ ⎜ ⎜ ⎝ ⎛ - + + + + ⎟ ⎟ ⎠ ⎞ ⎜ ⎜ ⎝ ⎛ - + + = 1 1 1 1 1 1 0 1 0 1 (11)
Equation ( 11) shows the additional EU imports into the African EPA configured region such as ECOWAS over and above the increase in ECOWAS imports as a result of trade creation. There isn't necessarily a net increase in imports into ECOWAS as this involves the displacement of ROW imports into ECOWAS.

EU M and

ROW M are the current imports into the African REC configuration for EPA purposes from the EU and ROW respectively. and are respectively the end and initial periods import tariffs imposed on EU imports in the destination REC with .

1 EU t 0 EU t 0 1 EU EU t t < M
σ is the elasticity of substitution between EU and ROW imports into the concerned country or REC. Trade diversion then depends on the current level of imports from the EU and ROW, the percentage change (reduction in this case) of tariffs facing EU imports with those for ROW remaining unchanged and the elasticity of substitution of the imports from the two sources. The higher the value of the elasticity of substitution, the greater will be the trade diversion effects.

Trade expansion

Adding the trade creation and diversion derives the total effect on trade. As indicated in Laird and Yeats (1986), the summation in equations ( 8) and ( 10) for an importing country can be done across products and/or across sources. It is also possible to sum the results across a group of importers for single or groups of products as well as for single sources of supply or groups of suppliers.

The revenue effect

The quantification of the revenue effect using WITS/SMART model is simple. In theory, the tariff revenue is given as the product of the tax rate (tariff rate in this case) and the tax base (the value of imports). Thus, before the change in the ad valorem incidence of the trade barriers, the revenue is given as:

∑∑ = i k ijk ijk ijk M P t R 0 0
After the change in the tariff rate, the new revenue collection will be given by:

∑∑ = i k ijk ijk ijk M P t R 1 1
The revenue loss as a result of the implementation of an EPA would then be the net effect between R 1 and R 0 which is the same as:

∑∑ ∆ = i k ijk ijk ijk M P t RL ( 12
)
The welfare effect

The WITS/SMART model estimation of welfare effects is quite simple. This is unlike the equivalent variations measurement in general equilibrium models. Essentially, the welfare effect is mainly ascribed to the consumer benefits in the importing country as a result of lower import prices4 . This allows them to substitute more expensive domestic or imported products with the cheaper imports that are affected by the relevant tariff reduction. Increased imports leads to a net welfare gain that can be thought as the increase in consumer welfare and is measured as follows:

) ( 5 . 0 ijk ijk ijk M t w ∆ ∆ = (13)
The coefficient of 0.5 captures the average between the ad valorem incidence of the trade barriers before and after their elimination/reduction. Equation ( 13) assumes that the elasticity of export supply is infinite. If this is not the case, the import prices in the importing countries fall by less than the full reduction in trade barriers. Therefore, while the equation can be used to measure welfare effect, it is no longer a representation of consumer surplus alone but has some element of producer surplus (see Laird and Yeats, 1986).

The database

WITS database comes from various sources. The external trade statistics comprise of UN COMTRADE, UNCTAD TRAINS and the WTO Integrated Data Base (IDB). The tariffs data is derived from UNCTAD TRAINS, WTO IDB and WTO Consolidated Tariff Schedule Data Base (CTS). The non-tariff measures are compiled from UNCTAD TRAINS database.

Simulation scenarios

Unlike the general equilibrium analysis where it is possible to look at several scenarios, only one simulation was undertaken for this FTA with the partial model. This scenario looks only at the reciprocity principal. Due to the weaknesses already pointed out, especially the ceteris paribus assumption upon which this model operates, only one-way liberalization is possible. The results discussed here are the possible outcomes of reducing to zero the import duties that Morocco imposes on US goods. One special advantage of the WITS/SMART model is that it allowed the analysis to be undertaken at the 6-digit level. There was therefore no aggregation problem such as the one with the GTAP database. Trade created from the full reciprocity scenario depends on the following three key elements as discussed in the analytical methodology: the initial level of trade (imports from the US); the initial level of protection; and the price elasticity of import demand.

The higher the initial level of protection, the greater the change expected from the reciprocation policy will be. The transmission mechanism for the trade effects is simple: the elimination of existing tariffs on US imports reduces the prices that consumers in the importing African country face compared to domestic substitutes, while the responsiveness of demand to the price change influences the amount of trade created or diverted. The substitutability of US goods for domestic goods is implicitly assumed. The Armington assumption at HS 6-digit level is that goods imported from different countries are imperfect substitutes. It is also assumed that the supply response to the price reduction will allow US producers and exporters to meet any demand arising in the importing countries as a result of price reduction. That is, export supplies are perfectly elastic, meaning that world supplies of each variety of the goods by origin are given.

Simulation results

This section discusses in detail the results obtained from the empirical analysis. The GTAP model analysis is complemented in the study with the SMART partial equilibrium analysis model.

General Equilibrium Results

Using the GTAP simulation model, we propose a quantitative assessment of the potential impacts of the 3 possible implementations of free trade described above on the economic growth of the two countries, on welfare, on sectoral value added, on exports, imports, trade balance and terms of trade. These results will give some tangible elements the necessity of an asymmetric agreement.

Impacts on welfare and growth

As shown in Table 2 and Figures 4 and5, the additional growth provided by trade liberalization is modest in the 2 countries, but not inconsiderable in Morocco (the rate of growth of Moroccan GDP would be increased by an additional 0.37% and a net welfare gain equal to US$37 million in the first scenario (strongly asymmetrical liberalization)).

The difference in the impact on the US and Moroccan GDP and welfare are clearly related to the difference in the size of the 2 countries and in the importance of their bilateral trade relations.

In any scenario, the impact of trade liberalization on the rate of growth would be much more important for Morocco than for the US, taking into account the difference in the bilateral trade flows sizes: US imports from Morocco represent 0.03% of total US imports, while Moroccan imports from the US correspond to 3.4% of total Moroccan imports.

Welfare effects, on the other hand, are much greater in the US. The impact on total welfare resulting from a one-dollar reduction in the price of an imported good is greater for a country with a population of 300 million than for a country with 30.6 million people. Lastly and more importantly, these results prove the importance of an asymmetrical and gradual liberalization process for Morocco. As the liberalization scenario become more liberal, the changes in GDP and welfare are lowered for Morocco. Finally, the Moroccan gains associated with Scenarios 1 and 2 result in recession and impoverishment in Scenario 3 (see table 2 andfigures 4 and5). If we consider the impact on the output, and more precisely on the variation of the value added in the 2 countries, we can conclude that the FTA creates both winners and losers in the 2 countries.

In Morocco, meat, electronic equipment, leather, textiles and clothing benefit as the trade scenario becomes more liberal. Textile and clothing apparel appear to be (and will probably be) among the biggest winners. This activity can be expected to take advantage of increasing production in a short period of time as a result of immediate liberalization. On the other hand, transport equipment, metals, mineral products and wheat lose out in the same process. Our simulation is therefore consistent with the fact that wheat is a highly political issue in Morocco. Eight million people in Morocco depend on wheat production, which is the main crop produced by small farmers. A full immediate liberalization in this sector would cause a large percentage of the Moroccan rural population to lose their livelihood. Not surprisingly, wheat is the only US product to remain subject to a quota in the actual agreement.

US farmers are expected to be the biggest beneficiaries of the agreement with Morocco, namely for wheat production, beef and animal feed, particularly for poultry which corresponds to the most important feed grain demand and the fastest growing meat production in Morocco. However, American oil seeds producers would experience severe losses in every scenario (Table 3).

Impacts on sectoral exports, imports and trade balance

The general picture is roughly the same when we consider the potential effects on trade. In Morocco, under full liberalization, the trade balance would improve particularly for clothing, sugar, vegetables and leather products, while it would deteriorate notably for wheat.

In the US, the FTA would cause the greatest improvement for chemical, rubber and plastic products and textiles, while trade deterioration would be felt most in oil seed and vegetables (Table 4). Part of these changes is related to the evolution of the terms of trade, which would deteriorate significantly for Morocco should the liberalization process be complete, immediate and perfectly reciprocal as described by the third scenario (Figure 6)

Potential Economic and Welfare Impacts of FTA on Morocco: Partial Equilibrium Results

In this section, the results using the WITS/SMART partial equilibrium model showing the possible impact of the FTA on Morocco are discussed, under the assumption of a full reciprocity, full liberalization scenario. Essentially, we want to analyze the possible consequences of a complete elimination of tariff barriers on the Moroccan economy, and more precisely the impacts on welfare, tariff revenues and exports. We choose to simulate the impact of a complete dismantlement of tariffs in order to clearly expose the effects of trade liberalization on all Moroccan products. This is therefore an "extreme scenario" which aims at delineating the general trends of the impact of liberalization of the Maroccan economy under the FTA.

The results on trade creation and diversion are also reported.

Impact on consumer's welfare

The concepts of producer and consumer surplus help economists to make welfare (normative) judgments about different ways of producing and distributing goods. In our CGE analysis, we analyzed global welfare as a whole. However, WITS only gives us the possibility to approximate the consumer surplus.

Table 5 displays the Harmonized system chapters (HS02) yielding the highest welfare gains for Morocco. Together, these 6 product groups account for more than 65% of total welfare gains in the country in the case of liberalization of trade with the US. By far, the group of products yielding the highest welfare gains are cereals (32.4%), followed by electrical equipment and plastic industries (20%).

Our simulations show that if we take into consideration only the effect on consumer welfare, as opposed to Table 2 which assesses the welfare implications for the whole of each economy, Moroccan consumers benefit greatly. They will be able to purchase US consumer goods (part of the immediate liberalization) at cheaper prices, obtaining thus an immediate -but limited -improvement in their standard of living. Indeed, in a full liberalization scenario, the total improvement in Moroccan consumer welfare would equal US$24.9 million per year (Table 4).

Moroccan consumers will derive gains from the FTA since they will have access to goods at lower prices. To this point, it is assumed that US producers and exporters will not be pricing to market. In other words, there is an implicit assumption that US exporters and Moroccan importers will pass the benefits of tariff reductions on to Moroccan consumers. If the benefits of tariff dismantlement are not passed on to Moroccan consumers but are captured by the exporter or the importer, it is possible that there will be no increase in consumer welfare.

It is therefore crucial to ensure that welfare is transmitted to consumers. To this end, it is necessary that the competition policy shield consumers against possible abuse of potential dominant positions or against collusion from large importers. Competition policy capacities and the judicial system supporting it should therefore be strengthened to ensure that the FTA delivers its potential benefits.

However, it should be noted that the overall economic welfare effects are not clear within a partial equilibrium modelling framework since producer surplus changes, especially since the supplanting of domestic producers by EU producers has not been captured in this analysis. In our CGE analysis, we have shown that total welfare will decrease to US$112 US million. This result clearly indicates that Moroccan producer surplus will suffer from a full liberalization scenario. These results could have significant implications on the structure of production in Morocco. Therefore, the results dictate clearly in favour of a progressive dismantelment in order to limit the adjustment costs.

While recognizing the weakness of consumer surplus as a proxy for welfare implications of the FTA, the partial equilibrium results tell only part of the story. Indeed, increased imports through trade creation do not only benefit consumers in Morocco. Potential gains are also likely to emanate from embodied technologies in some imports that may eventually be welfare enhancing. This will however depend on capital equipment and machinery and such imports that tend to have embodied technologies

Impact on Moroccan tariffs revenues

As would be expected, the elimination of import tariffs from the US is shown to harm government revenues in Morocco. In a full liberalization scenario, the FTA would significantly reduce Moroccan tariff revenues by more than US$147 million. Almost 60% of these losses would result from the elimination of duties on the import of US cereals (Table 6). This represents 0.5% of GDP and 4.5% of the balance of payments. One may mention that cereals account for almost 60% of the revenue shortfall. We can therefore understand why this product was treated separately during the negotiations.

In some cases, the bulk of the loss of revenues comes from the elimination of tariffs on goods that could otherwise be easily taxed (excise duty for example). Nevertheless, in terms of evaluating the FTA for Morocco, it can be noted that the foregone revenue is likely to have negative impacts on other government programmes. When this is combined with undermining regional integration, one is left with a picture that goes beyond normal international trade theory arguments. The question about the significance of non-economic reasons for integration comes into play. It is therefore necessary to look closer at the real weight of such a revenue loss on government finance. If the FTA entails full liberalization of US imports, Morocco would have to forgoe tariff revenues amounting to almost 2.5% of their public revenue.

It is important to note however that the revenue loss indicated by our simulations relates to imports tariff revenues. In reality, the increased imports presented earlier resulting from trade creation are in most countries subject to indirect taxes such as the VAT. As such, as long as there is rapid increase in the volume and value of imports into Morocco, and this country has indirect taxes such as VAT, then the revenue shortfall described will be minimized. However, unless the elasticity of the VAT and indirect taxes is significantly higher than that for import duties, it is unlikely that addition indirect tax revenues will outweigh the foregone revenue from the import tariffs. Source: Authors' WTIS simulation

Impact on exports

By providing duty free access to an American consumer market with 300 million individuals, the FTA will strongly stimulate Moroccan exports. Not surprisingly, this expansion would primarily concern the textile and clothing industry, which is the most important industrial activity in Morocco (43% of the country's industrial exports, providing 39.5% of total industrial employment). Table 7 shows that the agreement will likely have strong effects concentrated only on a limited number of sectors. Simultaneously, US exports to Morocco would increase at a still higher percentage: 36,28% against 22,58% (Table 7).

Impact on third countries

This section looks at possible impact of trade diversions on Morocco resulting from the FTA. It starts with a presentation of the losses in intra-regional trade, due to the substitution of intraregional exports by US products. Then, it will attempt to identify which products could be most affected by losses of intra-regional trade and would suffer the most from US competition.

Trade diversion is the quantity of exports (of third countries) that is being replaced by US products after liberalization. We assume here that the effect of the elimination of the tariff is fully transmited to consumer prices.

Indeed, the FTA between the US and Morocco will have significant impact not only on trade between these 2 countries, but also on the trading relationship with other countries. The most important trade diversion will affect the EU and particularly France, which is Morocco's largest trading partner. It will also have adverse effects on the other North African countries (Table 9). The FTA will thus offer the opportunity to Morocco to diversify its markets and its capabilities which are currently strongly focused on the EU, particularly France and Spain. Our partial equilibrium simulations show that imports from the US to Morocco would increase by approximately US$53.68 million. Finally, our model shows results, albeit incomplete, concerning welfare gains. It seems that consumer surplus would mainly be improved through lowering the price of industrial goods such as cars, machinery and equipment. Furthermore, the FTA would significantly reduce Moroccan tariff revenues by more than US$147 million.

Conclusion

Our analysis justifies the idea that a FTA between two zones at different levels of development needs to follow a progressive process of tariff dismantling for the most strategic sectors so as to limit the adjustment costs. It also argues in favour of an agreement which is not based on the principle of full reciprocity. Under an immediate, full and reciprocal trade liberalization, Morocco would experience a decrease in its economic growth, a loss of economic welfare, a deterioration of its terms of trade and an important deterioration of its trade balance (Scenario 3) However, strongly asymmetrical and progressive liberalization (Scenario 1) would stimulate Moroccan economic growth, improve its welfare and its terms of trade and leave the trade balance almost unchanged. Simultaneously, for the US, there is a relative indifference between the 3 scenarios as far as the impacts on welfare, the rate of growth and the evolution of the value added are concerned. Tables 2 and3 show that the effects on the US are quite similar on these levels.

When we consider the impact on the sectoral trade balance of the 3 scenarios (Table 4), the picture is more contrasted. For the US, a gradual and asymmetrical agreement would cause both improvements of the balance of trade in areas such as machinery and equipment, chemical, rubber, plastic products, wheat, and a deterioration in oil seeds, vegetables, fruits and nuts, oils and fats. However, according to our simulation, the global impact on the US balance of trade would be more advantageous with a gradual agreement (the total impact of Scenario 1 is a deterioration equal to US$77.65 million) than with the full liberalization scenario (which would cause a US$123.67 million deterioration). As a result, the move from a more liberal to a less liberal scenario seems to be mutually advantageous for the two countries, as far as the trade balances are concerned.. However, these figures must be considered cautiously. A more precise evaluation would require a dynamic simulation and a comparison of full liberalization with a scenario closer to the actual agreement, which is the objective of our oncoming research project. Beyond this strictly economic assessment, it is clear that the objectives of the FTA for the two trading partners are very different in a more general perspective:

-For Morocco, engaging in free trade with the US aims at changing the country's reliance on agriculture, which employs more than 40% of the labour force. Despite important investments in irrigation projects, this situation makes the country very vulnerable to weather hazards. As Minister of Trade and Industry Salaheddine Mezouar indicated,the government's goal is to create 500,000 jobs in industry over the next 10 years and increase the industrial gross domestic product to 23% of the total GDP by 2015 (as compared to 16% currently), and for industry to contribute 1.6% of growth in GDP every year. In short, the main objective is to reduce the country's dependence on agriculture, phosphate, and money sent home by its citizens living abroad, by developing industrial production and tourism. These objectives will require major economic and social changes and infrastructure investments (see for example the massive expansion in the northern city of Tangier which will multiply port traffic by 15 times, reduce transport costs to the US by 50% and bring Morocco to an average 6 days sea distance from the US).

-For the US, the main objective is not primarily economic, but rather geostrategic. Following the FTA with Jordan in 2000, the agreement with Morocco is a new step toward the creation of a large United States-Middle East free trade area, which is an important goal of the Bush administration, so as to integrate the Middle East into the modern global economy and create a friend and ally zone in an uncertain region. The next step will be Bahrain. National security considerations are probably the most important in this project, alongside the development of business transactions for US farmers and investors. The choice of Morocco is not random, but is the result of US political recognition of Morocco's commitment to reform, modernization and openness.

The differences identified in the objectives and the potential results of FTA are not necessarily an obstacle with the installation of a "win-win game", because development and security issues work jointly in the fight against poverty. Contemporary economic history shows that it is irrelevant to look for earnings balanced in trade relations. The differences in the specialization and the vigour of both economies examined here explain the differences of impact on the scale and the dynamics of exports. For a young economy such as Morocco, the required profits are due first to the cumulative reinforcement of growth and income, but also with the modernization of the industrial system.

It would be a huge error to believe that economic and social development can result automatically from the simple liberalization of trade, especially when the trading partner is a major world power such as the United States. After all, the success of the experiences of development does not only rely on a global integration strategy. They are also securely based on the forces and the internal resources. No sustainable development is possible if it is not based on endogenous dynamics.

  how does Morocco gain or lose based on the impacts on GDP, trade and other macroeconomic aggregates from the bilateral trade liberalization between Morocco and the US? • Second, what sectors lose and what sectors gain? • Third, what are the welfare implications for Morocco from the FTA? • Fourth, how does the formation of FTA affect trade expansion through the trade creation and trade diversion effects? • Fifth, what are the fiscal implications of the FTA?

Figure

  Figure 1. Evolution of Morocco's exports to US compared to EU25

Figure 2 .

 2 Figure 2. Evolution of Morocco' imports

Figure 3 .

 3 Figure 3. Ad valorem tariffs on different commodities (bilateral trade)

3

  The elasticity of import demand is in equation 6, allows the computation of the trade creation effect. From equation (

Figure 4 .Figure 5 .

 45 Figure 4. Impacts on welfare (in millions of US dollars)

Figure

  Figure 6. Terms of Trade (%)

Table 1 . Balance of payments, 1995-01

 1

	(US$ millions)
		1995	1996	1997	1998	1999	2000	2001
							221	144.0
	Direct investment abroad	-15	-30	-9	-20	-18	-59	-97.0
	Portfolio investment	20	142	38	24	6	17	-8.0
	Other investment	-1,083	-1,085	-1,022	-660	-4	-954	-1,006.0
	Errors and omissions	391	209	175	160	123	114	230.0
	Overall balance	-1,895	-673	-988	-640	-69	-1,167	860
	Financing	1,895	673	988	640	69	1,167	-860
	Reserve assets	984	-274	-553	-248	-1,636	416	-3,842.0
	Use of IMF resources	-101	-47	-3	0	0	0	0.0
	Exceptional financing	1,013	995	1,544	887	1,705	751	2,982.0
	Gross official reserves
	Foreign exchange reserves in terms of months of	4.6	5	5.4	5.2	6.7	5.4	9.9
	imports

Source: IMF (2002).

  Bilateral trade data is a critical component of the GTAP database. It is these bilateral trade flows that transmit policy and growth shocks between countries. Indeed, trade shares are important in explaining the simulation results. Bilateral trade is also important when looking at the terms of trade implications. The global bilateral data is sourced from the United Nations COMTRADE data. This is supplemented with individual countries global trade information and trade totals or aggregate bilateral trade statistics such as those available from the IMF, FAO and World Bank.

	Another important sub-component of the GTAP database is data protection. Data is both explicit
	and implicit. It is explicit in the sense that tariff or export revenue and anti-dumping data by
	commodity and region are available.. It is implicit in the sense that bilateral trade data is available
	both in market and world prices. The key sources of the protection data vary. Agricultural tariffs
	are obtained from the Economic Research Service, the EU and the applied or Most-Favoured
	Nation (MFN) rates. Merchandise tariffs, on the other hand, are available from the World
	Integrated Trade Solution project of the World Bank and UNCTAD (details of WITS are
	presented in the section discussing the SMART methodology). Domestic support protection data
	is obtained from the OECD's producer subsidy equivalent tables and can be divided into output
	subsidies, input subsidies, land-based and capital-based payments.

Table 2 .

 2 Impacts of the three different scenarios on welfare (in millions of US dollars) and GDP growth rate (in %)

	Scenarios	Scenario 1		Scenario 2		Scenario 3
	Regions	Welfare	GDP	Welfare	GDP	Welfare	GDP
	Morocco	37.08	0.37	26.49	0.18	-112.1	-0.78
	USA	962.02	0.03	1001.65	0.03	1115.94	0.04
	RofNAFR	-38.19	0.09	-39.55	0.09	-43.37	0.08
	ROW	-1277.54	0.06	-1303.83	0.05	-1375.13	0.05
	Source: Authors' GTAP simulation

Table 3 .

 3 Impacts of the three scenarios of trade liberalization on selected industrial and agricultural activities (% of variation of value added)

	Scenario 1	Scenario 2	Scenario 3

Table 4 .

 4 Changes in trade balance for selected products (in millions of US dollars)

	Scenario 1	Scenario 2	Scenario 3

Table 5 .

 5 Impact of full liberalization on consumer welfare in Morocco by commodity (in millions of US dollars)

	Sectors	Welfare Changes	%	Cumulative
	Cereals	8.07	32.4%	32.0%
	Electrical mchy equip parts thereof; sound recorder etc	3.20	12.8%	44.8%
	Plastics and articles thereof	1.79	7.2%	52.0%
	Paper & paperboard; art of paper pulp, paper/paperboard	1.61	6.5%	58.5%
	Rubber and articles thereof	1.16	4.6%	63.1%
	Mineral fuels, oils & product of their distillation; etc	1.13	4.5%	67.6%
	Vehicles o/t railw/tramw roll-stock, pts & accessories	0.85	3.4%	71.0%
	Tobacco and manufactured tobacco substitutes	0.79	3.2%	74.2%
	Aircraft, spacecraft, and parts thereof	0.75	3.0%	77.2%
	Nuclear reactors, boilers, mchy & mech appliance; parts	0.66	2.7%	79.9%
	Iron and steel	0.46	1.8%	81.7%
	Cotton	0.40	1.6%	83.3%
	Man-made staple fibres	0.36	1.4%	84.8%
	Miscellaneous chemical products	0.33	1.3%	86.1%
	Articles of iron or steel	0.32	1.3%	87.4%
	Pharmaceutical products	0.24	1.0%	88.3%
	Others	2.8	11.7%	100.00%
	Total	24.9	100.0%
	Source: Authors' WTIS simulation

Table 6 .

 6 Impact of full liberalization on tariff revenue losses in Morocco

	(Millions of US dollars)
	Description	Variation of tariff revenues	%
	Cereals	-85.93 58.4%
	Electrical mchy equip parts thereof; sound recorder etc	-9.90	6.7%
	Mineral fuels, oils & product of their distillation; etc	-7.19	4.9%
	Paper & paperboard; art of paper pulp, paper/paperboard	-6.27	4.3%
	Tobacco and manufactured tobacco substitutes	-5.54	3.8%
	Oil seed, oleagi fruits; miscell grain, seed, fruit etc	-5.147	3.5%
	Nuclear reactors, boilers, mchy & mech appliance; parts	-3.43	2.3%
	Aircraft, spacecraft, and parts thereof	-2.45	1.7%
	Vehicles o/t railw/tramw roll-stock, pts & accessories	-2.17	1.5%
	Iron and steel	-2.09	1.4%
	Cotton	-1.57	1.1%
	Articles of iron or steel	-1.54	1.0%
	Man-made staple fibres	-1.43	1.0%
	Rubber and articles thereof	-1.06	0.7%
	Pharmaceutical products	-0.97	0.7%
	Others	-10.50	7.0%
	Total	-147.21 100%

Table 7 .

 7 Total impact of full liberalization on Morocco's exports to the US in selected products (in thousands of US dollars and as a % of the sectoral Moroccan exports to the US)

	Products

Table 8 .

 8 Total impact of full liberalization on US exports to Morocco (Millions of US dollars)

	Before	After	Change In Revenue	% of increase
	567.57	773.51	205.936	36.28%
	Source: Authors' WTIS simulation

Table 9 .

 9 Impact of full liberalization on Moroccan trade with third countries (in millions of US dollars)

	Partner

As emphasized inLaird and Yeats (1986), in the case of pre-existing level of imports, there is no net welfare gain in the country as the tariff reduction simply means a reallocation/transfer of revenue from the government to the consumers.


Wenjie Li

Francesca Bassi

Laura Galluccio

Michel Kieffer

Self-Rating in a Community of Peers

Consider a community of agents, all performing a predefined task, but with different abilities. Each agent may be interested in knowing how well it performs in comparison with her peers. This general scenario is relevant, e.g., in Wireless Sensor Networks (WSNs), or in the context of crowd sensing applications, where devices with embedded sensing capabilities collaboratively collect data to characterize the surrounding environment, but the performance is very sensitive to the accuracy of the gathered measurements.

This paper presents a distributed algorithm allowing each agent to self-rate her level of expertise/performance at the task, as a consequence of pairwise interactions with the peers. The dynamics of the proportions of agents with similar beliefs in their expertise are described using continuous-time state equations. The existence of an equilibrium is shown. Closed form expressions for the various proportions of agents with similar belief in their expertise is provided at equilibrium. Simulations match well theoretical results in the context of agents aiming at determining the performance of their sensors.

I. INTRODUCTION

We consider a situation where all the agents in a community are engaged in some activity (sensing, estimation, classification...), for which it is reasonable to expect heterogeneous levels of ability. The agents, who regularly meet their peers and interact with them in pairs, are incentivated to self-rate their own capabilities at the task in order to better address their future actions. This general scenario may well describe, e.g., the needs of a group of amateur chess players trying to pair up with opponents of comparable strength; or the situation of a sensor network, where devices with embedded sensing capabilities collaboratively collect data to characterize the surrounding environment, and nodes with scarce sensing accuracy may prefer to withhold their contribution to avoid to pollute the data. This may happen, for instance, in the context of crowdsensing scenarios [START_REF] Guo | Mobile crowd sensing and computing: the review of an emerging human-powered sensing paradigm[END_REF], where, in order to provide reliable sensing services such as those advocated by the S 2 aaS (Sensing as a service) paradigm [START_REF] Sheng | Sensing as a Service: challenges, solutions and future directions[END_REF], there is a need for high quality measurements that are not always available at devices since this is tightly related to the accuracy of the sensors embedded.

This problem is counteracted in S 2 aaS scenarios by introducing reputation-based mechanisms [START_REF] Yu | Reputation-based incentive protocols in crowdsourcing applications[END_REF]- [START_REF]Reputation-based sensing-as-a-service for crowd management over the cloud[END_REF]. In such schemes sensing data are collected from smart-phones, based on an auction mechanism. The sensing task is assigned to the nodes by the central authority on the basis of their reputation level, to maximize the utility for the crowd. Such reputationbased mechanisms are effective in rating the agents of the community, but are based on data centralization and need to establish a rating authority. Allowing agents to assess their ability has the benefit to help them providing measurements as well as their associated quality levels. This facilitates further measurement processing and may avoid compromising the reputation of an agent temporarily producing outliers. Moreover, in S 2 aaS applications, agents knowing that their sensing ability is above the average may negotiate a better reward for their measurements.

This work considers instead distributed mechanism that nodes can employ to self-rate their capabilities. A distributed classification approach is taken in the context of WSN by the works in [START_REF] Chiuso | Gossip algorithms for simultaneous distributed estimation and classification in sensor networks[END_REF], [START_REF] Fagnani | A distributed classification/estimation algorithm for sensor networks[END_REF], where different nodes are subject to different sensing noise models characterized by hidden parameters. Each node is willing to co-operate with the rest of the network via gossip or consensus algorithms to estimate the common observed physical quantity, and simultaneously learns its sensing model. For these algorithms to converge, however, the WSN architecture needs to guarantee large static connectivity for each node, and to disseminate node identification. In this work we propose an alternative approach to distributed self-rating where instead nodes can be mobile, connectivity can be dynamic, and identification is not used by the algorithm, allowing, e.g., for node substitution or removal without disrupting the network functionality.

The proposed distributed self-rating (DSR) algorithm needs a Local Comparison Test (LCT) adequate to establish which agent of a pair of agents engaged in the test is better in performing the task. The self-rating algorithm consists then in performing a LCT when two agents meet, and in counting the number of positive test outcomes as well as the number of past meetings. The agents, who have knowledge of the expected proportion of nodes in each group, maintain a selfrating which evolves in time, and converges fast and reliably. The effectiveness of the proposed algorithm is measured by the correct grade rate (CGR), i.e., the proportion of agents whose self-rating result corresponds to the real level, and by the false grade rate (FGR), i.e., the proportion of agents who self-rate the wrong class. The behavior of the algorithm is described by state equations. The influence of the characteristics of the LCT of the CGR and the FGR at equilibrium provides insights to optimize design.

The paper is organized as follows. Section II introduces the system model and LCT. Section III introduces and analyzes the proposed DSR algorithm. The CGR and the FGR at equilibrium is characterized in Section IV. Simulations results are reported in Section V and conclusions in Section VI.

II. SYSTEM MODEL AND LOCAL COMPARISON TEST

Consider a set S of N S moving agents. Assume that the agents in S are partitioned into N G groups S 1 , . . . S NG , containing respectively a proportion p 1 , . . . , p NG of the agents. A group contains agents able to perform some task with a similar level of expertise or reliability. Groups are sorted in decreasing levels of expertise. Let θ i (t) ∈ G = {1, . . . , N G } be the index of the group S θi(t) to which Agent i belongs at time t. Initially, Agent i is not aware of the actual value of θ i but is willing to estimate it as fast as possible. We assume that the group to which Agent i belongs does not change over the time horizon of the experiment, so θ i (t) = θ i .

One will present a DSR algorithm allowing each Agent i to get an estimate θ i of its group θ i . For that purpose an LCT is introduced, performed by Agent i after meeting and interacting with any Agent j. Meetings are assumed to involve only two agents. The output y i,j of the LCT performed by Agent i upon interaction with Agent j is binary. The LCT determines whether Agent i is better at doing the considered task than Agent j (y i,j = 1), or vice-versa (y i,j = 0), without being able to determine the Agent i's absolute level of expertise. LCTs may provide erroneous conclusions and are characterized by their statistical properties q (θ i , θ j ) = P {Y i,j = 1|θ i , θ j } .

(

One assumes that θ i θ j implies q (θ i , 1) q (θ j , 1), which appears reasonable, since the first group contains the agents with the highest level of expertise.

Interactions may take various forms depending on the application scenario, ranging from the exchange of noisy measurements m i and m j of the same physical quantity when the agents are nodes of a WSN, to a blitz-game between humans, willing, e.g., to self-rate their level in chess. An example LCT is provided in Section V in the context of WSNs. A meeting between two nodes does not necessarily entail interaction: one assumes here that the probability of interaction α( θ i , θ j ) is a function of the estimates θ i (t) and θ j (t) of the groups to which each agent belongs. When the agents aim is to self-rate their level in chess, for instance, α( θ i , θ j ) will approach one when θ i and θ j are close and thus the outcome of the LCT is reputed unpredictable, and be small when θ i and θ j are very different, thus preventing the agents wasting time in a LCT whose outcome is reputed easily foreseeable. In practice, one assumes that when two agents i and j meet, they start exchanging the estimated index of their group, Agent i will request for a further interaction with probability α( θ i , θ j ) and Agent j with a probability α( θ j , θ i ).

III. DISTRIBUTED SELF-RATING ALGORITHM

In the proposed DSR algorithm, each agent manages two counters c t,i (t) and c b,i (t) initialized at 0 at t = 0. The number of LCTs performed by Agent i and following an Algorithm 1 DSR algorithm for Agent i

1) Initialize t 0 i = 0, θ i t 0 i = 1, c t,i t 0 i = c b,i t 0 i = 0, κ = 1, and µ = 0. 2) Do θ i (t) = θ i t κ-1 i , c t,i (t) = c t,i t κ-1 i , c b,i (t) = c b,i t κ-1 i
, and t = t+δt until the κ-th meeting occurs at time t κ i with Agent j κ ∈ S. 3) Transmit θ i (t κ i ) to Agent j κ and receive θ j κ (t κ i ) from Agent j κ . 4) With probability α θ i (t κ i ) , θ j κ (t κ i ) , perform a LCT with outcome y µ i , then a) µ = µ + 1. Update c t,i and c b,i as

c t,i (t κ i ) = min {µ, M } c b,i (t κ i ) = µ m=max{1,µ-M +1} y m i (2) b) Update θ i according to 3 5) κ = κ + 1. 6) Go to 2.
interaction it has requested is stored in c t,i (t). The number of LCTs concluding that Agent i is better than the agent met is stored in c b,i (t). An agent involved in an interaction it has not requested does not update c t,i (t) and c b,i (t). If the agents are randomly spread, the ratio c b,i (t)/c t,i (t) mainly depends on the proportions of agents in each group, on the interaction probabilities, and on the properties of the LCT.

Intuitively, an agent belonging to Group 1 is likely to have a larger ratio c b,i (t)/c t,i (t) than an agent belonging to Group N G . Introducing the partition of [0, 1] into N G decision intervals [ν k , ν k-1 ) with ν 0 = 1 and ν NG = 0, one may consider the decision rule

θ i (t) = k if c b,i (t)/c t,i (t) ∈ [ν k , ν k-1 ) , ∀k ∈ G. (3)
Agents with the largest value of c b,i (t)/c t,i (t) choose the smallest group index. One will show that the decision rule (3) leads to a satisfying self-rating of the agents, for an appropriate choice of the value of ν k , for all k ∈ G.

The values of α( θ i , θ j ) can be adjusted to optimize the performance of the DSR algorithm.

A. Practical Self-Rating Algorithm

Let x i (t) = (θ i , c t,i (t), c b,i (t)
) represent the state of Agent i. If all the LCT results obtained in the past are considered, one has lim t→∞ c t,i (t) → ∞, which results an infinite number of possible values for x i (t). The global (macroscopic) behavior of the algorithm is in this case difficult to analyze. To limit the number of possible states, one considers the evolution of c t,i (t) and c b,i (t) over a sliding variable-length time interval containing the time instants of the last M meetings during which Agent i has performed a LCT. Algorithm 1 summarizes the proposed DSR algorithm for an arbitrary Agent i.

B. Evolution of the state of an agent

At time t, among the agents in Group θ, let X ,d θ (t) be the proportion of agents in state x i (t) = (θ, , d), i.e., with One has first to evaluate the probability that some Agent i with state (θ, , d) and estimated rating θ ( , d) performs a LCT upon meeting a random Agent J. This probability may be evaluated as β ( , d) = E(α( θ ( , d) , θ J (t)))where the expectation has to be taken over θ J (t). Then

β ( , d) = k 1 ,k 2 ∈G α( θ ( , d) , k2)P θJ (t) = k2, θJ = k1 = k 1 ,k 2 ∈G α( θ ( , d) , k2)P θJ (t) = k2|θJ = k1 P {θJ = k1} = k 1 ,k 2 ∈G α( θ ( , d) , k2)p k 1 p k 1 k 2 (t) . (4)
In ( 4), one uses the fact that agents are randomly spread to get P {θ J = k 1 } = p k1 . We introduce p k1k2 (t) as the proportion of agents in Group k 1 believing their group index is k 2 . Finally, one has θ

( , d) = k when d/ ∈ [ν k , ν k-1 ). More specifically, p k1k2 (t) = P θ J (t) = k 2 |θ J = k 1 = X 0,0 k1 (t) + ,d,d/ ∈[ν k 2 ,ν k 2 -1) X ,d k1 (t) , if k 2 = 1, ,d,d/ ∈[ν k 2 ,ν k 2 -1) X ,d k1 (t) , else. (5)
Two phases have to be considered in Algorithm 1, depending on the value of c t,i (t). In the transient phase, for states with c t,i (t) = < M , one has (δ t , δ b ) ∈ {(0, 0) , (1, 0) , (1, 1)}, since may either increase or remain constant and δ b δ t . The only possibility leading to δ t = 0 is that Agent i, once it has met a random Agent J, decides not to continue interaction. Then π 0,0 θ (t, , d) = 1 -β ( , d). A state transition occurs with (δ t , δ b ) = (1, 1) when, once Agent i has met Agent J, they continue interaction and the LCT yields y i (t) = 1. Since α only depends on the group estimates, these two events can be assumed as independent. Considering all possible values taken by θ J (t) one gets

π 1,1 θ (t, , d) = k 1 ,k 2 ∈G α( θ ( , d) , k2)P{Yi = 1, θJ = k1, θJ (t) = k2|θi = θ} = k 1 ,k 2 ∈G α( θ ( , d) , k2)p k 1 p k 1 k 2 (t) q (θ, k1) . (6)
Finally, π 1,0 θ (t, , d) is obtained similarly as (6),

π 1,0 θ (t, , d) = k 1 ,k 2 ∈G α( θ ( , d) , k2)p k 1 p k 1 k 2 (t) (1 -q (θ, k1)) . (7)
In the permanent regime, c t,i (t) = M and remains constant, thus δ t = 0. In Algorithm 1, µ is the number of LCTs performed by Agent i till time t. When µ M , only the last M LCT outcomes are considered. To determine the value taken by δ b ∈ {-1, 0, 1} after the µ-th LODT, consider an arbitrary y ∈ {0, 1} and the random event Assume that the (µ -M )-th LCT performed by Agent i occurred at time t, then y µ-M i can also be denoted as y i t and the transition related to c b,i is such that δ b = y i (t) -y i t ∈ {-1, 0, 1} . To have (δ t , δ b ) = (0, 1), three independent events have to occur: 1) interaction has to continue once Agent J has been met; 2) y i (t) = 1; 3) y i t = 0, i.e., E 0 (t). Following derivations similar to (6),

E y (t) = Y µ-M i = y| µ-1 m=µ-M Y m i = d ,
π 0,1 θ (t, M, d) = k 1 ,k 2 ∈G α θ (M, d) , k2 p k 1 p k 1 k 2 (t) q (θ, k1) M -d M . (8)
Similarly,

π 0,-1 θ (t, M, d) = k 1 ,k 2 ∈G α θ (M, d) , k2 p k 1 p k 1 k 2 (t) (1 -q (θ, k1)) d M . (9)
Applying (8-9), π 0,0 θ (t, M, d) can be obtained from

π 0,0 θ (t, M, d) = 1 -π 0,1 θ (t, M, d) -π 0,-1 θ (t, M, d).

C. Macroscopic evolution

All agent state transition probabilities evaluated in Section III-B are now used to determine the evolution of the various proportions X ,d θ (t) of agents in the corresponding states. In what follows, one assumes that agents are mobile and form a well-mixed population. Considering an intercontact rate λ, during a short time interval [t, t + δt], the number of agents with state (θ, , d) that will meet another agent can be estimated as λp θ N S X ,d θ (t)δt. When 0 < d < < M , these agents will switch to the states (θ, + δ t , d + δ b ), with a probability π δt,δb θ (t, , d), where (δ t , δ b ) ∈ {(0, 0) , (1, 0) , (1, 1)}. Moreover, agents in the states (θ, -1, d -1) and (θ, -1, d) that have met another agent in the time interval [t, t + δt] may reach state (θ, , d), respectively with a probability π 1,1 θ (t, -1, d -1) and π 1,0 θ (t, -1, d). The evolution of X ,d θ (t) is then described by the following differential equation (10-c), in which the time dependency is omitted to lighten notations. Similar derivations can be made for the remaining state components to obtain the following equations.

                                                                           dX 0,0 θ
To analyze the asymptotic behavior of the state equations [START_REF] Li | Peer-assisted individual assessment in a multi-agent system[END_REF], one considers a special case where α (k 1 , k 2 ) = 1 if k 2 = 1 and α (k 1 , k 2 ) = 0 else. Interaction is only performed when an Agent i meets an Agent j believing it is in the best group. As will be seen in Section V, this strategy is efficient to self-rate agents equipped with sensors of different quality.

One investigates first the evolution of X ,k θ (t) when < M . in the following proposition.

Proposition 1: For any d < M , lim t→∞ X ,d θ (t) = 0. Proposition 1 is proved by extending the proof of Proposition 2 in [START_REF] Li | Distributed faulty node detection in delay tolerant networks: Design and analysis[END_REF], to θ discrete. As a consequence, the only possible value at equilibrium of X ,d θ (t) with < M is 0. Let X M,d θ be the value at equilibrium of X M,d θ . The proportion of agents estimating their group as θ depends on the partition of the interval [0, 1] introduced in (3)

p θ θ = d:d/M ∈[ν θ ,ν θ-1 ) X M,d θ . ( 11
)
Denote p 1 = p 11 , . . . , p NG1 T and consider the functions

h θ p 1 = k∈G p k p k1 q (θ, k) k∈G p k p k1 , (12)
F θ p 1 = M d= ν 1 M M d h θ p 1 d 1 -h θ p 1 M -d , (13)
and F p 1 = F 1 p 1 , . . . , F NG p 1 T . The following proposition provides a non-linear equation that has to be satisfied by p 1 . Once this equation is solved, one easily deduces the various X M,d θ at equilibrium. Proposition 2: Assume that (10) admits some equilibrium X ,d θ , then for any θ ∈ G and d , X

,d θ = 0 when < M and

X ,d θ = M d h θ p 1 d 1 -h θ p 1 M -d (14)
when = M , where p 1 are obtained by solving

p 1 = F p 1 .
(15) See Section IV-A for the proof.

The existence of X M,d θ depends on whether (15) has a solution p 1 . One then shows the existence of an equilibrium in Proposition 3 in the special case where N G = 2.

Proposition 3: In the case N G = 2, for any ν 1 ∈ [0, 1], (15) always admits a solution, and ( 10) admits an equilibrium. See Section IV-B for the proof.

E. Approximations of the equilibrium

Explicit expressions for p θ1 are difficult to obtain from (15). Since p θ1 with θ = 1 represent the proportions of agents that have wrongly estimated their group, the vector p 1 = p 11 , . . . , p NG1 T should be close to p 1 = [1, 0, . . . , 0]

T .

One has lim p 1 → p 1 h θ p 1 = q (θ, 1). Assuming that at equilibrium, h θ p 1 q (θ, 1), using (14), X M,d θ can be approximated as

X M,d θ = M d (q (θ, 1)) d (1 -q (θ, 1)) M -d , (16)
and follows thus a binomial distribution. Knowing X M,d θ for all θ ∈ G and all d M gives some insights to properly tune the decision thresholds introduced in (3). The values of the ν θ s may for example be adjusted to maximize θ∈G p θθ , see the extended version of this paper [START_REF] Li | Peer-assisted individual assessment in a multi-agent system[END_REF] for details.

IV. PROOFS

A. Proof of Proposition 2

At equilibrium, one has dX ,d θ (t)/dt = 0 for all 0 d M and the transition probabilities will not vary any more. From Proposition 1, one has X ,d θ = 0, for all d < using (18).

B. Proof sketch of Proposition 3

The existence of a solution of (15) when N G = 2 is shown using Brouwer's fixed-point [START_REF] Granas | Fixed point theory[END_REF]. One shows first that for any p 11 0 , p 21 0

∈ P 0 = {(x, y) ∈ [0, 1] × [0, 1] and (x, y) = (0, 0)}, the discrete- time system 1 p 11 n+1 , p 21 n+1 = F 1 p 11 n , p 21 n , F 2 p 11 n , p 21 n . (19)
converges to a equilibrium point p 11 , p 21 . Both F 1 and F 2 are continuous functions, however P 0 is not a compact set. Thus one needs to find a compact P n such that F 1 p 11 n , p 21 n is a mapping P n → P n . One starts showing some useful lemmas.

Lemma 4: If (x, y) ∈ P 0 , then h θ (x, y) is bounded as 0 < h θ,min h θ (x, y) h θ,max , where h θ,max = max{q(θ, 1), q(θ, 2)} and h θ,min = min{q(θ, 1), q(θ, 2)}.

Lemma 5: Define g(z)

= M d= M ν1 M d z d (1 -z) M -d . If 0 < ν 1 < 1, then g(z) is increasing over [0, 1].
Lemma 4 can be easily proved by comparing h θ with h θ,max and h θ,min . The proof of Lemma 5 can be found in [START_REF] Li | Distributed faulty node detection in delay tolerant networks: Design and analysis[END_REF]. From Lemma 4 and 5, one obtains that for any θ ∈ {1, 2} and (x, y)

∈ P 0 0 < g (h θ,min ) F θ (x, y) g (h θ,max ) . (20)
Define p θ1 n,max and p θ1 n,min as upper and lower bounds of p θ1 n , i.e., p θ1 n,min p θ1 n p θ1 n,max . When n = 0, p θ1 0,min = 0 and p θ0 0,max = 1. From (20), one gets h θ,max ,

p θ1 1,min = g (h θ,min ) > 0, p θ1 1,max = g (h θ,max ) . (21)
1 Notice that one never has p 11 0 = p 21 0 = 0, which can be obtained from Lemma 9 and Lemma 10 in [START_REF] Li | Distributed faulty node detection in delay tolerant networks: Design and analysis[END_REF]. Therefore F maps P 1 to P 1 , which is compact. Applying Brouwer's fixed-point theorem one proves Proposition 3.

V. ILLUSTRATION

Consider a scenario where all agents are equipped with a sensor providing noisy observations of the scalar physical quantity φ (o, t), at location o and at time t. For Agent i,

m i (o, t) = φ (o, t) + w i , ∀i ∈ S. (23)
The components w i of the measurement noise in (23) are assumed to be realizations of random Gaussian variables W i ∼ N e i , σ 2 , where e i is a constant agent-dependent bias. The agents can be classified according to the value of e i . Assume that among different sensors, the absolute value |e I | of a random agent I follows an exponential distribution with parameter γ. For example, Group θ can be defined as

S θ = {i ∈ S : θ -1 |e i | < θ} for any θ ∈ G \ {N G } and S NG = {i ∈ S : |e i | N G -1}.
Therefore, the proportion of agents in Group θ is p θ = exp (-γ (θ -1)) -exp (-γθ). Agent i does not know the characteristics of W i and aim at using Algorithm 1 to self-rate its sensor. For that purpose, when meeting other agents, it will share measurements performed at close locations and run the LCT introduced in Section V-A.

A. LCT

Consider some tolerance ω and the interval [m] = [m -ω, m + ω] of width 2ω centered around some measurement m. Assume that Agents i and j meet and exchange the measurements m i and m j . The set estimate [START_REF] Belforte | Parameter estimation algorithms for a set-membership description of uncertainty[END_REF] of φ obtained combining m i and m j is defined as [ φ (m i , m j )] = [m i ]∩[m j ], which may be used to define the low-complexity LCT y i = y j = 1, if [ φ (m i , m j )] = ∅ and y i = y j = 0 else. If [ φ (m i , m j )] = ∅ it is likely that the biases e i and e j are of the same order of magnitude and both agents can conclude that their sensor performs similarly. If [ φ (m i , m j )] = ∅, it is likely that e i and e j differ significantly more than ω. One is unable to indicate which agent has the best sensor in that case, so, both agents choose to conclude that its sensor behaves worse than that of the other agent.

For any pair of groups (θ i , θ j ), one is able to evaluate the probability q (θ i , θ j ) as a function of ω, σ, and γ.

B. Numerical verification of theoretical results

This section presents first the evolution of the proportion of nodes in various states given by [START_REF] Li | Peer-assisted individual assessment in a multi-agent system[END_REF]. Algorithm 1 is simulated considering a random displacement of agents without constraint on their speed. One takes N G = 4, σ 2 = 0.25, γ = 0. at the equilibrium: circles are for the theoretical values obtained integrating [START_REF] Li | Peer-assisted individual assessment in a multi-agent system[END_REF], triangles are the approximations obtained from (16), and crosses are for the moving agents simulation.

Besides, one considers M = 50, and a sampling period ∆t such that λ∆t = 0.33. The interaction probability α is as in Section III-D and the decision thresholds are chosen as ν 1 = 0.8, ν 2 = 0.45, ν 3 = 0.1, and ν 4 = 0. Figure 2 presents the evolution p θ θ (t), for θ, θ ∈ G. One observes that the proportions of agents in each state converge. For any θ ∈ G, p θθ is close to 1 for t sufficient large, while p θ θ tends to 0 for any θ = θ, showing the efficiency of Algorithm 1.

Consider now a set S of N S = 1000 moving agents which initial position is uniformly distributed over a unit square. Agents randomly choose their location at time (k + 1) ∆t, independently from their previous location at time k∆t. Two agents communicate only at discrete time instant k∆t when their distance is less than r 0 . The value of r 0 can be adjusted so that the inter-contact probability during ∆t is λ∆t ≈ 0.33. The resulting evolutions of p θ θ (t) are in Figure 2 and match closely those predicted by the direct integration of the state equation.

Figure 3 further illustrates the good match between theory and simulation for the proportions of states X 50,d θ at equilibrium. The approximation of X 50,d θ using ( 16) is also provided in Figure 3, which is also close to its actual value.

Similar results have been obtained with agents following a Brownian motion model.

VI. CONCLUSIONS

This paper has investigated the problem of helping agents self-rating their expertise level at doing some task via exchange of information with peers. Using local comparison tests involving, e.g., data exchanged during meetings with other agents, each agent is able to estimate the proportion of agents it is better at doing the considered task. With that information, each agent may then determine to which group of agents with similar expertise it belongs to.

The behavior of the proposed algorithm is described using dynamical equations. The existence of an equilibrium is established. The proportions of agents with similar beliefs in their expertise is characterized at equilibrium. This gives some insight in the tuning of the various parameters of the proposed algorithm.

The approach is illustrated with agents equipped with sensing devices of different sensing performance, which may be found in crowd sensing scenarios. Simulation results are in good match with theory.

Significant work remains to be done to analyze the behavior of the proposed algorithm with generic probabilities of interaction. The existence and uniqueness of the equilibrium has also to be shown in the general case. Nevertheless, the proposed approach may be useful to analyze other types of self-rating problems.

Fig. 1 .

 1 Fig. 1. Example of Markov model for the evolution of the state of an agent when M = 3.

  c t,i (t) = and c b,i (t) = d. Since ∈ {0, . . . , M } and d ∈ {0, . . . , }, the number of values that may be taken by the state of an agent is (M + 1) (M + 2) /2. The evolution of the state of Agent i, conditioned by the index θ of its actual group, follows a Markov model with state transition diagram similar to that shown in Figure1for M = 3.There are N G parallel chains conditioned by the value of θ ∈ G. Define π δt,δb θ as the transition probability from State (θ, , d) to State (θ, + δ t , d + δ b ). Note that π δt,δb θ depends on the current state (θ, , d) of the reference agent, and also on the current proportion of agents with estimation θ i (t).

  which corresponds to a situation where one knows that k LCTs yield 1 among the last M tests and Y µ-M i = y will be ignored once the new LCT outcome is available. P {E 1 (t)} is relatively complex to evaluate, since P {Y n i = y} depends on the actual group of the encountered agent and is time-varying. Assuming that LCT outcomes with Y m i = y, are independently distributed over the time horizon corresponding to m = µ -M, . . . , µ -1, one gets P {E 1 (t)} = d/M and P {E 0 (t)} = 1 -d/M .

1 g

 1 which leads tog (h θ,min ) p θ1 n = F θ p 11 n-1 , p 21 n-(h θ,max ) . (22)

7 ,Fig. 2 .

 72 Fig.2. Evolution of p θ θ (t), lines are for the theoretical values obtained solving[START_REF] Li | Peer-assisted individual assessment in a multi-agent system[END_REF], dots are simulation results using the random displacement model.

  Fig. 3. Comparison of X 50,d θ

M,d θ

This work was supported by the NoE NEWCOM# and by the Paris-Saclay ICODE project