text:
### African Journal ofMarketing Management

• Abbreviation: Afr. J. Mark. Manage.
• Language: English
• ISSN: 2141-2421
• DOI: 10.5897/AJMM
• Start Year: 2009
• Published Articles: 153

## Globalization, technology transformation and economic growth (A case study of Pakistan)

##### Bushra Mushtaq
• Bushra Mushtaq
• Department of Economics Virtual University Lahore, Pakistan.
##### Syeda Azra Batool
• Syeda Azra Batool
• Department of Economics Bahauddin Zakariya University Multan, Pakistan.
• University of the Punjab Lahore, Pakistan.

•  Received: 02 April 2011
•  Accepted: 23 July 2014
•  Published: 30 September 2014

ABSTRACT

How Economic Growth can be stimulated? This question has called the attention of every policy maker and economist to find the answer. What factors can affect the economic growth? The answer of this question is unclear so far. After the endogenous growth theory as given by Romer (1986, 1990), Lucas (1988) and Grossman and Helpman (1991) Knowledge is being considered as an important and endogenous determinant of Economic growth. The latest knowledge (Technology) is essential for developing countries to catch-up with developed economies. Economic liberalization refers to both trade liberalization and financial liberalization. Trade liberalization means reduction in trade restrictions like tariff, quota or other trade barriers which discourage the international trade. On the other hand, more capital inflow and outflow as a result of Foreign direct investment (FDI), portfolio investment or worker remittances show that the country is financially integrating with rest of the world. How the economic liberalization affect the Economy of any particular country. Whether this economic liberalization is good or bad for developing country has become a huge policy debate.

Key words: Technology transmission, Liberalization, R&D Spillovers, Foreign direct investment (FDI).

INTRODUCTION

Almost all developing economies face the scarcity of technology. Technology is very essential to enhance the productivity of factor of production and economic growth. That’s why developing countries have low economic growth than developed countries, because the developing countries spend less on research and development while developed countries heavily spend on R & D. Furthermore, high concentration of technology is in the hands of developed counties. According to the Global Competitiveness Report 2011 to 2012, Pakistan ranks at 93 number in term of Availability of latest technology index while India ranks at 47, Turkey 52 and Sri Lanka 63. These figures clearly show Pakistan’s weak R&D base as compared to countries of her region. So dependence on foreign source of Technology is very crucial and important for Pakistan. Similarly, World Economic forum which have ranked all the counties to see at what extent business of a country can absorb new technology. According to report (2011 to 12), Pakistan’s rank is 92 while Indias rank is 41, Sri Lankas 42 and Turkey has ranked at 44. The index which evaluates the capacity of FDI for the transmission of new technology into a country has ranked Pakistan in the rank of 121, India in 38 and Sri Lanka in 45.

There are many channels through which Technology can be transferred from developed countries. The direct import of Technology embodied machinery and intermediate goods is one channel of transmission of Technology. Foreign direct investment by multinational companies (MNCs) is another source of international Technology transmission. The MNCs import not only Technological modern machinery but also the Ideas and knowledge generated through R & D carried out in parent country. In addition there is movement of employees or managerial talent from developed economies to low and middle income economies when these countries open their economies. Kortum (Many studies have identified the different channels of technology transformation like Eaton 1996) considered licensing agreements as a direct channel of transfer but according to World Investigation Report (2010), the licensing agreement cannot bring the valuable and latest technology.

To absorb the foreign technology brought by foreign investors, the absorption capacity of host country matters a lot. Most studies use an appropriate level of human capital as a measure of absorption capacity[1]. Because, without minimum level of skill or knowledge (absorptive capacity), local firms cannot get knowledge benefit of technology transmission via foreign direct investment (UNCTAD, 2010).[2] To absorb the foreign technology brought by foreign investor, the absorption capacity of host country matters. Most studies use level of human capital as measure of absorption capacity[3]. The negative relationship between foreign direct investment and economic growths indicates the lack of high skilled labor force and basic infrastructure to absorb the foreign technology which comes through foreign direct investment. This lack of capabilities and inefficiencies in technological learning prevent spillover impact of MNC’s on economic growth of Pakistan. As without minimum level of skill or knowledge (absorptive capacity) the local firms cannot get knowledge benefit of technology transmission through foreign direct investment (UNCTAD, 2010).[4] Many studies have shown that foreign sources of Technology are important contributor to productivity growth for the developed economies. Less developed economies spend less on R & D and face scarcity of modern Technology. The import of Technology or transmission of Technology from developed countries is a key question for their economic growth. There is a lot of controversy regarding the Technology transmission whether it is good or bad for developing countries. Some Economist argues that more open economies have more ability to absorb technology generated in advanced countries. Some economist like Coe and Helpman (1995) showed that transmission of technology and related knowledge from developed counties to developing countries through export and import will be more effective in economies with better and advanced education.

Several economists favor the hypothesis of “learning by exporting”. There is a lot of literature which shows that exporters are more productive on average as compared to non-exporters[5]. The question is whether the productivity increases because of “learning by exporting” or productivity leads to more export? Most evidences are in the favor that when any country starts exporting, the firms of that country get benefit from interacting with customer of the world. These customer demand higher quality products and in this way impose condition to produce higher standard products as compared to domestic customer demand. After entering into the foreign markets, firms gain new knowledge and latest technical expertise which facilitate to improve their efficiency level. Other positive contribution of economic liberalization through trade openness to growth can be that liberalization increases specialization and division of the labor thereby improving productivity and export capability. Expansion production of exportable products can lead to production growth by adoption and transmission of modern method of production. Many theorists also are in the view that gains from trade can be in the form that the reduction of trade restriction increase the economic efficiency by making consumers and producers able to buy items at lowest cost. Openness is an important issue but little research has been done on the significance of inter-national Technology transmission for the low and middle income economies like Pakistan.

Trade and investment policies of Pakistan are fairly liberal since the late 80s the average tariff rate come down to just 20% in 2001 to 02 which is only half as compared to the mid-1990s. In the foreign investment policy 1997 Pakistan has opened most sectors of economy to FDI, by giving 100% foreign ownership except some conditionality like the provision of national treatment to foreign companies by following the WTO obligations by giving some incentives such as duty and tax exemptions and some other concessions. Pakistan has taken many steps for inward FDI but is not able to attract large FDI. FDI is very important for Pakistan but it has played a small role in Pakistan economy. In most year of the ratio of FDI to GDP is less than 1%. After independence FDI was very crucial for the success of both import substitution and infant industry.

[1] Nelson and Phelps (1966), Benhabib and Spiegel (1994).

[2] United Nation Conference on Trade and Development, 2010.

[3] Nelson and Phelps (1966), Benhabib and Spiegel (1994).

[4] United Nation Conference on Trade and Development, 2010.

[5] (Bernard and Jensen 1999)

[6] “President of the federation of Pakistan Chambers of Commerce and Industry”

[7] Pesaran et al, (2001)

OBJECTIVES OF THE STUDY

This research has been conducted for identifying different channels of foreign technology transformation and their impact on economic growth of Pakistan through long run and short run empirical investigation. Moreover, we aim to give policy suggestions for the promotion of Technology Transformation and effective use of this technology by developing absorption capacities of Pakistan.

LITERATURE REVIEW

Caves (1974) discovered that there might be two different impacts of foreign knowledge spillovers that had competitive effect and technology diffusion effect. The result of this study confirmed that in industry where the proportion of output produced by foreign owned firms was higher, the domestic owned firms had higher value added per worker. This finding supported the view that firms had taken benefit of foreign knowledge or technology and it had increased the efficiency of domestic owned firms. Barro (1991) examined the relationship between exports and economic growth by using the data of Middle East and African countries. The simple ordinary least square regression was used. The results showed that there was positive and significant correlation between exports and economic growth. The major shortcoming of this study was that this had not shown the direction of relationship that is, either relation was from export to growth or from growth to exports. Eaton and Kortum (1996) had shown that international licensing agreements as a direct way to transfer foreign technology but according to world investment report 2000, technology transfer through this source was not important because it did not contain modern technology.

Edwards (1998) checked the relationship between trade liberalization and total factor productivity (TFP) by using indexes of openness. He used the data of 93 developed and developing countries and estimated 18 growth equations by using random effect model. From these estimates he computed TFP and then regressed TFP on income, initial labor and openness indicators. The results indicated that all the coefficient of openness had expected signs and in most of cases it is significant. The coefficient on initial labor force was significant and positive while of initial income it was negative. He concluded that trade openness had positive effect on economic growth. Xu and Wang (2000) examined the impact of Trade and Foreign direct investment as channels for technology transmission from industrialized countries to less developed countries. They also checked impact of this technology on TFP of these countries. The sample of 21 OECD[1] countries for the period from 1971 to 1990 was used. Three channels, capital goods trade, inward FDI and out ward FDI were considered for technology transmission. Ordinary least squares with white’s hetero scedasticity consistent covariance estimation method were used to the Cobb-Douglas production function to estimate the required results. The results showed that the technology which comes through the imports of capital goods had a sizeable positive effect on a country’s total factor productivity. That was strong empirical support for the trade as channel of foreign technology diffusion. To examine the role of FDI a sample of 13 OECD countries for the period of 1983 to 90 was used. The results showed the outward FDI brings technology back to the home country through the multinational enterprises. There were some short comings in this study. For example Cobb-Douglas production function does not take into account the endogeneity problem in the variable. There was need to develop theoretical justification for methods used and also more attention should be paid to econometric issues. Chakraborty and Basu (2002) examined the causality from GDP to FDI in Indian economy by using co-integration and error-correction models. Results showed that causality run from GDP to FDI rather from FDI to GDP in the Indian economy.

Narayan and Smyth (2005) have examined the impact of trade liberalization on economic growth of Fiji by using Cobb Douglas production function with making little modification in order to take into account the impact of political instability and trade liberalization from 1986 to 2000. A recently developed Autoregressive Distributed Lag (ARDL) bounds testing approach was used to estimate the model. They used taxes on trade as a variable of openness and dummies for political instability. Long-run results were consistent to the theory and showed that there is a co integration relationship amongst the exogenous and dependent variable. But the coefficient of labor force was negative. Investment and human capital have positive signs and statistically significant at 10% of level of significance. The dummy variable which was used to capture the impact of political instability of Fiji had negative sign and significant at 1%. This is consistent with the view that political instability has bad impact on economic activities in the country. The exports variable in the long-run have positive sign but insignificant and in the short-run the results are ambiguous. Also the results of tax on trade which measure the degree of trade openness are not clear cut. The weak relationship of exports and investment with GDP is alarming for Fiji. It is necessary for Fiji to raise investment to about 20 to 25% in order to achieve 5% target of GDP growth rate. Driffield and Henry (2007) examined the importance of absorptive capacity and institutional quality of host country for making the foreign technology more effective for the economic growth of host country. The absorptive capacity of foreign technology is measured by the level of human capital which is the average level of schooling for the population of 25 years and above. Institutional quality is measured by two ways. First was measured by index of legal structure and property rights and secondly it was measured through quality of bureaucracy. The threshold regression analysis has been used to get the results for the group of 57 developing countries over the period from 1970 to 1998. The results of this study showed that in the case of trade as a channel of foreign technology the institutional quality is more effective for growth effects, while in the case of FDI a channel of foreign technology, the human capital is found to be more effective for economic growth. This means that in the case of FDI, absorptive capacity of host country matters.

Cuaresma and Scharler (2008) investigated the importance of absorptive capacity of foreign technology in effecting the productivity of the host county. A sample of 21 Organisation for Economic Co-operation and Development (OECD) countries were used from 1973 to 1997. There were assumption that there are two major channels of foreign technology that is, imports of intermediate and capital goods and FDI. Proxies of market regulation and wage bargaining were used to measure the absorption barriers. Foreign R&D stokes were constructed by their import share weighted averages of the country’s own R&D stock. The overall results showed that the foreign R&D have positive impact on the economic growth of the countries which have lower levels of market regulation, employment protection and lower barriers to the entrepreneurship. Krammer (2008) examined the impact of international spillovers via trade and FDI on economic growth of 27 transition and 20 western European countries over the period from 1990 to 2006 by using latest technique of panel unit root and co integration test. There were two channels of foreign R&D stocks (i) Foreign R&D stocks embodied in imports (ii) foreign R&D stocks embodied in FDI. Domestic R&D capital stocks and human capital were used as control variable. Domestic R&D capital stock is based on the gross expenditure on R&D and for human capital, the proxy of average years of secondary schooling in male population over 25 year old was used. Human capital measured the absorption capacity of host country. The finding of this study showed that both trade and FDI remains the main carrier of foreign technology both trade and FDI have significant impact on TFP but FDI have smaller impact as compare to trade in the case of both developed and developing countries. The human capital and domestic R&D stocks which were used as absorption capacity and control variable play a crucial role in TFP of these countries. On the basis of these results it can be concluded that openness to both trade and FDI is very crucial and beneficial for developing economies but to use this foreign technology more efficiently there is need of skilled educated labor force and domestic R&D stocks in order to absorb foreign technology.

Chandran and Munusamy (2009) investigated the long run impact of openness on growth of manufacturing sector of Malaysia by using the annual data from 1970 to 2003. The source of data is Malaysia Economic statistics- time series, published by the development of statistics, Malaysia. The data includes the value added output of manufacturing sector, net fixed capital, number of labor and Trade openness. To include the impact of Asian financial crisis 1997 to 1998, the dummy variable was used. To estimate the result the co-integration test was performed using the Autoregressive Distributive Lag (ARDL) method. To check the long run relationship the bond testing approach was used. The results showed that there exist long run relationship among the manufacturing value added output and all the independent variables. But short run results revealed that in the short run openness have no effect on the growth of manufacturing sector of Malaysia. The conclusion of this study showed that any country can only benefit form Economic openness if it uses openness as source of growth on long term basis. In the case of discontinuity in trade policy or opening up of economy for only short time could not encourage the Economic growth of any country. Guessan and Yue (2010) investigated the long-run impact of trade liberalization and foreign direct investment on the Economic growth of Cote dIvoire by using the time series data from 1980 to 2007. The variables which were used are output defined by per capita real GDP of Cote dIvoire, Foreign direct investment which is also in real form, openness was measured by the total sum of total export and total import as the ratio of GDP, labor measured by total labor force and for capital the proxy of real value of gross fixed capital formation was used. Data of all the variables were taken from world development indicator (WDI, 2008).

Aggregate production function was used in order to check the relationship and this function was estimated by using bounds testing co integration procedure which is ARDL[4] bounds testing approach to investigate the long-run as well as short-run impact of all exogenous variables on the Economic growth of Cote dIvoire. Before estimating the model the stationary status was checked by using the unit root test and result showed that all the variables were stationary at first difference. ARDL results showed that there is long-run relationship among the explanatory and dependent variables.

The results of Causality test showed the unidirectional causal relationship exists which is from independent variables to Economic growth. In this case FDI and trade openness have significant and positive impact on Economic growth of Cote dIvoire.

This brings the policy recommendation for Cote dIvoire that the policy makers should formulate Economic policy in such a way to attract more foreign direct investment along with reducing the trade restrictions in order to achieve higher Economic growth. Brain drain means emigration of a proportion of the population which is comparatively highly educated as relative to average population. Haque and Kim (1995) concluded in their study that emigration causes brain drain which reduces the Economic growth.

Zhu Yiying (2010) tried to investigate how China has become the most attractive place for FDI and how this FDI effect the economy of China by bringing the foreign Technology into China. The author used the theoretical frame work to explain his point of view. As a result of reforms and opening up policy of China, a record FDI have come to China during the last three decades. FDI not only brings Technology to China but also there is establishment of R&D centers by MNCs which help to localize their products to create competitive environment in Chinas markets. This market competition brings developing momentum in the host economy. Foreign companies provide advices and professional assistance to the local suppliers which help to accelerate the growth of local enterprises and healthy competition. In this way, FDI acts as source of positive Technology diffusion to host country. Boermans (2010) analyzed that exporting firms are more productive than non-Exporting because of “learning Exporting” by using firm level data of Africa from 1991 to 2003 collected by the survey of World Bank (RPED)[5].

The results showed that African exporting firms are more productive and significantly learning by Exporting as compared to the non-exporting firms. The exporting firms are more active and competitive internationally as compared to domestic firms. Therefore, Government should formulate such policies which help to make domestic firms more active internationally through export promotion programs.

[1] “Organization for Economic Co-operation and Development”

[2] World Trade Organization

[3] Augmented Dicky-Fuller

[4] Autoregressive Distributed Lag

[5] “Regional Program on Enterprise Development”

EMPIRICAL ANALYSIS

Model specification and data sources

Many theorists are of the view that technology is key determinant of sustainable economic growth. Creation of new products which expands the knowledge and new ideas is also vital for growth. Alternatively consumers prefer more of the new products and may be willing to pay more for products which are consistent with latest fashion. As the new products come through new ideas, new knowledge, so the international trade can acts as source to transfer these new ideas or knowledge internationally. In Pakistan many studies was done on trade openness and economic growth but no one has investigated the effect of foreign technology on growth which comes from imports of goods. There are many factors which are critical about the effectiveness of foreign technology for the Economic growth of host country. If the traded goods are more R&D intensive then this type of trade will have significant positive impact on economic growth of importing country[1]. As the goods produced by developed country is R&D intensive so opening up of trade by developing country like Pakistan with developed country like Japan or USA will have significant positive impact on economic growth of Pakistan. This impact will also depend on the human capital of developing country. Although the opening up of trade is critical for developing countries but alone trade openness is not enough for Economic growth. The effectiveness of imported technology also depends on the absorptive capability and ability to adopt foreign technology, which further depend on the local circum-stances of host country[2]. Absorption of foreign technology is also affected by the distance of host country from the global frontier (Keller 2002). Hejaji and Safarian (1999) summarized theoretical argument for inward FDI and trade as channels for Technology diffusion. FDI is channel to bring the foreign capital, management expertise and production Technology[3]. Howitt (2000) and Mayer Foulkes and Howitt (2000) are of the view that flow of ideas, new method of production and management skill through the movement of peoples across the countries benefit the production growth of especially developing economies. The emigration of people of Pakistan is used as proxy to capture impact of this flow of ideas. Most of the researchers including Ahmed and Anoruo (1999-2000), Edward (1998), Edward (1992), Harrison (1996), Isean (1998), Santos (2002) and Wacziarg (2001) have used total exports and imports as independent variable in their growth models. Many studies like Coe and Helpman, (1995), Keller (2000). Xu and Wang (1999), Mayer (2001), have concluded that import of capital goods is a major channel of foreign technology and source of productivity for developing economies. Some economists like Clerides, Lach and Tybout (1997) are of the views that exporting to industrialized counties is a source of learning or acts as learning by exporting. Chuang (2000), Greenaway and Sapsford (1994) and Dollar (1992) have found that Exports have positive impact on growth.

There is a lot of empirical work done on the issue to examine the impact of liberalization on economic growth of Pakistan but no one examined the relative importance of several channels of transformation of Technology from developed countries to Pakistan as a result of liberalization of economy. So there is need to empirically examine importance of Technology transmission for the Economic growth of Pakistan. Pakistan is also one of those countries which allocate very minor amount on R & D and faces scarcity of Technology, so foreign sources of technology are very important for Pakistan. Main focus of this chapter is to empirically examine the significance of transmission of technology as result of liberalizing economy for economic growth of Pakistan. On the bases of literature and economic theories, the following model will be employed. As shown in Table 2.

[1] Coe and Helpman (2004)

[2] Evenson and Westphal (1995)

[3] (Johnson, 1972), Blomstrom and Kokko (1997), Aitken and Harrison (1999), Borensztein, De Gregorio and Lee (1998) and Blomstrom and Sjoholm (1999)

ln(Y)t = f[ln(K)t, ln(L)t, ln(TEXP)t, (MTEC)t, (FDI)t, ln(EMG)t]

or

ln(Y)t = β0 + β1 ln(K)t+ β2ln(L)t+ β3 (MTEC)t+ β4 (FDI)t5 ln(TEXP)t6ln(EMG)tt

MTEC[1] is technology goods import intensity defined as imports of Technology goods divided by total import[2]. FDI is the foreign direct investment to GDP ratio is used as other channel of Technology diffusion supported by lot of literature. Data of both the variables MTEC and FDI is taken from Economic Survey of Pakistan. The variables ln(TEXP)t and ln(EMG)t are the natural logarithm of total export and total number of emigrants annually respectively. Both are important indicators of economic liberalization and source of Technology transmission. Data of total exports in million Rupees is taken form Economic Survey of Pakistan and total number of Emigrants annually taken from Bureau of Emigrants and Overseas. Gross Capital formation and employed labor force both are important factor of production which is consistent with the models of Solow (1956), Swan (1956) and Romer (1986 and 1990). Both are used after taking the natural logarithm (lnK, lnL). Data of Gross capital formation (current US$) and Gross domestic products (GDP US$) is taken from world Development Indicator (WDI) and employed labor force taken from International Labor organization (ILO). And at the last μt is random error term. The natural logarithm is taken to convert the different variable with different units into percentage. MTEC and FDI are already in percentage so these both variables are used without taking natural logarithm. During the year 1971 to 72 a major change occurred caused by the separation of East wing of Pakistan that’s why the data from 1972 to 2009 have been used for estimation purposes.

[1]For detail see Andreas and Marios (2003)

[2] Helpman and Grossman (1991), Wilson and Caselli (2003), and Eaton and Kortum (2001)

EMPIRICAL FINDINGS AND RESULT DISCUSSION

Augmented Dickey Fuller (ADF) is applied to check the stationary status and the results are given in Table 3. The results of ADF test indicate that every variable either is stationary at level or at first difference. MTEC and ln (EMG) variables both are stationary at level because on the basis of t-statistics the null hypothesis of non-Stationarity is rejected at level. Remaining all variable are stationary at first difference because on the basis of t-statistics the null hypothesis of non-Stationarity is rejected at first difference. It is confirmed that no variable has order of integration two or I (2). So it fulfills the assumption of bounds test that no variable is having I (2). The optimal lag length is one selected by using Schwarz Bayesian and Hannan-Quinn information criterion. The value of F statistics is 3.66 reported in table 4 below. As the calculated F statistics is greater than upper bound at 10% and 5% level of significant, so the null hypothesis of no cointegration is rejected. This Bounds Testing results confirm that there is co integration relationship between dependent and independent variables of the model. Table 5 shows that import of technology goods (MTEC), exports, employed labor force and gross capital formation have positive and statistically significant impact on GDP in the long run.

The coefficient of export reveals that one percent increase in total exports leads to 0.17% increase in GDP growth in the long-run. The positive association between exports and economic growth confirm the export lead growth hypothesis for Pakistan. Export is the important contributor to the economic growth. There are number of benefit of export expansion, like it increases efficiency and improves quality of domestic production. The positive relation between exports and growth is because of the exports sector have positive externalities for non-exporting sector of the country. Expansion production of exportable products can lead to production growth by adoption and transmission of modern method of production. Most of evidences are in the favor that when any country starts exporting, the firms of that country get benefit from interacting with customers from all over the world. These customer demand higher quality products and in this way impose condition to produce higher standard products as compared to domestic customer demand. The coefficient of MTEC reveals that one percent increase in the technology goods import intensity (MTEC) leads to 0.008% increase in GDP growth in the long run. Imports of technological goods (capital, machinery and parts of machinery) have positive and statistically significant impact on economic growth of Pakistan which indicates that to achieve development and to boost economic growth, it is crucial for Pakistan to import technology goods (capital, machinery and parts of machinery) and input material so that the productive capacity can be expanded. The result also confirms that excessive imports of finished goods (luxury goods) have negative relation with economic growth. This is because the excessive imports of finished (luxury goods) replace the domestic output and thereby the process of value addition in the country. The results are in contrast of the finding of Akbar and Naqvi (2000) who concluded that the imports do not have any role in economic growth of Pakistan but the results of this research show that the imports of technological goods (capital, machinery and parts of machinery) are very crucial for economic growth of Pakistan. The results of this research have also provided the clear cut answer to the study done by Husain (2005), his study could not give the clear cut answer to the question of whether the trade liberalization positively affects the economic growth or negatively.

The two important growth factors (labor and capital) are the most significant and have positive relation with growth which is consistent with the models of Solow (1956), Swan (1956), Kaldor (1961) and Romer (1986 and 1990). The coefficient of employed labor (lnL) shows that one percent increase in employed labor leads to 0.64% increase in GDP growth and co efficient of gross capital formation (lnK) shows that one percent increase in gross capital formation leads to 0.17% increase in GDP growth in the long run. The impact of emigration is not significant although the sign of coefficient of emigration is positive. On the other hand FDI has significant but negative effect on GDP. The coefficient of FDI shows that one percent increase in FDI leads to 0.06% decrease in GDP growth in the long run. The negative relationship between foreign direct investment economic growths indicates the lack of high skilled labor force and basic infrastructure to absorb the technology which comes through foreign direct investment. This lack of capabilities and inefficiencies in technological learning prevent spillover impact of MNC’s on economic growth of Pakistan. FDI brings capital intensive techniques in developing economies which are labor abundant and developing countries required time for shifting form labor intensive to capital intensive techniques that is why FDI is not effective in most of developing countries like Pakistan. The results of error correction model in Table 5 give information about the short-run speed of adjustment to-wards long-run equili-brium which is 27% per year. This further confirms the short-run movement of the model to-wards long-run equilibrium. As shown in Table 6.

SENSITIVITY ANALYSIS

At the end, the reliability and goodness of fit of the ARDL model is necessary condition before recommending and forecasting any policy on the basis of results obtained. So stability and diagnostic tests are performed. To examine the serial correlation the Lagrange Multiplier (LM) test are used. Heteroscedasticity are checked using test based on the regression of squared residuals on squared fitted values and for normality, the test based on skewness and Kurtosis of residuals are used. On the basis of ?2 Statistics or F-Statistics as given in Table 7 we fail to reject the mull hypothesis of

A. No serial correlation

B. No Heteroscedasticity

C. Normality of data.

At the end for examining of stability of coefficients Cumulative Sum of Recursive Residuals (CUSUM) and Cumulative Sum of Squares of Recursive Residuals (CUSUM square) are used as can be seen from Figure 1 and 2 that the fitted line is within 5% critical bounds so the Null Hypothesis of coefficient cannot be rejected. It means that model is stable.

CONCLUSION AND POLICY RECOMMENDATIONS

On the basis of all the discussion on economic liberalization and estimated results of the model, it can be concluded that openness to both trade and FDI is very crucial and beneficial for Pakistan but to use foreign technology more efficiently, there is need of skilled educated labor force and domestic R&D stocks in order to absorb this technology. To promote the economic growth of Pakistan, there is need to diversify the export base and import duties should be removed from the import of technology goods (capital, machinery and parts of machinery) and input material and at the same time the imports of unnecessary and luxuries should be reduced through heavy import taxes. There are new opportunities that have been opened in Asia and Middle Eastern countries for Pakistan, there is need to boost economic growth by exporting to these markets and by importing the capital goods from these economies at low transportation cost. Pakistan leadership must take steps to resolve the energy crisis and improve the law and order situation in order to achieve the macro-economic stability which is vital in boosting economic growth and restoring foreign investor’s confidence. Structural reforms that can improve investment climate and competitiveness are necessary to make both foreign direct investment and domestic investment more effective.

There is need of structural transformation through increasing the mobility of capital and labor across sectors and changing their production process in order to enable our firms and entrepreneurs to become globally competitive by diversifying their products. Government can also set up different programs like export investment support fund to transfer public investment to the selected sectors of exportable goods. Acquiring and up gradation of modern technology is necessary for Pakistan in order to move away from low value and traditional export products. This can only be achieved by providing incentives to facilitate technology adoption, acquisition and replacement. Government should formulate and implement such policies which can enhance the adaptive and absorptive capacities of economy for maximization of technology dissemination. Creation of skilled labor force not only for MNCs, but also for local firms is crucial in order to promote competitive domestic enterprises. Education policies should be changed as the demand for labor force change from industry. Along with the policies to enhance the absorptive and adoptive capacities of the economy, Government needs to target specific technologies related to the development areas. By providing fiscal or finance incentives, Government can attract these specific technologies into Pakistan. Establishment of Universities, Science and technology parks and other research institutions can generate environment for R & D innovation and THIS can help to attract high technology investors relevant to priority areas of development strategies. The impact of foreign research and development capital stock and domestic R&D capital stock on economic growth of Pakistan should be incorporated in the suggested model. Due to the unavailability of data, these variables have been left in this model. But future study should take into account these variables; because these are significant factors for the evaluation of impact of foreign technology and knowledge on economic growth of Pakistan.

CONFLICT OF INTERESTS

The authors have not declared any conflict of interests.

REFERENCES


text:
# An Example of OUnit

The following example shows you how to create an OUnit test suite. There are some things in the example that might at first seem mysterious; they are discussed in the next section.

Create a file named sum.ml, and put the following code into it:

let rec sum = function
| []    -> 0
| x::xs -> x + sum xs

Now create a second file named sum_test.ml, and put this code into it:

open OUnit2
open Sum

let tests = "test suite for sum" >::: [
"empty"  >:: (fun _ -> assert_equal 0 (sum []));
"one"    >:: (fun _ -> assert_equal 1 (sum [1]));
"onetwo" >:: (fun _ -> assert_equal 3 (sum [1; 2]));
]

let _ = run_test_tt_main tests

(Depending on what editor you are using, you might now see some errors about OUnit2 and Sum. Ignore those for the moment: your code is correct, but your editor doesn't understand it yet. We'll fix that later by creating a .merlin file.)

Finally, run these commands:

$ocamlbuild -pkgs oUnit sum_test.byte$ ./sum_test.byte

You will get a response something like this:

...
Ran: 3 tests in: 0.12 seconds.
OK

Now suppose we modify sum.ml to introduce a bug by changing the code in it to the following:

let rec sum = function
| []    -> 1  (* bug *)
| x::xs -> x + sum xs

If rebuild and re-execute sum_test.byte, all test cases now fail. The output tells us the names of the failing cases. Here's the beginning of the output, in which we've replaced some strings that will be dependent on your own local computer with ...:

FFF
==============================================================================
Error: test suite for sum:2:onetwo.

File ".../_build/oUnit-test suite for sum-...#01.log", line 8, characters 1-1:
Error: test suite for sum:2:onetwo (in the log).

Called from unknown location

not equal
------------------------------------------------------------------------------

The first line of that output

FFF

tells us that OUnit ran three test cases and all three failed.

The next interesting line

Error: test suite for sum:2:onetwo.

tells us that in the test suite named test suite for sum the test case at index 2 named onetwo failed. The rest of the output for that test case is not particularly interesting; let's ignore it for now.

format: plain


text:
<meta http-equiv="refresh" content="1; url=/nojavascript/">

Difficulty Level: At Grade Created by: CK-12

Look at the table below. s\begin{align*}s\end{align*} stands for a number. Can you follow the rule and complete the table? In this concept, we will practice using rules to complete tables.

Guidance

In order to complete function tables like the one above, we can use the problem solving steps to help.

• First, describe what you see in the table.
• Second, identify what your job is. In these problems, your job will be to complete the table.
• Third, make a plan. In these problems, your plan should be to use the rules to help you to complete the table.
• Fourth, solve. In these problems you will solve by completing the table.
• Fifth, check. In these problems you will check by making sure that the numbers in the table work with the rule.

Example A

Use the rule to complete the table.

Solution:

We can use problem solving steps to help.

\begin{align*}r\end{align*} \begin{align*}v = r - 2\end{align*}
7 5
3 1
9 7
10 8
15 13
36 34
20 18
29 27
54 52

Example B

Use the rule to complete the table.

Solution:

We can use problem solving steps to help.

\begin{align*}q\end{align*} \begin{align*}w=q+20\end{align*}
5 25
8 28
6 26
4 24
19 39
53 73
20 40
48 68
69 89

Example C

Use the rule to complete the table.

Solution:

We can use problem solving steps to help.

\begin{align*}b\end{align*} \begin{align*}a=b-100\end{align*}
538 438
810 710
662 562
626 526
149 49
479 379
905 805
700 600
568 468

Concept Problem Revisited

We can use problem solving steps to help.

Vocabulary

A function is an example of a rule that states a relationship between two quantities. A variable is a letter that represents a number that can change value. In this concept, our rule told us how the two variables in the table were related.

Guided Practice

Use the rules to complete the tables.

1.

2.

3.

4.

1. Here is the completed table:

\begin{align*}m\end{align*} \begin{align*}p=m-200\end{align*}
741 541
800 600
306 106
449 249
530 330
361 161
427 227
936 736
958 758

2. Here is the completed table:

\begin{align*}a\end{align*} \begin{align*}q = 3 \times a\end{align*}
2 6
5 15
9 27
4 12
3 9
10 30
1 3
8 24
7 21

3. Here is the completed table:

\begin{align*}d\end{align*} \begin{align*}r=d \div 2\end{align*}
8 4
12 6
10 5
4 2
18 9
2 1
20 10
16 8
14 7

4. Here is the completed table:

\begin{align*}z\end{align*} \begin{align*}m=5 \times z\end{align*}
3 15
7 35
8 40
2 10
9 45
4 20
1 5
5 25
6 30

Explore More

Use the rules to complete the tables.

Date Created:

Jan 18, 2013

Dec 29, 2014
You can only attach files to Modality which belong to you
If you would like to associate files with this Modality, please make a copy first.


text:
# Solved papers for 10th Class Mathematics Solved Paper - Mathematics 2017 Delhi Set-III

### done Solved Paper - Mathematics 2017 Delhi Set-III

 In the figure, AB and CD are common tangents to two circles of unequal radii. Prove that AB = CD.

• question_answer2) If the ${{p}^{th}}$ term of an A. P. is q and ${{q}^{th}}$ term is p, prove that its ${{n}^{th}}$ term is $(p+q-n)$.

• question_answer3) A solid metallic sphere of diameter $16\text{ }cm$ is melted and recasted into smaller solid cones, each of radius $4\text{ }cm$ and height$8\text{ }cm$. Find the number of cones so formed.

• question_answer4) The angle of elevation of the top of a hill at the foot of a tower is $60{}^\circ$ and the angle of elevation of the top of the tower from the foot of the hill is $30{}^\circ$. If height of the tower is 50 m, find the height of the hill.

• question_answer5) If the ${{p}^{th}}$ term of an A.P. is $\frac{1}{q}$ and ${{q}^{th}}$ term is $\frac{1}{p}$, prove that the sum of first $pq$ terms if the A.P. is $\left( \frac{pq+1}{2} \right)$.

• question_answer6) An observer finds the angle of elevation of the top of the tower from a certain point on the ground as $30{}^\circ$. If the observer moves $20\text{ }m$ towards the base of the tower, the angle of elevation of the top increases by $15{}^\circ$, find the height of the tower.

#### Study Package

##### 15 10

LIMITED OFFER HURRY UP! OFFER AVAILABLE ON ALL MATERIAL TILL TODAY ONLY!

You need to login to perform this action.
You will be redirected in 3 sec


text:
# 11.3 Bohr’s theory of the hydrogen atom  (Page 2/7)

 Page 2 / 7

## Bohr’s solution for hydrogen

Bohr was able to derive the formula for the hydrogen spectrum using basic physics, the planetary model of the atom, and some very important new proposals. His first proposal is that only certain orbits are allowed: we say that the orbits of electrons in atoms are quantized . Each orbit has a different energy, and electrons can move to a higher orbit by absorbing energy and drop to a lower orbit by emitting energy. If the orbits are quantized, the amount of energy absorbed or emitted is also quantized, producing discrete spectra. Photon absorption and emission are among the primary methods of transferring energy into and out of atoms. The energies of the photons are quantized, and their energy is explained as being equal to the change in energy of the electron when it moves from one orbit to another. In equation form, this is

$\Delta E=\text{hf}={E}_{i}-{E}_{f}.$

Here, $\Delta E$ is the change in energy between the initial and final orbits, and $\text{hf}$ is the energy of the absorbed or emitted photon. It is quite logical (that is, expected from our everyday experience) that energy is involved in changing orbits. A blast of energy is required for the space shuttle, for example, to climb to a higher orbit. What is not expected is that atomic orbits should be quantized. This is not observed for satellites or planets, which can have any orbit given the proper energy. (See [link] .)

[link] shows an energy-level diagram    , a convenient way to display energy states. In the present discussion, we take these to be the allowed energy levels of the electron. Energy is plotted vertically with the lowest or ground state at the bottom and with excited states above. Given the energies of the lines in an atomic spectrum, it is possible (although sometimes very difficult) to determine the energy levels of an atom. Energy-level diagrams are used for many systems, including molecules and nuclei. A theory of the atom or any other system must predict its energies based on the physics of the system.

Bohr was clever enough to find a way to calculate the electron orbital energies in hydrogen. This was an important first step that has been improved upon, but it does correctly describe many characteristics of hydrogen. Bohr proposed that only very specific circular orbits were allowed. The radius of these orbits is calculated to be
${r}_{\mathrm{n}}=\frac{{n}^{2}}{Z}{a}_{\mathrm{B}}$
where
$n=1,2,3,\dots ,$
$Z$ is the atomic number of the element, and
${a}_{\mathrm{B}}=0.529×{10}^{-10}\phantom{\rule{.1667em}{0ex}}\mathrm{m},$
is known as the Bohr radius. The value of $n$ largely determines the energy level of the atom and is called the principal quantum number . This equation can be used to calculate the radii of the allowed (quantized) electron orbits in any hydrogen-like atom . It is impressive that the formula gives the correct size of hydrogen, which is measured experimentally to be very close to the Bohr radius. This equation also tells us that the orbital radius is proportional to ${n}^{2}$ , as illustrated in [link] .

where we get a research paper on Nano chemistry....?
what are the products of Nano chemistry?
There are lots of products of nano chemistry... Like nano coatings.....carbon fiber.. And lots of others..
learn
Even nanotechnology is pretty much all about chemistry... Its the chemistry on quantum or atomic level
learn
da
no nanotechnology is also a part of physics and maths it requires angle formulas and some pressure regarding concepts
Bhagvanji
Preparation and Applications of Nanomaterial for Drug Delivery
revolt
da
Application of nanotechnology in medicine
what is variations in raman spectra for nanomaterials
I only see partial conversation and what's the question here!
what about nanotechnology for water purification
please someone correct me if I'm wrong but I think one can use nanoparticles, specially silver nanoparticles for water treatment.
Damian
yes that's correct
Professor
I think
Professor
Nasa has use it in the 60's, copper as water purification in the moon travel.
Alexandre
nanocopper obvius
Alexandre
what is the stm
is there industrial application of fullrenes. What is the method to prepare fullrene on large scale.?
Rafiq
industrial application...? mmm I think on the medical side as drug carrier, but you should go deeper on your research, I may be wrong
Damian
How we are making nano material?
what is a peer
What is meant by 'nano scale'?
What is STMs full form?
LITNING
scanning tunneling microscope
Sahil
how nano science is used for hydrophobicity
Santosh
Do u think that Graphene and Fullrene fiber can be used to make Air Plane body structure the lightest and strongest. Rafiq
Rafiq
what is differents between GO and RGO?
Mahi
what is simplest way to understand the applications of nano robots used to detect the cancer affected cell of human body.? How this robot is carried to required site of body cell.? what will be the carrier material and how can be detected that correct delivery of drug is done Rafiq
Rafiq
if virus is killing to make ARTIFICIAL DNA OF GRAPHENE FOR KILLED THE VIRUS .THIS IS OUR ASSUMPTION
Anam
analytical skills graphene is prepared to kill any type viruses .
Anam
Any one who tell me about Preparation and application of Nanomaterial for drug Delivery
Hafiz
what is Nano technology ?
write examples of Nano molecule?
Bob
The nanotechnology is as new science, to scale nanometric
brayan
nanotechnology is the study, desing, synthesis, manipulation and application of materials and functional systems through control of matter at nanoscale
Damian
Is there any normative that regulates the use of silver nanoparticles?
what king of growth are you checking .?
Renato
What fields keep nano created devices from performing or assimulating ? Magnetic fields ? Are do they assimilate ?
why we need to study biomolecules, molecular biology in nanotechnology?
?
Kyle
yes I'm doing my masters in nanotechnology, we are being studying all these domains as well..
why?
what school?
Kyle
biomolecules are e building blocks of every organics and inorganic materials.
Joe
how did you get the value of 2000N.What calculations are needed to arrive at it
Privacy Information Security Software Version 1.1a
Good
Got questions? Join the online conversation and get instant answers!


text:
1
JEE Main 2019 (Online) 12th January Evening Slot
+4
-1
A parallel plate capacitor with plates of area 1 m2 each, are at a separation of 0.1 m. If the electric field between the plates is 100 N/C, the magnitude of charge on each plate is :

(Take $$\varepsilon$$0 = 8.85 $$\times$$ 10$$-$$12 $${{{C^2}} \over {N - {m^2}}}$$)
A
9.85 $$\times$$ 10–10 C
B
8.85 $$\times$$ 10–10 C
C
6.85 $$\times$$ 10–10 C
D
7.85 × 10–10 C
2
JEE Main 2019 (Online) 12th January Evening Slot
+4
-1
In the circuit shown, find C if the effective capacitance of the whole circuit is to be 0.5 $$\mu$$F. All values in the circuit are in $$\mu$$F.

A
$${6 \over 5}\mu F$$
B
$${7 \over 11}\mu F$$
C
4$$\mu$$F
D
$${7 \over 10}\mu F$$
3
JEE Main 2019 (Online) 12th January Evening Slot
+4
-1
The charge on a capacitor plate in a circuit, as a function of time, is shown in the figure :

When is the value of current at t = 4 s ?
A
zero
B
1.5 $$\mu$$A
C
2 $$\mu$$A
D
3 $$\mu$$A
4
JEE Main 2019 (Online) 12th January Morning Slot
+4
-1
In the figure shown, after the switch 'S' is turned from position 'A' to position 'B', the energy dissipated in the circuit in terms of capacitance 'C' and total charge 'Q' is :

A
$${1 \over 8}{{{Q^2}} \over C}$$
B
$${5 \over 8}{{{Q^2}} \over C}$$
C
$${3 \over 4}{{{Q^2}} \over C}$$
D
$${3 \over 8}{{{Q^2}} \over C}$$
JEE Main Subjects
Physics
Mechanics
Electricity
Optics
Modern Physics
Chemistry
Physical Chemistry
Inorganic Chemistry
Organic Chemistry
Mathematics
Algebra
Trigonometry
Coordinate Geometry
Calculus
EXAM MAP
Joint Entrance Examination


text:
# Among the following elements, the one having the highest ionization energy is

$(A)\;[Ne] 3s^2p^1$
$(B)\;[Ne] 3s^2p^3$
$(C)\;[Ne] 3s^2p^2$
$(D)\;[Ar] 3d^{10}\;4s^2\;4p^3$

The element with $[Ne] 3s^2p^3$ is the one having the highest ionization energy, because IE increases in a period from left to right. Moreover this element has half-filled p-electrons
edited Mar 24


text:
## Molecular models of nematic elastomers  and various effects:

skip down to the abstracts on continuum theories

• E.M. Terentjev, M. Warner, R.B. Meyer and J. Yamamoto

• Electromechanical Fredericks Effects in Nematic Gels,

The solid nematic equivalent of the Fredericks transition is found to depend on a critical field rather than a critical voltage as in the classical case.  This arises because director anchoring is principally to the solid rubbery matrix of the nematic gel rather than to the sample surfaces.  Moreover, above the threshold field, we find a competition between quartic (soft) and conventional harmonic elasticity which dictates the director response.  By including a small degree of initial director misorientation, the calculated field variation of optical anisotropy agrees well with the conoscopy measurements of Chang et al  (Phys.Rev.E56, 595 (1997) of the electro-optical response of nematic gels.

• E.M. Terentjev and M. Warner,

• Piezoelectricity of chiral nematic elastomers,

A molecular model of freely jointed chains of chiral monomers is developed to describe the piezoelectric effect in chiral nematic elastomers. The model, an extension of the neo-classical theory of nematic polymer networks, takes into account a chiral biasing of molecular alignment under shear which leads to induced polarisation if the monomers contain a transverse dipole moment. The resulting theory is fully non-linear in elastic deformations, in the spirit of ordinary rubber elasticity. The expansion to the highest order in small strains gives the three linear piezoelectric coefficients predicted by phenomenological models.

• H. Finkelmann, I. Kundler, E.M. Terentjev and M. Warner,

• Critical Stripe-Domain Instability of Nematic Elastomers,

We present an experimental and theoretical investigation of the critical formation of stripe domains in monodomain nematic elastomers. Domains with alternating sense of director rotation are formed when the material is stretched perpendicular to the initial director alignment. A wide range of differing samples are shown to have a singular onset to director rotation at a threshold deformation and a second singular point at the end of the stripe domain region. All the data collapses onto a master plot revealing a universal behaviour. We analyse theoretically the threshold properties of the stripe phase. The analysis of free energy yields a first order transition into a fully-coarsened texture without any intermediate state of sinusoidal modulation.

• M. Warner and E.M. Terentjev,

• Nematic Elastomers - A New State of Matter? (big review)
Prog. Polym. Sci. v.21, pp.853-891 (1996).

• G.C. Verwey, M. Warner and E.M. Terentjev,

• Elastic Instability and Stripe Domains in Liquid Crystalline Elastomers,
J. Physique II v.6, p.1273 (1996).

We consider the elastic and orientational response of a uniform nematic elastomer subjected to an extension perpendicular to its director. By allowing a possibility of local shear in the material, we show that the effect of soft elasticity' leads to a new regime of director re-orientation, through a highly non-uniform stripe domain state (in contrast to earlier predictions and observations of a discontinuous uniform director jump). The molecular theory developed here gives predictions on two levels: of the general texture of the stripe state plus the interval of strains in which it occurs, and of topological properties of the director rotation that are very general and depend only on chain anisotropy of elastomer but not on details of the specific material. On the other hand, parameters like the threshold strain for the domain formation depend on the chemical composition and on the model used to describe its effect. We discuss and explain experimental observations of stripe domains both in the perpendicular geometry and when the stretching direction is at an oblique angle to the director, leading to asymmetric stripes and different topology.

• E.M. Terentjev, M. Warner and G.C. Verwey

• Non-uniform Deformations in Liquid Crystalline Elastomers,
J. Physique II v.6, p.1049 (1996).

The result of this work is the general expression for the free energy of deformations, which combines the effects of large non-symmetric affine strains in the rubbery network and gradients of curvature deformations of the director field, $F \sim \lambda^T \{ \nabla {\bf n} \}^2 \lambda$. We derive the molecular expressions for the elastic constants governing non-uniform directors in the presence of elastic strains. These constants depend on the polymer step length anisotropy and - most strikingly - have an overall negative sense. We therefore predict that in some circumstances, especially at large elastic deformations \lambda, these new terms may overpower the usual, positive Frank elastic moduli of the underlying nematic structure, as well as the coupling in nematic elastomers of uniform relative rotations of the director and the elastic matrix. In this event highly distorted polydomain textures n(r) would be favoured.

• P. Bladon, M. Warner and E.M. Terentjev,

• Orientational Order in Strained Nematic Networks,
Macromolecules v.27, 7067, 1994.

Monodomain nematic networks, formed by crosslinking polymer liquid crystals in ordered states, retain a memory of their anisotropic crosslinking conditions and thereby show novel elasticity and strain induced nematic transitions. Orientational transitions can result and these are investigated using a simple model of nematic elastomers that allows both the the direction and the magnitude of order to respond to applied strains. We find two temperature dependent regimes. At low temperatures where nematic effects are strong, the director rotates and switches with the nematic order largely intact. At higher temperatures near the thermodynamic phase transition elastic effects dominate and applied strain destroys the nematic order before it reforms in the new direction.

• Orientation of Liquid Crystal Elastomers and Gels by an Electric Field,
J. de Physique II v.4, 667, 1994.

Electric fields acting on anisotropic chains induce orientational torques, which compete with rubber elastic effects. Outcome structures crucially depend on the mechanical constraints applied to the sample. In set-ups with no or few constraints, an electric field rotates the nematic director without resistance, inducing also a spontaneous shape change of a rubber or gel matrix. When certain strains are prevented in the sample by external constraints, the magnitude of the elastic barrier is much higher than the electric contribution and a very high electric field is required to create an observable director rotation. In weakly anisotropic elastomers, for instance conventional rubbers which have been strained during crosslinking, the characteristic field will be considerably lower.

• Deformation-induced Orientational Transitions in Liquid Crystal Elastomers, J. de Physique II, v.4, 75, 1994.

Solid liquid crystals, formed by crosslinking polymeric nematics into elastomers are shown to display novel and complex elasticity. The internal (nematic) direction can experience a barrier to its rotation which couples to standard elasticity. We investigate this elasticity by considering imposed strains and demonstrate several new orientational phase transitions, caused by the interaction between applied stress fields and bulk barriers to rotation.

• M.Warner, E.M.Terentjev and P.Bladon, Soft Elasticity' -- Deformations without Resistance in Liquid Crystal Elastomers, J. de Physique II, v.4, 93, 1994.
• We predict a new phenomena unique to anisotropic rubber -- a `soft elastic response'; uniaxial strain is developed without resistance below a critical deformation $\lambda^*$ due to the relaxation of related shear strains and reorientation of the nematic director.

• P.Bladon, E.M.Terentjev and M.Warner, Transitions and Instabilities in Liquid Crystalline Elastomers, Phys. Rev. E, v.47, R3838, 1993.

## Continuum theory of nematic and smectic elastomers and more effects...

• E.M. Terentjev,

• THERMODYNAMIC ORDER AND RANDOM DISORDER IN LIQUID CRYSTAL ELASTOMERS,
Makromol. Symp. v.117, 79 (1997).
See the abstract on the page related to random disorder

• P.D. Olmsted and E.M. Terentjev, Mean Field Nematic-Smectic A Transition in a Random Polymer Network,

• Phys. Rev. E53, p.2444 (1996).
See the abstract on the page related to random disorder

• E.M. Terentjev, M. Warner and T.C. Lubensky,

• Fluctuations and Long- Range Order in Smectic Elastomers,
Europhys. Lett. 30, 343, 1995.

In a crosslinked polymer network, which has a lamellar or liquid crystalline smectic-A order, layer deformations are penalized by an underlying rubber elasticity. By integrating out phonon modes of the network, we obtain an effective smectic-A elastic free energy in which there is an energy cost for rotating smectic layers relative to the elastic network. As a result, there is long-range translational smectic order with true Bragg peaks in the X-ray scattering intensity with Debye-Waller factors depending on the crosslink density of the network. There is also a very anisotropic diffuse scattering.

• E.M.Terentjev and M.Warner,

• Continuum Theory of Elasticity and Piezoelectric Effects in Smectic A Elastomers,
J. de Physique II, v.4, 111, 1994.

The general continuum free energy is derived for a liquid crystalline (smectic) elastomer under small strain and orientational distortions. Using group representations theory we obtain all invariants describing the coupling of translational and orientational degrees of freedom. Possibilities of uniform rotation of the layer system under shear deformation are outlined. It is shown that in centrosymmetric materials (smectic A) the only polarizational response is flexoelectric, that is in the response to non-uniform orientational deformations. Chiral materials (rubbers of smectic A*) also have a uniform piezoelectric effect in response to a shear deformation, or an extension at an angle with the layer normal.

• E.M.Terentjev and M.Warner,

• Continuum Theory of Ferroelectric Smectic C* Elastomers,
J. de Physique II v.4, 849, 1994.

The continuum free energy is derived for a crosslinked network of smectic C and chiral smectic C* liquid crystal polymers under small strain and orientational distortions. The coupling between elastic strain, the smectic C order parameter and the polarization (induced or spontaneous in C* phase) is examined and several new orientational and polarizational effects are predicted. It is shown, on the other hand, that some effects in conventional smectic C liquid crystals, for example the bistability and switching in ferroelectric C*, no longer exist in corresponding elastomers.

• T.C.Lubensky, E.M.Terentjev and M. Warner, Layer-Network Coupling in Smectic Elastomers, J. de Physique II v.4, 1457, 1994.

•
• E.M.Terentjev, Phenomenological Theory of Non-uniform Nematic Elastomers: Free Energy of Deformations and Electric Field Effects, Europhys. Letters, v.23, 27, 1993.

• The general phenomenological free energy is derived for a liquid crystalline elastomer under arbitrary strain and orientational distortions. Using the group representations method I obtaine all invariants, describing the coupling of translational and orientational deformations and/or external electric field. It is shown that in centrosymmetric materials (nematic rubbers) the only contribution to the free energy which is linear in (small) gradients of the director, is the coupling with electric field and the strain tensor (16 independent terms analogous to the flexoelectric effect). In chiral materials (cholesterics) the electric field couples with the strain tensor for uniform nematic director (piezoelectric effect, 3 invariants) and, in the absence of an electric field, translational and linear orientational distortions interact with each other (couple-stress effects, 6 invariants).


text:
# How to calculate the heat transfer rate between the liquid and the gas?

Let water (liquid) be in a chamber (with no heat transfer to the walls). The gas is the residual space above the liquid, meaning that the contact surface is the surface of the water.

Given the gas and the liquid are at a certain pressure, but the temperature of the gas and the liquid differ. How can I find the heat transfer rate for this problem?

• In general, there is no easy answer to this, because the total heat transfer will be a complicated function of different effects like conduction, convection, radiation, evaporation etc.. Can you restrict the problem to a much more specialized case? – CuriousOne Sep 5 '14 at 8:17

The power of energy emitted by a body through radiation is given by Stefan–Boltzmann law:

$$P = eA\sigma T^4$$

where $e$ is the emissivity of the body, $A$ is the surface area of the body and $\sigma$ is the Stefan-Boltzmann's constant and $T$ is the temperature of the body.

Conduction:

For a conductor, the rate at which heat is transferred is calculated using the following formula:

$$\frac{dQ}{dt} = kA\frac{dT}{dx}=kA\frac{\Delta T}{\Delta x}$$

where $k$ is the thermal conductivity of the conductor, $A$ is the surface area through which heat is being transferred, $\Delta T$ is the temperature difference between the ends of the conductor and $\Delta x$ is the length of the conductor.

Convection:

The gas surrounding the liquid is not in equilibrium until it reaches a certain distance away from the surface of the liquid. It is quite difficult to quantitatively work with heat transfer through convection. The best approach to this problem is by treating the convective heat transfer to be a conductive heat transfer (or solve for conductive heat transfer and then adjust parameters to account for convection). The exchange of energy between the gas and the liquid can hence, be modeled as:

The region colored in blue is the liquid and the thick black line indicates the surface of the liquid. The region colored in yellow represents the gas which is at equilibrium. The orange region represents the gas which is not in equilibrium. In this region, we assume that the gas behaves as a thick conductor. The width of this region is called effective wall thickness and is denoted by $d$. The thin black line represents a line separating the orange region, where active conduction is taking place, and the yellow region where the gas has already reached the equilibrium temperature.

We can make adjustments to the heat transfer equation for conduction to account for convection. In cases where conduction is not negligible, we add a correction factor to the thickness of the conductor to account for the heat transferred through convection. In cases where conduction is negligible and heat transfer overwhelmingly happens through convection, we assume that there exists a hypothetical conductor separating the two surfaces; in our case, that is the orange region of air.

The value of $\Delta T$ is taken as the equilibrium temperature of the gas (yellow region) and temperature of the liquid (blue region). The value of $\Delta x$ is taken as the effective wall thickness $d$. The value of $A$ is taken as the total surface area of the liquid that is in contact with the air. The value of $k$ is taken as the thermal conductivity of air.

The value of effective wall thickness depends on several factors such as wind speed (turning on an air blower helps disperse the hot air near the surface of the liquid and hence, improves the conduction by reducing the effective wall thickness). This value is in most cases derived empirically or calculated through experiments.

The above explanation dealt with a general case. In your question, you have the gas enclosed in a container. As the hot air rises, the temperature at the top of the container will be the highest. You can take nearly the entire height of the gas as the effective wall thickness.

References:

Conduction and convection mechanism for the human body

You could either use:

$dS = \frac{dQ}{T}$

with $T dS = dQ$

First Law: $T dS = dE - dW$

so $dE = T dS + dW$

alternatively, you could use

$Q = mc \Delta \theta$

Where $\Delta \theta$ is the temperature difference between the gas and the liquid.

To use this in regard to both systems, the formula gets a bit more complex.

Firstly you have to compute the final temperature of the lower temperature substance using, lets say the gas is:

$Q = M_{g}c_{g}(T_{f} - T_{i}) = M_{l}c_{l}(T_{i} - T{f})$

so $T_{f} = \frac{M_{l}c_{l}T_{i} + M_{g}c_{g}T_{g}}{M_{g}c_{g} + M_{l}c_{l}}$

I.e the joint heat capacity of the liquid and gas would be:

$c_{lg} = \frac{c_{g} + c_{l}}{c_{l}c_{g}}$

Then you can again use $Q = mc \Delta \theta$

and iterate for an arbitrary addition of systems.


text:
# Divisibility

Determine the smallest integer which divided 11 gives remainder 4 when divided 15 gives remainder 10 and when divided by 19 gives remainder 16.

Correct result:

x =  1555

#### Solution:

x1: 4, 15, 26, 37, 48, 59, 70, 81, 92, 103, 114, 125, 136, 147, 158, 169, 180, 191, 202, 213, 224, 235, 246, 257, 268, 279, 290, 301, 312, 323, 334, 345, 356, 367, 378, 389, 400, 411, 422, 433, 444, 455, 466, 477, 488, 499, 510, 521, 532, 543, 554, 565, 576, 587, 598, 609, 620, 631, 642, 653, 664, 675, 686, 697, 708, 719, 730, 741, 752, 763, 774, 785, 796, 807, 818, 829, 840, 851, 862, 873, 884, 895, 906, 917, 928, 939, 950, 961, 972, 983, 994, 1005, 1016, 1027, 1038, 1049, 1060, 1071, 1082, 1093, 1104, 1115, 1126, 1137, 1148, 1159, 1170, 1181, 1192, 1203, 1214, 1225, 1236, 1247, 1258, 1269, 1280, 1291, 1302, 1313, 1324, 1335, 1346, 1357, 1368, 1379, 1390, 1401, 1412, 1423, 1434, 1445, 1456, 1467, 1478, 1489, 1500, 1511, 1522, 1533, 1544, 1555

x2: 10, 25, 40, 55, 70, 85, 100, 115, 130, 145, 160, 175, 190, 205, 220, 235, 250, 265, 280, 295, 310, 325, 340, 355, 370, 385, 400, 415, 430, 445, 460, 475, 490, 505, 520, 535, 550, 565, 580, 595, 610, 625, 640, 655, 670, 685, 700, 715, 730, 745, 760, 775, 790, 805, 820, 835, 850, 865, 880, 895, 910, 925, 940, 955, 970, 985, 1000, 1015, 1030, 1045, 1060, 1075, 1090, 1105, 1120, 1135, 1150, 1165, 1180, 1195, 1210, 1225, 1240, 1255, 1270, 1285, 1300, 1315, 1330, 1345, 1360, 1375, 1390, 1405, 1420, 1435, 1450, 1465, 1480, 1495, 1510, 1525, 1540, 1555

x3: 16, 35, 54, 73, 92, 111, 130, 149, 168, 187, 206, 225, 244, 263, 282, 301, 320, 339, 358, 377, 396, 415, 434, 453, 472, 491, 510, 529, 548, 567, 586, 605, 624, 643, 662, 681, 700, 719, 738, 757, 776, 795, 814, 833, 852, 871, 890, 909, 928, 947, 966, 985, 1004, 1023, 1042, 1061, 1080, 1099, 1118, 1137, 1156, 1175, 1194, 1213, 1232, 1251, 1270, 1289, 1308, 1327, 1346, 1365, 1384, 1403, 1422, 1441, 1460, 1479, 1498, 1517, 1536, 1555

$1555 \div 11 = 141 + \dfrac{ 4 }{ 11 } \ \\ 1555 \div 15 = 103 + \dfrac{ 10 }{ 15 } \ \\ 1555 \div 19 = 81 + \dfrac{ 16 }{ 19 } \ \\$

Our examples were largely sent or created by pupils and students themselves. Therefore, we would be pleased if you could send us any errors you found, spelling mistakes, or rephasing the example. Thank you!

Leave us a comment of this math problem and its solution (i.e. if it is still somewhat unclear...):

Be the first to comment!

Tips to related online calculators
Do you solve Diofant problems and looking for a calculator of Diofant integer equations?

## Next similar math problems:

• Digit sum
Determine for how many integers greater than 900 and less than 1,001 has digit sum digit of the digit sum number 1.
• Divisors
The sum of all divisors unknown odd number is 2112. Determine sum of all divisors of number which is twice of unknown numbers.
• Tissues
The store got three kinds of tissues - 132 children, 156 women and 204 men. Tissues each species were packed into boxes after the number of pieces the same for all three types (and greatest). Determine the number, if you know that every box has more than
• Numbers
Write smallest three-digit number, which in division 5 and 7 gives the rest 2.
• Red and white
Simona picked 63 tulips in the garden and tied bicolor bouquets for her girlfriends. The tulips were only red and white. She put as many tulips in each bouquet, three of which were always red. How much could Simon tear off white tulips? Write all the opti
• Remainder
A is an arbitrary integer that gives remainder 1 in the division with 6. B is an arbitrary integer that gives remainder 2 the division by. What makes remainder in division by 3 product of numbers A x B ?
• Three-digit integers
How many three-digit natural numbers exist that do not contain zero and are divisible by five?
• Divisible by 5
How many three-digit odd numbers divisible by 5, which are in place ten's number 3?
• Four-digit number
Find also a four-digit number, which quadrupled written backwards is the same number.
• Theorem prove
We want to prove the sentence: If the natural number n is divisible by six, then n is divisible by three. From what assumption we started?
• Ski tow
The ski club has 168 pupils and used lift with 60 seats, while students always follow the same sequence in filling seats. How many times while riding a ski lift skier sitting in the same seat as the first run?
• Divisors
Find all divisors of number 493. How many are them?
• Bundle of candies
In the store has 168 chocolates, caramel candies 224 and 196 hard candies. How many packages we can do and how many of candies will be in each package?


text:
# Best way to write an xml tag

I'm writing a document about an XML schema, and I will be talking a lot of times about that <tag1> or that other <tag2>. Since I'm only mentioning them and not printing a whole XML file, it doesn't feel like a job for listings.

I suppose using $<tag1>$ wouldn't fit well either. So... which would be the best way of writing isolated XML tags in a document?

-

The definition of a new command would be the easiest way to go.

\newcommand*{\xml}[1]{\texttt{<#1>}}

Use it in your document as \xml{tag}.

-

With listings you can do the following:

\lstMakeShortInline{|}

And then use it thus: |<tag1>| and it will be printed using the listings style, and syntax highlighting and so on. You could use a symbol other than | if you so wished.

-
\def\<#1>{$\langle\texttt{#1}\rangle$}


text:
# OBD2 4u

The finished build

## Project overview

Have you ever seen that poster of the grizzly bear with the salmon in its mouth, subcaptioned “Sometimes the journey of 1000 miles ends very, very badly”? Well [spoiler alert], this is one of those journeys. The OBD2 interface (ISO-9141-2) that I spent about 10 months hacking - relatively successfully - is no longer really used in newer cars. So if you want to skip this one, feel free. Otherwise, I’ll take you on my journey to hack the car. A few things I wanted to see happen from the outset:

An easy-to-read display of the accumulated fuel costs while driving. Like this:

The only thing that really matters

Typical gas mileage for our car & minivan, including a sense of at what speed you get the optimum bang for your buck -

And the answer is: 61 miles/hr for the car & 53 miles/hr for the van

Some real-time output telemetry from the car while we were driving

Give me the stats

And, of course, the check engine light (CEL or MIL) … and more to the point, my desire to figure out which code was causing it, & then douse it.

Here’s a video of this hack in action. As it always seems to be on my Camry, the code set was P0136, which is an oxygen sensor. I’ve been ignoring it for years. I’m sure that’s not good.

Here’s another video of the system booting up and me checking out the identity of the vehicle and what information I can see. My hands were freezing (it was -25C that day) & you gotta love the music that was playing on the radio-

For inspiration, there is some great information out there. In particular, I’d mention Bruce Lightner’s project: an AVR-based fuel consumption gauge. You can see it mentioned near the bottom of his homepage, among all the other great things referenced there. I’d also mention Trampas Stern’s very informative website. There are a few pieces of code - in particular the ISO timing protocols - that I used from his google code repository (which no longer looks to be available?). Both of these folks are awesome.

## S.T.E.M.

### Raw materials

A ‘98 Camry and ‘05 Sienna were what I had to work with. As I found out during this project, Toyota stayed close to the ISO-9141-2 specs on these vehicles, so I actually didn’t have a lot of problems “talking” to my cars once I actually understood the spec & the bugs were all flushed out (that took some time).

### The basics - MAF, MAP, etc…

The fuel efficiency of an internal combustion engine can be estimated by … wait for it … chemistry. Knowing how much air is flowing into the engine, and knowing the ratio of air to fuel burned in the engine allows fuel consumption to be estimated. Some typical ratios are:

Fuel ratios .. I used 14.7:1 in the code

MAP stands for “manifold absolute pressure” and MAF stands for “mass air flow” - your car’s engine control unit will report one of these two. My ‘98 Camry only reports MAF and my ‘05 Sienna only reports MAP - go figure. Here’s the math to go from MAF to MPG.

#### MPG given a MAF value

where MFF is mass fuel flow, AFR is air-fuel ratio and 2799 g/gallon is the density of gasoline. If given a MAP value, first convert it to MAF,

#### MPG given a MAP value

\begin{align*} \text{MAF} = \frac{\text{RPM/60} * \text{MAP[kPa]} }{\text{(IAT[K]/2)} } * \text{VE[%]} * \\ \text{displacement[L]} * \frac{\text{28.97[g/mol]} }{\text{8.3[J/molK]} } \tag{2} \label{MAP} \end{align*}

& then use Equation $\ref{MAF}$ above to get to MPG. Here is a little spreadsheet to get a feel for the numbers. In this example, most of the assumptions are relevant to highway cruising -

A bunch of math gets me to what I want. And I want my MPG

### Introduction to OBD2

OBD2 stands for “On Board Diagnostics” - it was introduced in 1996 & has gone through several iterations. It turns out, that the current protocol (based on the CAN bus protocol) was mandated for any automobile year ‘08 or later. Both of mine are earlier than ’08s, so they use the older protocol I needed to implement here. OK, that just means another project at some point.

#### OBD2 connector

Below is a picture of the OBD2 connector in my vehicles, the mating connector on my scanner, and the pinout of OBD2.

Connector & pinout

The mating plug on our minivan

In place and connected

#### OBD2 protocols, timing and handshaking

OBD2 has several flavors - the variant I used is ISO-9141-2 which works with the Toyota spec. Another flavor (J1939) works with many older GM cars.

The initial “handshaking” has a timing process that looks like the following:

1. Send 0x55 on K- & L- lines at 5 bits/sec (bps)
2. Switch communications to 10400 bps
3. Receive 0x08 0x08 at 10400 bps
4. Send 0xF7 at 10400 bps
5. Receive 0xCC at 10400 bps

Initial communication protocol

Here is the initialization code:

void ISO_init_comm(uint8_t show) {
lcd_clear();
lcd_goto_xy(1,1);
fprintf_P(&lcd_out, PSTR("INIT"));
// send 33, resp str should contain 55
connect_put[0]=0x33;
//  switch_lcd_wait();
iso_5baud_putc(connect_put[0]);
for (i =0; i<3; i++)
{temp = iso_getb(&connect_get[i],1, ISO_W1_MAX*2);}
connect_put[1] = ~connect_get[2];
temp = iso_putb(&connect_put[1],1, ISO_W4_MIN);
temp = iso_getb(&connect_get[3],1, ISO_W4_MAX*2);

if(show ==1) {
lcd_clear();
lcd_goto_xy(1,1);
fprintf_P(&lcd_out,PSTR("INIT"), connect_put[0]);
lcd_goto_xy(1,2);
fprintf_P(&lcd_out,PSTR("0x%x"), connect_put[0]);
lcd_goto_xy(1,3);
fprintf_P(&lcd_out,PSTR("%x..%x %x"), connect_get[0], connect_get[1], connect_get[2]);
lcd_goto_xy(1,4);
fprintf_P(&lcd_out,PSTR("%x..%x"), connect_put[1], connect_get[3]);
clean_exit_partial();
}
}

And here is a picture of how my software responds to the initialization

Oh Bee Dee, Oh Bee Dah, Life goes on, yeah!!! Got Hex 55, its alive

#### OBD2 PIDs (parameter IDs)

You can read about parameter IDs (PIDs) & diagnostic trouble codes (DTCs) in a number of places. Wikipedia has a list of many of the PIDs. The documentation is good, so I won’t regurgitate much of it here.

One interesting code to send, though, is

0x68 0x6A 0xF1 0x01 0x00 0xC4

This tells you which of the PID codes are actually readable on your particular vehicle. In the case of our Sienna, the response is:

So it was these four hex bytes:

0xBF 0x9F 0xA8 0x91

What the heck does that mean? Well, we asked the van to respond to the code for Mode 01, PID 01. That’s what the two bold hex numbers are in the command we sent:0x68 0x6A 0xF1 0x01 0x00 0xC4. The response we should expect, based on the Wikipedia page is 4 Bytes A B C D (or 32 bits). For us A = 0xBF, B = 0x9F, C= 0xA8 and D = 0x91. The meaning of those bytes [A7 … D0] = [$PID$01 … PID $20] tells us whether that particular PID is implemented. So I first converted those 4 bytes to binary 0b 1011 1111 1001 1111 1101 1000 1001 0001  and then I matched them up to the Wikipedia list. I had previously done the same for our car, and you can see them both lined up on this cheat sheet: Now I know what we’re working with In order to read the value of one of these PIDs that are available, you have to send the message in the format 0x68 0x6A 0xF1 0x[A] 0x[B] 0x[CSUM]  Where A = 01 for PID code set “mode 1” and B represents the actual code you want. CSUM represents a checksum, which is implemented like this: How to implement the CSUM checksum byte The car’s ECU will send a message back in the format 0x48 0x6B 0x[ADDR] 0x41 0x[A] {optional:0x[B] 0x[C] 0x[D]} 0x[CSUM]  where A, B, C, D, etc.. are data bits you can do something with. Here is a screenshot of a little utility I wrote in Excel/VBA called “PING” that I could use from a laptop connected to my scanner. This allowed me to “explore” all of these different PIDs .. basically a hacking tool. DIY hacking interface #### CEL codes If your check engine light (CEL) - also known as the malfunction indicator lamp (MIL) - is on, you can see how many codes are set: 0x68 0x6A 0xF1 0x01 0x01 0xC5  Currently, I’m good: OK, so for once I’m on the right side of things with old MILlie-CELlie In order to get CEL codes (also known as diagnostic trouble codes DTC), you need to send 0x68 0x6A 0xF1 0x03 0xC6  which gets you a response: 0x48 0x6B 0x[ADDR] 0x43 {repeated n times: 0x[A] 0x[B] 0x[C] 0x[D] 0x[E] 0x[F]} 0x[CSUM]  You can now interpret AB CD EF as diagnostic trouble codes. A typical response I get on my Camry is A = 01, B = 36, C = 0, D = 0, E = 0, F = 0 … yes I (like you) almost always get P0136, the oxygen sensor code. Didn’t even need to build this thing - its always that same stupid code. Maybe I’ll do something about it next time. I’ll bet you 50 bucks its the dreaded “oxygen sensor” code And of course, sending 0x68 0x6A 0xF1 0x04 0xC7  is magic, especially just prior to your annual safety check. So, really, this entire setup is a communications protocol with the car. Lets dive into the hardware prior to coming back to some of the things you can do with it in software. ## Hardware - circuit diagram Below is a circuit diagram of the entire setup. Circuit diagram for OBD2 project– ### LCD & buttons I used the Nokia 5110 LCD & driver plus a couple of pushbuttons to navigate around on the menu. Nothing really special there. More about the menu later. ### Serial interface I decided I might like to drive around and record what was happening on a laptop as I drove, among other things. So I put in a serial interface using a MAX232 chip. It requires a few capacitors and takes its input/output from the PD0/PD1 pins of the ATMega328. Also, in order to push up to 19200 baud and higher, you really have to start to pay attention to timing. There are some (really cool) software UARTs out there, but I didn’t use them on this project. On the PC side, I used Excel to collect the information and also to ping the car. You may cringe, but VBA was a simple solution. I’ll add more documentation to this over time. ### Circuit & package Here are a few close ups of the circuit, front and back sides. Front and back of circuit board Not really much of a package to speak of. I just mounted the circuit board with a couple of standoffs to a piece of wood. I also put a bunch of shoe-goo around the connector once I had it completed - that stuff is solid. Keeping the OBD2 connector connected ### L-line and K-line The L-line is only needed for 1-direction (reader-to-car only), but the K-Line is a bidirectional line. I used separate ICs - the L9637 - for both of these lines. It is a line driver with a bunch of protection circuitry built in. All you need on the output lines is a 5K pullup to the battery voltage of 12V. ### Testing, more testing, & finally success (0x55) Once the hardware was built, I had to test it - and it was a bit of a pain running back and forth from the car every time I wanted to try something new. I got stuck for almost two weeks getting my car to say anything at all. I went through the hardware and software with a fine tooth comb, until I realized I had only connected the K-Line and not the L-line. It turns out, Toyota is looking for the L-Line as well for the initial communications. At last, I got 0x55 in response to the pings. I was off and running now! 0x55 is a pattern 0b01010101, whose pattern adequately represents the ups and downs of those 2 weeks! ## Software It’s no badge of honor, but the size of code is 32kB, right at the limit of the Atmega328. Basically means I need to learn more compact coding skills. All of the code is posted at my repo. ### Mother of all loops: polling v. interrupts OK, so this is the project where I learned my lesson - but I implemented the code with one monster loop. It actually worked very well, except for one MAJOR problem that would really be a non-starter for anything PRO: the button-press recognition was all done by polling. This meant that sometimes it is unresponsive to a user’s button push, depending on the load of the processor. This happens rarely, but when it happens it is bad. The only real solution to this is to use an interrupts and an RTOS with a high priority handler thread for button presses, which I did on one of my future projects. In fact, it was exactly this problem that led me to investigate RTOS’s in the first place, but that’s another story. Learn by (re)doing. ### Getting information from the car A few more details associated with getting information from the car. Sometimes I knew exactly how the car would respond & and could send a compact request (in this case for the throttle position): temp = iso_putb(&thrott_put[0],1, ISO_P3_MIN); for (i =1; i<6; i++) {temp = iso_putb(&thrott_put[i],1, ISO_P4_MIN);} temp = iso_getb(&thrott_get[0],1, ISO_P2_MAX*2); for (i =1; i<7; i++) {temp = iso_getb(&thrott_get[i],1, ISO_W2_MAX*2);} serial_data = 0.3922*thrott_get[5];  In other cases, I did not know when the message would end, and would then have to compare the received byte with the running calculated checksum to determine the end of the message. (Yup, there’s a slight chance of making an error here, but we’re hacking folks). ISO_init_comm(0); temp = iso_putb(&ping_put[0],1, ISO_P3_MIN); for (i =1; i<ping_length; i++) { temp = iso_putb(&ping_put[i],1, ISO_P4_MIN); } ping_length = 1; temp = iso_getb(&ping_get[0],1, ISO_P2_MAX*2); ping_sum = ping_get[0]; while(1) { temp = iso_getb(&ping_get[ping_length],1, ISO_W2_MAX*2); if ((ping_length>3) && (ping_get[ping_length] == (UBYTE) ping_sum)) { break; //checksum ... last bit } //end if ping_sum += ping_get[ping_length]; ping_length++; }//end while  You’ll notice in each function call to iso_putb and iso_getb there are variables like ISO_P3_MIN, ISO_P2_MAX_2, etc… These are timing windows for each of the commands and responses. The best explanation of this I’ve seen is Trampas Stern’s website - there are a couple of informative tables there. I’m sure there is official documentation somewhere on the dark web. These variables can be used to mask the timing windows and handle errors in the communication timings should they arise. I did very little error handling. Yes, I know - bad, bad, bad. ### Averaging stuff Most of the math here is very simple. You can see the formulas above for MPG. In some cases I wanted instantaneous values and in others I wanted running averages. For the running (time) averages like average speed, it was important to have a good master clock to always pick from to update & you just need to think about the definitions of averages. running_time =(double) (running_time +dt_seconds); MPG_temp = (double) (7.101*VSS_temp/MAF_temp); running_dist =(double) (running_dist+0.6214*VSS_temp*dt_seconds/3600.0); running_gallons =(double) (running_gallons+2.4307e-5*MAF_temp*dt_seconds); MPG_ave = (double) (running_dist/running_gallons); speed_ave = (double) (3600.0*running_dist/running_time);  I did everything with floating point math, so there were no issues there. Powered-up & waiting for input The menu was a simple 2D array that held elements for submenus. Each element of the array linked to a code block that I could execute. At any moment in time, the code keeps track of where the user has navigated to and uses a simple UI feature (a “>”) to give the user a visual cue. The interface is a 2-button implementation, with the left button navigating up and down, and the right button selecting. These buttons are context sensitive and do different things in the submenu. In order not to get lost, I kept a little spreadsheet to remind me of the navigation path. Menu structure And here are all of the different screens in their glory … yes, its quite a few. OBD2 menu navigation Below is the code to do the reset of the cursor position. Not sure this is the most efficient solution, but it worked for me. while(1) { if (switch_is_pressed(&switchtype)) { if (switchtype == 1) { //we are scrolling curItem++; // add one to curr item cursorCount++; if (menuitem[curMenu][curItem][0] == '\0') { curItem = 0; pageScroll = 0; cursorCount = 0; } if (cursorCount >= pageSize) { // we have scrolled past this page, go to next // remember, we check if we have scrolled off the MENU under clicks. This is off the PAGE. pageScroll++; // next "page" cursorCount=0; // reset cursor location } menuCount = pageScroll*pageSize; break; } if (switchtype == 2) { //we are selecting // handle user input if (menuactn[curMenu][curItem]) { // has an action switch (menuactn[curMenu][curItem]) { case 1: //run MPG - DONE get_MPG(); break; case 2: //screen 1 of data - DONE get_data_set1(); break; case 3: //screen 2 of data - DONE get_data_set2(); break; case 4: //PIDS supported - DONE get_supported_PIDs(); break; // lots of other cases here case 999: //RETURN TO MAIN curMenu = 0; // return to main menu curItem = 0; // reset menu item to which cursor point pageScroll = 0; // reset menu page scroll cursorCount = 0; // reset menu location of page //menuCount = pageScroll*pageSize; // reprint from first line of this page break; }//switch menuCount = 0; break; } else //GO TO A SUB-MENU { curMenu = menulink[curMenu][curItem]; // set to menu selected by cursor curItem = 0; // reset menu item to which cursor point pageScroll = 0; // reset menu page scroll cursorCount = 0; // reset menu location of page menuCount = pageScroll*pageSize; // reprint from first line of this page break; }//end if action updateFlag = 1; // we have updated the menu. Flag is used to delay user input } // end we are selecting } // end switch is pressed } // end while (1)  ### Settings & EEPROM I decided to use the EEPROM to full effect in this project. Here is the layout of what I used it for: EEPROM layout Mainly to hold averaged data that I could read out later (I did not implement any SD-card memory), plus a few of user-defined constants. There were a couple screens that allowed the user to change these constants. That was kind of a fun thing to implement with just the two pushbuttons available. void set_gas_price (void){ _delay_ms(500); lcd_clear(); eeprom_address = 460; eeprom_read_block(&gas_price, (void*)eeprom_address, 4); lcd_goto_xy(1,1); fprintf_P(&lcd_out, PSTR("Current:")); lcd_goto_xy(1,2); fprintf_P(&lcd_out, PSTR("$%5.2f"), gas_price);

uint8_t d1=3;
uint8_t d2=5;
uint8_t d3=0;
uint8_t cur_item=3;
uint8_t done = 0;
while(1) {
if (done ==1) break;
lcd_goto_xy(1,3);
fprintf_P(&lcd_out, PSTR(" %d"), d1);
lcd_goto_xy(1,4);
fprintf_P(&lcd_out, PSTR(" %d"), d2);
lcd_goto_xy(1,5);
fprintf_P(&lcd_out, PSTR(" %d"), d3);
lcd_goto_xy(1,6);
fprintf_P(&lcd_out, PSTR(" OK"));

lcd_goto_xy(1,cur_item);
fprintf_P(&lcd_out, PSTR(">"));
_delay_ms(500);
while(1) {
if (switch_is_pressed(&switchtype)) {
if (switchtype == 1) { //we are scrolling
_delay_ms(500);
cur_item++;
if (cur_item == 7) cur_item = 3;
break;
}  //switchtype1
if (switchtype == 2) { //we incrementing
_delay_ms(500);
if (cur_item == 3) {
d1++;
if (d1==10) d1=0;
}
if (cur_item == 4) {
d2++;
if (d2 ==10) d2=0;
}

if (cur_item == 5) {
d3++;
if (d3 ==10) d3=0;
}
if (cur_item == 6) done =1;
break;
}//switchtype2
}//switchpressed
}//INNER WHILE

} //OUTER while
_delay_ms(500);
gas_price = (double)(100.0*d1+10.0*d2+d3)/100;
lcd_clear();
clean_start();
fprintf_P(&lcd_out, PSTR("\$%5.2f"), gas_price);
clean_exit_partial();
}

### Talking to the PC

I used the built in USART to talk to the PC - the code on the microcontroller side has a few twists. The first trick was implementing the stream capability to minimize use the use of RAM by storing as much as possible in flash (program) memory - the chip has 32K of Flash but only 2K of RAM.

/********************************************************************************
Global Variables
********************************************************************************/
static FILE usart_out = FDEV_SETUP_STREAM(usart_putchar_printf, usart_getchar_printf, _FDEV_SETUP_RW);
static FILE lcd_out = FDEV_SETUP_STREAM(lcd_chr_printf, NULL, _FDEV_SETUP_WRITE);

Next, to talk to the PC over serial, I used Visual Basic for Applications (VBA) within Excel. It is flexible, and can usually do the job if you are in a hurry. I posted the spreadsheet with the code, and also broke out the module macros individually. I used a set of serial communications routines (Modcomm) written by David M. Hitchner, with two modifications:

1. Every system function declaration needs to add PtrSafe for 64 bit operation

 '-------------------------------------------------------------------------------
' System Functions
'-------------------------------------------------------------------------------
Declare PtrSafe Sub AppSleep Lib "kernel32" Alias "Sleep" (ByVal dwMilliseconds As Long)

2. I forced Commread to only return the number of bytes lngSize that were called so I could just read one byte at a time. This worked really well for the read rates I was using.

 '-------------------------------------------------------------------------------
'
' Parameters:
'   intPortID   - Port ID used when port was opened.
'   strData     - Data buffer.
'   lngSize     - Maximum number of bytes to be read.
'
' Returns:
'   Error Code  - 0 = No Error.
'-------------------------------------------------------------------------------
If udtCommStat.cbInQue > 0 Then
'If udtCommStat.cbInQue > lngSize Then
'    lngRdSize = udtCommStat.cbInQue
'Else
lngRdSize = lngSize
'End If
Else
lngRdSize = 0
End If

So there are 4 macros I wrote that work over serial to a PC: PIPE2XL, PIPE2XL2, EEPROM2XL and PING.

Clickety clack … Cartalk

EEPROM2XL allowed me to read the EEPROM at any point in time, which was useful since I saved data there. PING - the hacker tool - was already described above, and could be used to send arbitrary commands to the car to see how it responded. Here it is again in action:

PING … doing its thing

PIPE2XL and PIPE2XL2 allowed me to ask the car to stream real-time data. Here is a video of the RPMs streaming to a laptop:

& here is an example of my speed on a road near our house ending in a traffic light, check back as I’ll try to post some cooler stuff.

Kinda boring … but analyzing a bunch of these might be interesting

All of them used the same VBA code snippet to ensure receiving good data from the microcontroller

Do While (still_going = 1)
end_of_string = 0
buf = ""
Do While (end_of_string = 0) 'not yet end of string
'read one byte at a time into a buffer
strData = ""
Do While (strData = "") 'nothing in buffer
Loop 'nothing in buffer
If ((strData <> Chr(13)) And (strData <> Chr(10))) Then
buf = buf + strData
Else
If strData = Chr(10) Then 'we read the string, flush buffer
Call CommFlush(intPortID)
end_of_string = 1
End If
End If
Loop 'end of string
total_count = total_count + 1
response_count = response_count + 1
If Val(buf) = 999 Then
still_going = 0
Else
Worksheets("PING").Cells(j + 2, response_count + 1).Value = Hex(Val(buf))
End If
Loop 'still_going

In the microcontroller, I escaped each byte with \r\n

fprintf_P(&usart_out,PSTR("%08.2f\r\n"), serial_data);

and in this particular case I also finish the overall transmission with 999 to make the VBA serial link end cleanly

fprintf_P(&usart_out,PSTR("%06d\r\n"),999);

## Learning by re-doing

### CAN bus

I actually got a bunch of use out of this project, and will probably make a CAN version at some point. If I do, I’ll probably go for an RTOS and design it so it can be mounted and unmounted in the car. Will have to start to go hunting for all of the CAN specs and protocols.

Updated: