A Textbook of Production Engineering_P. C. Sharma

126
7/25/2019 A Textbook of Production Engineering_P. C. Sharma http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 1/126 Scilab Textbook Companion for A Textbook of Production Engineering by P. C. Sharma 1 Created by Mayank Sahu B.E. Mechanical Engineering M. I. T. S Gwalior, M.P College Teacher None Cross-Checked by Bhavani Jalkrish November 3, 2014 1 Funded by a grant from the National Mission on Education through ICT, http://spoken-tutorial.org/NMEICT-Intro. This Textbook Companion and Scilab codes written in it can be downloaded from the ”Textbook Companion Project” section at the website http://scilab.in

Transcript of A Textbook of Production Engineering_P. C. Sharma

Page 1: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 1/126

Scilab Textbook Companion for

A Textbook of Production Engineering

by P. C. Sharma1

Created byMayank Sahu

B.E.Mechanical EngineeringM. I. T. S Gwalior, M.P

College Teacher

NoneCross-Checked byBhavani Jalkrish

November 3, 2014

1Funded by a grant from the National Mission on Education through ICT,http://spoken-tutorial.org/NMEICT-Intro. This Textbook Companion and Scilabcodes written in it can be downloaded from the ”Textbook Companion Project”section at the website http://scilab.in

Page 2: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 2/126

Book Description

Title:   A Textbook of Production Engineering

Author:  P. C. Sharma

Publisher:  S. Chanda & Company, New Delhi

Edition:   11

Year:   2008

ISBN:   9788121901116

1

Page 3: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 3/126

Scilab numbering policy used in this document and the relation to theabove book.

Exa  Example (Solved example)

Eqn  Equation (Particular equation of the above book)

AP  Appendix to Example(Scilab Code that is an Appednix to a particularExample of the above book)

For example, Exa 3.51 means solved example 3.51 of this book. Sec 2.3 meansa scilab code whose theory is explained in Section 2.3 of the book.

2

Page 4: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 4/126

Contents

List of Scilab Codes   4

2 Press Tool Design   9

4 Cost Estimating   21

5 Economics of tooling   34

9 Limits Tolerences and Fits   62

11 Surface finish   69

13 Analysis of metal forming processes   71

14 Theory of metal cutting   80

15 Design and manufacture of cutting tools   94

16 Gear manufacture   101

17 Thread manufacturing   102

21 Statical quality control   103

22 Kinematics of machine tools   114

23 Production planning and control   120

26 Plant layout   125

3

Page 5: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 5/126

List of Scilab Codes

Exa 2.1 find total pressure and dimensions   . . . . . . . . . . . 9Exa 2.2 To find number of draws . . . . . . . . . . . . . . . . . 10Exa 2.3 To calculate bending force   . . . . . . . . . . . . . . . 10Exa 2.4 find blanking force and work done   . . . . . . . . . . . 10Exa 2.5 To find elastic recovery of material   . . . . . . . . . . . 11Exa 2.6 To find cutting forces   . . . . . . . . . . . . . . . . . . 11Exa 2.7 To calculate amount of shear   . . . . . . . . . . . . . . 12Exa 2.8 To find economy of material . . . . . . . . . . . . . . . 12Exa 2.9 Calculations for designing drawing die   . . . . . . . . . 13Exa 2.10 Determine developed length  . . . . . . . . . . . . . . . 15Exa 2.11 To calculate bending force . . . . . . . . . . . . . . . . 15Exa 2.12 To calculate bending force . . . . . . . . . . . . . . . . 16Exa 2.13 calculate capacity of double bending die   . . . . . . . . 16

Exa 2.14 To calculate cutting force   . . . . . . . . . . . . . . . . 17Exa 2.15 Determine blank and punch diameter   . . . . . . . . . 17Exa 2.16 To find drawing operations and force  . . . . . . . . . . 18Exa 2.17 Determine developed length  . . . . . . . . . . . . . . . 19Exa 4.1 To calculate total cost and SP   . . . . . . . . . . . . . 21Exa 4.2 To find selling price   . . . . . . . . . . . . . . . . . . . 21Exa 4.3 To find factory cost   . . . . . . . . . . . . . . . . . . . 22Exa 4.4 find production cost and time taken   . . . . . . . . . . 23Exa 4.5 To find profit   . . . . . . . . . . . . . . . . . . . . . . . 23Exa 4.6 To find lot size and time . . . . . . . . . . . . . . . . . 24Exa 4.7 To find time to change cutter   . . . . . . . . . . . . . . 24

Exa 4.8 To find tool change time . . . . . . . . . . . . . . . . . 25Exa 4.9 To calculate measuring time allowance   . . . . . . . . . 25Exa 4.10 To find direct labour cost   . . . . . . . . . . . . . . . . 25Exa 4.11 To find machining time   . . . . . . . . . . . . . . . . . 26

4

Page 6: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 6/126

Exa 4.12 To find time to turn relief   . . . . . . . . . . . . . . . . 27

Exa 4.13 calculate time to face on lathe   . . . . . . . . . . . . . 27Exa 4.14 To find time to drill hole   . . . . . . . . . . . . . . . . 28Exa 4.15 To find time to complete cut   . . . . . . . . . . . . . . 28Exa 4.16 To find time to broach  . . . . . . . . . . . . . . . . . . 29Exa 4.17 find feed cutter travel and time   . . . . . . . . . . . . 29Exa 4.18 To find cutting time   . . . . . . . . . . . . . . . . . . . 30Exa 4.19 To find milling time   . . . . . . . . . . . . . . . . . . . 30Exa 4.20 To find time to grind shaft   . . . . . . . . . . . . . . . 31Exa 4.21 To find time to cut threads   . . . . . . . . . . . . . . . 31Exa 4.22 find time to produce one piece   . . . . . . . . . . . . . 32Exa 5.1 To find value of machine tool   . . . . . . . . . . . . . . 34

Exa 5.2 To find annual investment   . . . . . . . . . . . . . . . . 35Exa 5.3 find project is economical or not   . . . . . . . . . . . . 35Exa 5.4 selection of economical machine . . . . . . . . . . . . . 36Exa 5.5 selection of machine   . . . . . . . . . . . . . . . . . . . 37Exa 5.6 selection of economical machine . . . . . . . . . . . . . 38Exa 5.7 find ERR and economicality of project   . . . . . . . . . 38Exa 5.9 find ERR and economicality of project   . . . . . . . . 39Exa 5.10 To determine acceptance of machine   . . . . . . . . . . 39Exa 5.11 find investment cost and unamortized value . . . . . . 40Exa 5.13 To make decision of machines replacement   . . . . . . . 40

Exa 5.15 Determine economic repair life   . . . . . . . . . . . . . 41Exa 5.16 find time to pay for itself   . . . . . . . . . . . . . . . . 42Exa 5.17 selection of machine for job   . . . . . . . . . . . . . . . 43Exa 5.18 Calculate maximum investment on turret lathe   . . . . 44Exa 5.19 To find years for new machine . . . . . . . . . . . . . . 45Exa 5.20 To find cost and pieces . . . . . . . . . . . . . . . . . . 46Exa 5.21 To find number of components   . . . . . . . . . . . . . 47Exa 5.22 To find number of components   . . . . . . . . . . . . . 47Exa 5.23 To find time and profit   . . . . . . . . . . . . . . . . . 48Exa 5.24 To find minimum number of components . . . . . . . . 48Exa 5.25 To calculate number of pieces  . . . . . . . . . . . . . . 49

Exa 5.26 To find cost for new fixture   . . . . . . . . . . . . . . . 49Exa 5.27 find time to amortize fixture   . . . . . . . . . . . . . . 50Exa 5.28 To find profit   . . . . . . . . . . . . . . . . . . . . . . . 51Exa 5.29 To find BEP Cost and Components   . . . . . . . . . . 51Exa 5.30 To find break even point . . . . . . . . . . . . . . . . . 52

5

Page 7: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 7/126

Exa 5.31 To find break even quantity   . . . . . . . . . . . . . . . 52

Exa 5.32 To do break even analysis   . . . . . . . . . . . . . . . . 54Exa 5.33 To calculate minimum number of pieces   . . . . . . . . 54Exa 5.34 To determine the point   . . . . . . . . . . . . . . . . . 55Exa 5.35 To find quantity of pieces   . . . . . . . . . . . . . . . . 55Exa 5.36 To determine quantity of production   . . . . . . . . . . 56Exa 5.37 find preference between machines and production   . . . 56Exa 5.38 To find BEP and various sales   . . . . . . . . . . . . . 57Exa 5.39 To determine break even point   . . . . . . . . . . . . . 58Exa 5.40 To calculate economic lot size  . . . . . . . . . . . . . . 58Exa 5.41 To find EOQ and total cost   . . . . . . . . . . . . . . . 59Exa 5.42 Determine optimum lot size   . . . . . . . . . . . . . . . 60

Exa 5.43 To find most economical lot size   . . . . . . . . . . . . 61Exa 9.1 To find allowance and tolerence  . . . . . . . . . . . . . 62Exa 9.2 Determine dimensions of shaft and hole   . . . . . . . . 62Exa 9.3 Determine dimensions of hole and shaft   . . . . . . . . 63Exa 9.4 Calculate fundamental deviations and tolerences   . . . 63Exa 9.5 Find tolerences limits and clearance   . . . . . . . . . . 64Exa 9.6 Determine limits of shaft and hole   . . . . . . . . . . . 65Exa 9.7 Determine dimensions of shaft and hole   . . . . . . . . 66Exa 9.8 Determine size of bearing and journal   . . . . . . . . . 66Exa 9.9 Determine size of two mating parts  . . . . . . . . . . . 67

Exa 9.10 Determine size of hole and shaft   . . . . . . . . . . . . 68Exa 11.1 Calculate CLA value  . . . . . . . . . . . . . . . . . . . 69Exa 11.2 Calculate average and rms value   . . . . . . . . . . . . 69Exa 13.1 To find drawing load  . . . . . . . . . . . . . . . . . . . 71Exa 13.2 Calculate drawing force   . . . . . . . . . . . . . . . . . 72Exa 13.3 find neutral section slips and pressure   . . . . . . . . . 72Exa 13.4 To determine maximum force   . . . . . . . . . . . . . . 73Exa 13.5 Determine sticking radius and total load   . . . . . . . . 74Exa 13.7 To find drawing load and power . . . . . . . . . . . . . 74Exa 13.8 calculate drawing load and power rating   . . . . . . . . 75Exa 13.9 To calculate forging loads   . . . . . . . . . . . . . . . . 76

Exa 13.10 Determine extrusion load   . . . . . . . . . . . . . . . . 76Exa 13.11 To find roll pressures . . . . . . . . . . . . . . . . . . . 77Exa 13.12 Determine neutral plane  . . . . . . . . . . . . . . . . . 78Exa 14.1 calculate the tool life . . . . . . . . . . . . . . . . . . . 80Exa 14.2 Calculate the optimum cutting speed . . . . . . . . . . 80

6

Page 8: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 8/126

Exa 14.3 To find different orthogonal cutting picture   . . . . . . 81

Exa 14.4 To find tool life . . . . . . . . . . . . . . . . . . . . . . 82Exa 14.5 find force and coefficient of friction   . . . . . . . . . . 83Exa 14.6 To find terms of orthogonal cutting . . . . . . . . . . . 84Exa 14.7 To solve tool life equation   . . . . . . . . . . . . . . . 85Exa 14.8 Determine normal and tangential force  . . . . . . . . . 85Exa 14.9 To find cutting and thrust force . . . . . . . . . . . . . 86Exa 14.10 find terms of orthogonal rake system  . . . . . . . . . . 87Exa 14.11 Calculate CLA   . . . . . . . . . . . . . . . . . . . . . . 88Exa 14.12 Calculate back and side rake angle   . . . . . . . . . . . 88Exa 14.13 Calculate inclination and rake angle   . . . . . . . . . . 89Exa 14.14 find different powers and resistance  . . . . . . . . . . . 89

Exa 14.15 Calculate percentage increase in tool life   . . . . . . . . 90Exa 14.16 To find percentage of total energy   . . . . . . . . . . . 90Exa 14.17 To find power and different energies   . . . . . . . . . . 91Exa 14.18 Determine components of force and power   . . . . . . . 92Exa 15.1 calculate horsepower at cutter and motor   . . . . . . . 94Exa 15.2 Determine broaching power and Design broach   . . . . 94Exa 15.3 Estimate moment thrust force and power   . . . . . . . 96Exa 15.4 Design shell inserted blade reamer   . . . . . . . . . . . 96Exa 15.5 To design single point cutting tool   . . . . . . . . . . . 97Exa 15.8 find various terms for stainless steel   . . . . . . . . . . 98

Exa 15.9 To find MRR power and torque  . . . . . . . . . . . . . 99Exa 15.10 find MRR power torque and time   . . . . . . . . . . . 99Exa 16.1 Calculate settings of gear tooth  . . . . . . . . . . . . . 101Exa 17.1 Calculate best wire size   . . . . . . . . . . . . . . . . . 102Exa 17.2 Calculate size and distances over wire   . . . . . . . . . 102Exa 21.1 Construct R and X chart   . . . . . . . . . . . . . . . . 103Exa 21.2 Construct the control charts . . . . . . . . . . . . . . . 104Exa 21.4 Calculate poisson probabilities   . . . . . . . . . . . . . 106Exa 21.5 Calculate probabilities of defective items   . . . . . . . 106Exa 21.6 Determine producers and consumers risk . . . . . . . . 107Exa 21.7 Evaluate preliminary and revised control limits   . . . . 107

Exa 21.8 Find control limits for c chart   . . . . . . . . . . . . . 109Exa 21.9 find control limits for charts . . . . . . . . . . . . . . . 110Exa 21.10 Determine producers and consumers risk . . . . . . . . 112Exa 22.1 Find range of cutting velocity   . . . . . . . . . . . . . . 114Exa 22.2 Determine speed ratios and teeth  . . . . . . . . . . . . 115

7

Page 9: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 9/126

Exa 22.3 Calculate speed and number of teeths   . . . . . . . . . 116

Exa 22.4 Calculate common ratio   . . . . . . . . . . . . . . . . . 117Exa 22.5 Calculate gear ratio teeth and speed   . . . . . . . . . . 118Exa 23.1 Calculate forecast   . . . . . . . . . . . . . . . . . . . . 120Exa 23.2 Calculate forecat by SMA method   . . . . . . . . . . . 120Exa 23.3 Calculate forecat by WMA method   . . . . . . . . . . 121Exa 23.4 Calculate forecast for january   . . . . . . . . . . . . . . 121Exa 23.5 Calculate total cost   . . . . . . . . . . . . . . . . . . . 122Exa 23.6 Calculate economical order quantity   . . . . . . . . . . 122Exa 23.7 Calculate economic lot size   . . . . . . . . . . . . . . . 122Exa 23.8 Calculate inventory control terms . . . . . . . . . . . . 123Exa 23.9 Calculate discount offered   . . . . . . . . . . . . . . . . 123

Exa 23.10 Calculate EOQ and reorder point . . . . . . . . . . . . 124Exa 26.1 Calculate number of machine required   . . . . . . . . . 125

8

Page 10: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 10/126

Chapter 2

Press Tool Design

Scilab code Exa 2.1  find total pressure and dimensions

1   clc

2   D = 5 0   // D ia me te r o f w as he r i n mm3   t = 4   // t h i c k n e s s o f m a t e r i a l i n mm4   d = 2 4   // d ia me te r o f h o l e i n mm5   p = 360   // s h e ar s t r e n g t h o f m a t e r i a l i n N/mmˆ26   F 1 = % pi * D* t *p   // b l a nk in g p r e s s u r e i n N

7   F 2 = % pi * d* t *p   // p i e r c i n g p r e s s u r e i n N8   F = F 1 + F 2   // t o t a l p r e s s u r e i n N9   d1 = d + 0.4   // p i e r c i n g d i e d ia me te r i n mm

10   d2 = D - 0.4   / / b l an k punch d i a m et e r i n mm11   c = 0.8* F   // p r e s s c ap a c i t y i n N12   printf ( ” \n B l an k in g p r e s s u r e = %d kN\n P i e r c i n g

p r e s s u r e = %0 . 3 f KN\n T o ta l p r e s s u re r e q u i r e d =%0 . 1 f KN”   , F 1 / 1 0 0 0 , F 2 / 1 0 0 0 , F / 1 0 0 0 )

13   printf ( ” \n p i e r c i n g punch d i a me t er = %0 . 2 f cm\nb l a n k i n g p un ch d i a m e t r e = %0 . 2 f cm   \n p r e s s

c a p a c i t y = %0 . 2 f KN\n” , d1 / 10 , d2 /10 , c / 10 00 )14   / / A nswers v ar y d ue t o ro und o f f e r r o r

9

Page 11: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 11/126

Scilab code Exa 2.2  To find number of draws

1   clc

2   h = 1 0   // h e i g h t o f cup i n cm3   d = 5   // d ia me te r o f cup i n cm4   D =   sqrt ( d ^2 + 4 *d * h)   // b la nk d i am e te r i n cm5   // h e i g h t d ai me te r r a t i o i s 2 . T he re f o r e from t a b l e

2 . 9 t o t a l r e d u c t i o n s a re 36   r 1 = 0 .4 5* D   // f i r s t r e d u c t io n i s 45%7   d1 = D - r 1   // d i a me t e r a t f i r s t draw i n cm8   r 2 = d 1 *0 .2 5   // s ec on d r e du c t io n i s 25%9   d2 = d1 - r 2   // d i am e te r a t s ec on d draw i n cm

10   r3 = d2 * 0.2   // t h i r d r e d u ct i o n i s 20%11   d3 = d2 - r 3   // d i a me te r a t t h i r d draw i n cm12   printf ( ” \n D i am e te r a t f i r s t draw = %0 . 2 f cm\n

D ia me te r a t s e co n d draw = %0 . 2 f cm\n D ia me te r a tt h i r d d ra w =%0 . 3 f cm”   , d1 , d2 , d3 )

Scilab code Exa 2.3  To calculate bending force

1   clc2   K = 1.20   // d ie −o pe ni ng f a c t o r3   L = 37.5   // Length o f s t r i p i n cm4   T = 2.5   // t h i c k n e s s o f s t r i p i n mm5   s i g ma _ ut = 6 30   // t e n s i l e s t r e n g t h i n N/mmˆ26   W = 16* T   // wi dt h o f d i e o pe ni ng i n mm7   F = ( K * L *1 0* s i g ma _ ut * T ^ 2) / W   // b en d i ng f o r c e i n N8   printf ( ” \n b e n di n g f o r c e = %0 . 1 f KN”   , F / 1 00 0)

Scilab code Exa 2.4  find blanking force and work done

1   clc

2   b = 2 5   // w id th o f b la nk i n mm

10

Page 12: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 12/126

3   l = 3 0   // l e ng t h o f b la nk i n mm

4   t au = 450   // u l t i m a t e s he ar s t r e s s o f m a t e r i a l i n N/mmˆ25   t = 1.5   // t h i c k n e s s o f m e t a l s t r i p i n mm6   p = 2*( l + b )   // p e r i me t e r o f b la nk i n mm7   f = p *t * tau   // b la nk i ng f o r c e i n N8   P t = 0 .2 5* t   // punch t r a v e l i n mm9   w = f * Pt   / / w or k d o ne i n Nmm

10   printf ( ” \n b l an k i ng f o r c e = %0 . 2 f KN\n work d one =%0 . 2 f Nm” , f / 1 00 0 , w / 1 0 0 0 )

Scilab code Exa 2.5  To find elastic recovery of material

1   clc

2   t = 1.5   // t h i c k n e s s i n mm3   c = 0. 05 * t   // c l e a r a n c e i n mm4   D = 25.4   // o u t s i d e d i am et e r i n mm5   D_o = D - 0.05   // b la nk d i e o pe ni ng i n mm6   B_s = D_o - 2* c   // b l a nk i n g punch s i z e i n mm7   d = 12.7   // i n t e r n a l d i a me te r i n mm

8   P_s = d + 0.05   // p i e r c i n g punch s i z e i n mm9   D_s = P_s + 2* c   // p i e r c i n g d i e s i z e i n mm

10   printf ( ” \n c l e a r a n c e = %0 . 3 f mm\n b la nk d i e o pe ni ngs i z e = %0 . 2 f mm ” , c , D_ o)

11   printf ( ” \n b l a n k i n g punch s i z e = %0 . 2 f mm\n p i e r c i n gp un ch s i z e = %0 . 2 f mm\n p i e r c i n g d i e s i z e = %0 . 2

f mm” , B _s , P _s , D _ s )

Scilab code Exa 2.6  To find cutting forces

1   clc

2   D = 25.4   // o u t s i d e d i am et e r i n mm3   d = 12.7   // i n t e r n a l d i a me te r i n mm

11

Page 13: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 13/126

4   t = 1.5   // t h i c k n e s s i n mm

5   t au = 280   // u l t i m a t e s h e a r i n g s t r e n g t h i n N/mmˆ 26   F = %pi *( D + d )* t* tau   // t o t a l c ut t i n g f o r c e i n N7   F _ s = % pi * D * t* t au   // c u t t i n g f o r c e when p un ch es a r e

s t a g ge r e d i n N8   k = 0.6   // p e n e t r a t i o n9   i = 1   // s h ea r o f punch i n mm

10   F _p = ( t *k *F ) /( k *t + i) // c u t t i n g f o r c e when b o thp un ch es a ct t o g e t h e r i n N

11   printf   ( ” \n s h e ar f o r c e when b ot h punch a c t a t samet im e and no s h ea r i s a p p l i e d = %0 . 2 f kN”   , F

/1000)

12   printf ( ” \n c u t t i n g f o r c e when p unc he s a r e s t a gg e r ed= %0. 1 f kN ”, F _ s / 1 00 0 )

13   printf ( ” \n c u t t i ng f o r c e when t h e r e i s p e ne t ra t i o na nd s h e a r on p un ch = %0 . 1 f kN” , F _ p / 1 0 0 0 )

Scilab code Exa 2.7  To calculate amount of shear

1   clc

2   D = 6 0   // h o l e d i am et er i n mm3   t au = 450   // u l t i m a t e s h e a r s t r e n g t h i n N/mmˆ24   t = 2.5   // t h i c k n e s s i n mm5   F = % pi * D *t * ta u   / / maximum p un ch f o r c e i n N6   w = F *0 .4 *t   / / wo rk d on e i n Nm7   f = F /2   // p un ch in g f o r c e i n N8   k = 0.4   // p e n e t r a t i o n p e r ce n t a ge9   i = k *t *( F -f ) /f   / / s h e a r on punch i n mm

10   printf ( ” \n Amount o f s h e a r o n p un ch = %d mm”   , i )

Scilab code Exa 2.8  To find economy of material

1   clc

12

Page 14: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 14/126

2   // f rom f i g 2 . 2 7

3   w = 2.5   / / cm4   t = 3.2   // s t r i p t h i c k n e ss i n mm5   h = 1 0   // cm6   a = t + 0 .015* h *10   // back s c r a p and f r o n t s c ra p i n

mm7   b = t   // s c ra p b r i d ge i n mm8   W = h + ( 2 * a ) / 1 0   // w i dt h o f s t r i p i n cm9   W =   ceil ( W )   // cm

10   s = w + b /10   // l en g t h o f one p i e c e o f s to c k i n cm11   L = 240   // l en g t h o f s t r i p i n cm12   N = (L - b) /s   // number o f p a r t s

13   y = L - ( N * s + b /10)   // s c r a p r em ai ni ng a t t he endi n mm

14   printf ( ” \n V al ue o f b ac k s c r a p = %0 . 1 f mm\n V al ue o f  s c r a p b r i d g e = %0 . 1 f mm ”   , a , b )

15   printf ( ” \n Width o f s t r i p = %0 . 2 f cm\n L en gt h o f on ep i e c e o f s t oc k n ee d ed t o p ro du ce one p ar t = %0 . 2

f cm”   , W , s )

16   printf ( ” \n Number o f p a r t s = %0 . 1 f b l a n k s \n S cr apr e m a i n i n g a t t h e e nd = %0 . 2 f mm”   , N , y )

17   / / A nswers v ar y d ue t o ro und o f f e r r o r

Scilab code Exa 2.9   Calculations for designing drawing die

1   clc

2   // from f i g u r e 2 . 7 33   t = 0.8   // t h i c k n e s s i n mm4   d = 5 0   // s h e l l d ia me te r i n mm5   r = 1.6   // r a d i u s o f bottom c o r n er i n mm

6   h = 5 0   // h e i g ht i n mm7   D =   sqrt ( d ^2 + 4 *d * h)   // s h e l l b l an k s i z e i n mm8   e l = 6.4   // e xt ra l en gt h r e q u i r e d t o add i n s h e l l

b la nk s i z e9   D = D + el   // mm

13

Page 15: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 15/126

10   p r = 1 00 *( 1 - ( d / D) )   // p e r ce n t ag e r e d u c t io n

11   r at io = h /d12   n = 2   / / number o f d ra ws13   R 1 = 45   / / f i r s t r e d u c t i o n14   D1 = D - R1 *D /100   // d i am e te r a t f i r s t r e d u c ti o n i n

mm15   R 2 = 1 00 *( 1 - ( d / D1 ) )   // s ec on d r e d u c t io n16   P R = 4* t   // punch r a d i u s i n mm17   PR =   ceil ( P R )

18   D R = 6   // d i e r a d i u s i n mm19   DC1 = 0 .8 7   // d i e c l e a r a n c e f o r f i r s t draw i n mm20   DC2 = 0 .8 8   // d i e c l e a r a n c e f o r s ec on d draw i n mm

21   PD2 = d - 2* t   // punch d i am e te r f o r s ec on d draw i nmm

22   DD2 = PD2 + 2* DC2   // Di e o pe ni ng d i am e te r f o r s ec on ddraw i n mm

23   PD1 = D1 - 2* t   / / punch d i a me t er f o r f i r s t draw i nmm

24   DD1 = D1 + 2* DC1   // D ie o p en i ng d i a me t er f o r f i r s tdraw i n mm

25   / / D ra win g p r e s s u r e26   c = 0.65   // c o n st a n t27   s i gm a = 4 27

  / / N/mmˆ228   F = % pi * d * t* s i gm a * ( D/ d - c)   / / Dra wi ng p r e s s u r e i n mm29   Bhp = 3 0. 8   // b l an k i n g h o ld i ng p r e s s ur e i n kN30   p c = 150   // p r e s s c a pa c i t y i n kN31   printf ( ” \n ( i ) s i z e o f b la nk = %0 . 2 f mm   \n ( i i )

P e r ce n t ag e r e d u c t i o n = %0 . 1 f p e r c e n t   \n ( i i i )Number o f d r a ws = %d   \n ( i v ) R a d iu s o n p un ch = %d

mm   \n Die R adi us = %d mm   \n ( v ) Di e c l e a r a nc ef o r f i r s t d ra w = %0 . 2 f mm   \n d i e c l e a r a n c e

f o r s e c o n d d ra w = %0 . 2 f mm”   , D , pr , n , PR , DR , DC1 ,

D C 2 )

32   printf ( ” \n Punch d i am et er f o r s ec on d draw = %0 . 1 f  mm   \n Di e o pe ni ng d ia me te r f o r s ec on d draw = %0. 2 f mm   \n Punch d ia me te r f o r f i r s t draw = %0 . 3f mm   \n Di e o pe n in g d ia me te r f o r f i r s t draw =%0 . 3 f mm\n ( v i ) D ra wi ng p r e s s u r e = %0 . 2 f mm   \n (

14

Page 16: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 16/126

v i i ) Bl ank h o l d in g p r e s s u r e = %d kN   \n ( v i i i )

P r e s s c a p a c i t y = %d kN”   , PD2 , DD2 , PD1 , DD1 , F/ 100 0 , Bhp , pc )

33   / / A nswers v ar y d ue t o ro und o f f e r r o r

Scilab code Exa 2.10   Determine developed length

1   clc

2   // from f i g u r e 2 . 7 4

3   l1 = 76 - ( 2.3 + 0.90)   / / l e n g th 1 i n mm4   l 2 = 115 - (2.3 + 0.90)   / / l e n g th 2 i n mm5   t = 2.3   / / mm6   r = 0.90   // i n n er r a d i us i n mm7   k = t /3   / / mm8   B = 0 .5 * %pi *( r + k )   // b en d in g a l l o w a n c e i n mm9   d = l1 + l2 + B   // d e ve l op e d l e n g t h i n mm

10   printf ( ” \n D e v el o p e d l e n g t h = %0 . 2 f mm”   , d )

11   / / A nswers v ar y d ue t o ro und o f f e r r o r

Scilab code Exa 2.11  To calculate bending force

1   clc

2   t = 3.2   // t h i c k n e s s o f b la nk i n mm3   l = 900   // b en d in g l e n g t h i n mm4   s i gm a = 4 00   // u l t i m at e t e n s i l e s t r e n g t h i n N/mmˆ25   k = 0.67   // d i e o pe ni ng f a c t o r6   r 1 = 9.5   / / punch r a d i u s i n mm7   r 2 = 9.5   // d i e e d ge r a d i u s i n mm

8   c = 3.2   // c l e a r a n c e i n mm9   w = r1 + r2 + c   // w id th b etw een c o n ta c t p o i n t s

b at we en d i e and p unc h i n mm10   F = ( k * l * s i gm a * t ^ 2 ) / w   // b e n d in g f o r c e i n N11   F = floor ( F / 1 0 ) * 1 0   // N

15

Page 17: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 17/126

12   printf ( ” \n b en d in g f o r c e = %0 . 2 f kN”   , F / 1 0 0 0 )

Scilab code Exa 2.12  To calculate bending force

1   clc

2   k = 1.33   // d i e o pe ni ng f a c t o r3   l = 1200   // bend l e n g t h i n mm4   s i gm a = 4 55   // u l t i m at e t e n s i l e s t r e n g t h i n N/mmˆ25   t = 1.6   // b la nk t h i c k n e s s i n mm

6   w = 8* t   // w id th o f d i e o pe ni ng i n mm7   F = k * l * si gm a * t ^2 / w   // b en di n g f o r c e i n N8   printf ( ” \n b en di ng f o r c e = %0 . 2 f kN” , F / 1 00 0)

Scilab code Exa 2.13  calculate capacity of double bending die

1   clc

2   c = 1.25   // c l e a r a n c e i n mm

3   r 1 = 3   // d i e r a d i u s i n mm4   r 2 = 1.5   / / punch r a d i u s i n mm5   s i gm a = 3 15   // u l t i m at e t e n s i l e s t r en g t h i n MPa6   t = 1   // t h i c k n e s s i n mm7   l = 5 0   / / w id th a t bend i n mm8   w = r1 + r2 + c   // w id th b et wee n c o n t ac t p o i n t s on

d i e and p un ch i n mm9   F = 0 .6 7* l * s i gm a * t ^2 / w   // b en d i ng f o r c e i n N

10   F _p = 0 .6 7* s i g ma * l * t   // pad f o r c e i n N11   s ig ma _c = 5 60   // s e t t i n g p r e s su r e i n MPa12   b 1 = 2   // b e ad s on p un ch13   b = b1 *r1   / / mm14   F _ b = s ig m a_ c * l *b   // b ot to mi ng f o r c e i n N15   F _o = F_p + F_b   // F or ce r e q u i r e d when b ot to mi ng i s

u se d i n N

16

Page 18: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 18/126

16   F_n = F + F_p   // F or ce r e q u i r e d when b ot to mi ng i s n ot

us ed i n N17   printf ( ” \n F o rc e r e q u i r e d when b ot to mi ng i s u se d =%0 . 1 f t o n n e s ”   , F _ o / ( 9 . 8 1 * 1 0 0 0 ) )

18   printf ( ” \n F or ce r e q u i r e d when b ot to mi ng i s n ot u se d= %0 . 3 f t o n n e s ”   , F _n / ( 9 . 81 * 1 0 00 ) )

Scilab code Exa 2.14  To calculate cutting force

1   clc2   w = 2   / / w id t h i n mm3   t = 5   // t h i c k n e s s i n mm4   t h e t a = 6   // s he ar i n d e g r e e s5   t a u = 3 82 .5   // u l t i m at e s h ea r s t r e s s i n MPa6   F = w * t * ta u * 10 00   // c u t t i n g f o r c e i n N7   l = t / sin ( t h e t a * % p i / 1 8 0 )   // l e ng t h t o be c ut i n mm8   F _i = l * t* ta u   // c u t t i n g f o r c e i n N9   printf ( ” \n c u t t i n g f o r c e w i t h p a r a l l e l c u t t i n g e d ge s

= %0. 3 f MN\n c u t t i n g f o r c e when s he ar i sc o n s i d e r e d = %0 . 2 f kN ” , F / 1 0^ 6 , F _i / 1 0 0 0 )

Scilab code Exa 2.15  Determine blank and punch diameter

1   clc

2   d 1 = 105   // i n s i d e d i am et er i n mm3   h = 9 0   / / d ep th i n mm4   t = 1   // t h i c k n e s s i n mm5   D =   sqrt ( d 1 ^ 2 + 4 * d 1 * h )   // b l an k d i a me t er i n mm

6   t r = t * 10 0/ D   // t h i c k n e s s r a t i o7   // f rom t a b l e s a f e d r a w i n g r a t i o i s 1 . 8 28   r = 1.82   // draw r a t i o9   d 2 = D / r   / / d i a m e t e r f o r f i r s t draw i n mm

10   d = 130   / / L et d i a me t e r f o r f i r s t draw i n mm

17

Page 19: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 19/126

11   r at io 1 = D /d   / / D/ d f o r f i r s t d ra w

12   r at io 2 = d / d1   // D/ d f o r s e co n d draw13   h 1 = ( ( D ) ^2 - ( d ) ^ 2 ) / ( 4* d )   / / D ep th o f f i r s t d ra w i n mm14   s i gm a = 4 15   / / N/mmˆ215   c = 0.65   // c o n st a n t16   p c = % pi * d* t * si gm a (D /d - c )   // p r e s s c a p a ci t y i n kN17   printf ( ” \n B l an k d i a m e t e r = %d mm   \n T hi ck ne ss r a t i o

= %0. 3 f    \n D i a m e t e r f o r f i r s t d ra w = %d mm   \nDepth of f i r s t draw = %0. 2 f mm   \n P r e ss c a p ac i t y= %0. 2 f kN ”   , D , t r , d 2 , h 1 , p c / 1 0 0 0 )

18   / / A nswers v ar y d ue t o ro und o f f e r r o r

Scilab code Exa 2.16  To find drawing operations and force

1   clc

2   d = 8 0   / / d i a me t e r i n mm3   h = 250   / / h e i g h t i n mm4   D =   sqrt ( ( d ^ 2 + 4 * d * h ) ) / 1 0   // b la nk d i am et er i n cm5   D 1 = 0. 5* D   / / d i a me t er a f t e r f i r s t draw i n cm6   / / l e t r e du c t i o n be 40% i n s ec on d draw

7   D 2 = D1 - 0 .4 * D1   // d i am e te r a f t e r s co nd draw i n cm8   R = (1 - ( d /( 10 * D2 ) )) * 10 0   // p e r ce n t ag e r e d u c t io n

f o r t h i r d draw9   l 1 = ( ( D) ^ 2 -( D 1 ) ^2 ) / (4 * D1 )   // h e i g h t o f cup a f t e r

f i r s t d ra w i n cm10   l 2 = ( ( D) ^ 2 -( D 2 ) ^2 ) / (4 * D2 )   // h e i g h t o f cup a f t e r

f i r s t d ra w i n cm11   l 3 = ( ( D ) ^2 - ( d / 1 0 ) ^ 2) / ( 4 * d / 1 0)   // h e i g h t o f cup

a f t e r f i r s t draw i n cm12   t = 3   // mm

13   s i gm a = 2 50   / / N/mmˆ214   C = 0.66

15   F = % pi * d / 1 0 * t * s i gm a * ( ( D * 1 0/ d ) - C )   // d ra wi ng f o r c ei n kN

16   printf ( ” \n D i am e te r a f t e r f i r s t dra w = %0 . 1 f    \n

18

Page 20: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 20/126

D ia me te r a f t e r s e co n d draw = %0 . 2 f    \n P e r ce n t ag e

r e d u c ti o n a f t e r t h i r d draw = %d p e r ce n t ” , D 1 , D 2 , R )17   printf ( ” \n H ei g ht o f cup a f t e r f i r s t draw = %0 . 2 f cm\n H ei gh t o f cup a f t e r s ec on d draw = %0 . 2 f cm\nH ei gh t o f cup a f t e r t h i r d draw = %0 . 2 f cm” , l1 , l 2

, l 3 )

18   printf ( ” \n D ra wi ng f o r c e = %0 . 3 f kN” , F / 1 0 0 0 )

19   / / A nswers v ar y d ue t o ro und o f f e r r o r

Scilab code Exa 2.17   Determine developed length

1   clc

2   / / from f i g u r e 2 . 7 5 ( a )3   r 1 = 30   // r a d i u s i n mm4   t = 1 0   // t h i c k n e s s i n mm5   h 1 = 300   // h e i g h t i n mm6   i r1 = r1 - t   // i n n er r a d i u s o f be nds i n mm7   L 1 = h1 - ( ir 1 +t )   // mm8   a l ph a1 = 90   // d e gr e e9   r 2 = 2* t   / / mm

10   k = 0. 33 * t   // mm11   L 2 = a l p ha 1 * 2 * % p i * ( r2 + k ) / 3 6 0   / / mm12   w = 200   / / mm13   L 3 = w - 2* ( t+ i r1 ) // mm14   L 4 = L2   //mm15   h 2 = 100   / / mm16   L5 = h2 -( t+ ir1 )   / / mm17   r 3 = 150   //mm18   ir2 = r3 - t   // i n n er r a d i u s i n mm19   a lp ha 2 = 1 80   // d e g re e

20   L 6 = a l p ha 2 * 2 * % p i * ( i r2 + k ) / 3 6 0   / / mm21   d l = L 1 + L2 + L 3 + L4 + L 5 + L6   // T ot al d ev el op ed l e ng t h i nmm

22   printf ( ” \n T o t a l d e v e l o p e d l e n g t h = %0 . 2 f mm”   , d l )

23   / / A nswers v ar y d ue t o ro und o f f e r r o r

19

Page 21: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 21/126

20

Page 22: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 22/126

Chapter 4

Cost Estimating

Scilab code Exa 4.1  To calculate total cost and SP

1   clc

2   d _m = 5 50 0   // c o s t o f d i r e c t m a t e r i a l i n Rs3   d _l = 3 00 0   // m a n uf a ct u ri n g w ag es i n Rs4   // f a c t o r y o ve rh ea d i s 1 00% 0 f m a nu fa ct ur in g wa ges5   f _o = ( 10 0* d _ l ) /1 00   // f a c t o r y o ve rh ea ds i n Rs6   F C = d_m + d_l + f_o   // f a c t o r y c o s t i n Rs

7   n m_ o = 1 5* F C / 10 0   / / non−m a n uf a ct u ri n g o v e rh e a d s i nRs

8   t c = FC + nm _o   // t o t a l c os t i n Rs9   p = 1 2* t c /1 00   // p r o f i t i n Rs

10   s p = tc +p   / / s e l l i n g p r i c e i n Rs11   printf ( ” \n T ot al c o s t = Rs %d\n S e l l i n g p r i c e = Rs

%d”   , tc , s p)

Scilab code Exa 4.2  To find selling price

1   clc

2   / / g i ve n

21

Page 23: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 23/126

3   O S_ RM = 2 00 00   // o pe n in g s t o c k o f raw m a t e r i a l s i n

Rs4   C S_ RM = 3 00 00   // c l o s i n g s t o ck o f raw m a t e r i a l s i nRs

5   T P _ RM = 1 7 00 00   // t o t a l p ur ch as e i n y ea r i n Rs6   O S_ FG = 1 00 00   // o pe n in g s t o c k o f f i n i s h e d g o o ds i n

Rs7   C S_ FG = 1 50 00   // c l o s i n g s t o ck o f f i n i s h e d g o o d s i n

Rs8   s a l es = 4 8 95 00   // s a l e s o f f i n i s h e d g o o d s i n Rs9   D _W = 1 20 00 0   // d i r e c t wages i n Rs

10   F _ E1 = 1 20 00 0   // f a c t o r y e xp en se s i n Rs

11   N M_ E = 5 00 00   // non−m a n uf a ct u ri n g e x p e ns e s i n Rs12   DMC = O S_ RM + TP _R M - C S_R M   // d i r e c t m a t e r i a l c o s t13   FC = DMC + D_W + F_E1   // f a c t o r y c o st14   T C = FC + NM_E   // t o t a l c o s t15   FG_S = OS_FG + TC - CS_FG   // c o s t o f f i n i s h e d g o o d s

s o l d i n Rs16   P = sales - FG_S   // p r o f i t i n Rs17   F _E 2 = ( F _E 1 ) / D_ W * 10 0   // f a c t o r y e xp e n s es i n p e rc e n t18   N M_ C = ( N M_ E ) / FC * 1 00   / / non−m a n u f a ct u r i n g e x p e n s e s

t o f a c t o r y c o s t19   P _C = ( P / F G_ S ) * 10 0

  // p r o f i t t o c o st o f s a l e s20   d m = 2 00 00   // d i r e c t m a t e r i a l i n Rs21   d w = 3 00 00   // d i r e c t wages i n Rs22   f e = dw   // f a c t o r y e x p e n se s23   f c = dm + dw + fe   // f a c t o r y c o s t i n Rs24   n m e = N M_ C * fc / 1 00   / / non−m a n uf a ct u ri n g e x p e n se s i n

Rs25   tc = fc + nme   // t o t a l c os t i n Rs26   p = ( P _C * t c ) /1 00   // p r o f i t i n Rs27   s p = tc +p   / / s e l l i n g p r i c e i n Rs28   printf ( ” \n S e l l i n g p r i c e = Rs %d”   , s p )

Scilab code Exa 4.3  To find factory cost

22

Page 24: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 24/126

1   clc

2   d = 3 8   // d i am et e r o f b ar i n mm3   l = 2 5   // l e ng t h o f b ar i n mm4   p = 8.6   / / d e n s i t y gm/ cm ˆ35   g = 9.81   // a c c e l e r a t i o n due t o g r a v i t y i n m/ s ˆ26   w = ( % p i * d ^ 2* l * p * g ) / ( 4 * 1 0^ 6 )   // w ei gh t o f m a t e r i a l

i n N7   m c = w * 1. 62 5   // m a te r ia l c o st i n Rs8   l c = ( 2* 90 ) /6 0   // l ab ou r c o st i n Rs9   f o = 0 .5 * lc   // f a c t o r y o v e rh ea ds i n Rs

10   fc = mc + lc + fo   // f a c t or y c o s t i n Rs11   printf ( ” \n f a c t o r y c o s t = Rs %0 . 2 f ” , f c )

12   / / A nswers v ar y d ue t o ro und o f f e r r o r

Scilab code Exa 4.4  find production cost and time taken

1   clc

2   s p = 65   // s e l l i n g p r i c e i n Rs3   p r o fi t = 0 .2 * s p   // p r o f i t i n Rs4   t c = sp - pro fit   // t o t a l c os t i n Rs

5   P = ( sp - p ro fi t) /1 .4   // p r o d uc t i o n c o s t i n Rs6   D M = 15   // c os t o f d i r e c t m a t e r i a l i n Rs7   W = ( P - DM )/ 1.4   // d i r e c t l ab ou r c o s t i n Rs8   tt = W /2   // t im e t ak en i n h ou rs9   printf ( ” \n Time t a k e n = %0 . 3 f H ou rs ”   , t t )

10   / / A nswers v ar y d ue t o ro und o f f e r r o r

Scilab code Exa 4.5  To find profit

1   clc

2   m p = 60 00   // m arket p r i c e o f ma ch in e i n Rs3   d = 0 .2 * mp   // d i s co u n t i n Rs4   sp = mp - d   // s e l l i n g p r i c e o f f a c t o r y i n Rs

23

Page 25: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 25/126

5   m c = 400   // m a t e r i a l c o s t i n Rs

6   l c = 16 00   // l ab ou r c o st i n Rs7   f o = 800   // f a c t o r y o ve rh ea ds i n R s8   F = m c + l c + f o   // f a c t o r y c o s t i n Rs9   s e = 0. 5* F   // s e l l i n g e x pe n s es i n Rs

10   pro fit = sp - ( F + se )   / / Rs11   printf ( ” \n p r o f i t = Rs %d”   , p ro f it )

Scilab code Exa 4.6  To find lot size and time

1   clc

2   a = 1500   // r e q u i r e m en t s o f c om po ne nt s3   s = 3 0   // c o s t o f e a c h s e t up i n Rs4   k = 0.2   // c ha rg e f a c t o r5   c = 5   // c o s t o f e a c h p ar t i n Rs6   N = 5 * sqrt ( a * s ) / ( k * c )   // e c o n o m i c l o t s i z e7   printf ( ” \n Economic l o t s i z e = %d p i e c e s ” , N )

8   S = ( N* s) /a   // t i m e f o r e a ch s e t up i n h ou rs9   printf ( ” \n Time f o r e ac h s e t up = %0 . 2 f h ou rs ” , S )

10   / / A nswers v ar y d ue t o ro und o f f e r r o r

Scilab code Exa 4.7  To find time to change cutter

1   clc

2   T c = 2   // t im e t ak en by c u t t e r p er c y c l e i n m in ut es3   T k = 10   // t i me t ak en t o c h ang e c u t t e r i n m in ut es4   T = 240   / / t o o l l i f e i n m in ut es5   t = ( Tc * Tk ) /T   // t im e t o c h ang e t he c u t t e r i n min .6   printf ( ” \n U ni t t im e t o c ha ng e t he c u t t e r = %0 . 3 f  

min”   , t )

7   / / E rr or i n t ex tb oo k

24

Page 26: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 26/126

Scilab code Exa 4.8  To find tool change time

1   clc

2   T k = 360   // t i m e t a ke n by t o o l t o c u t b e f o r es h a r p e ni n g i n min .

3   T c = 20   // t i me t ak en t o c h ang e t he t o o l i n min .4   T = 4320   // t i m e t a ke n b e f o r e i t i s d i sc a r d e d i n min

.5   t = ( Tc * Tk ) /T   // t o o l c h a ng e t i m e p er c y c l e i n min .6   printf ( ” \n U ni t t o o l c ha ng e t im e p er c y c l e = %0 . 2 f  

min”   , t )

Scilab code Exa 4.9  To calculate measuring time allowance

1   clc

2   T c = 10   // t i m e t ak e n t o c h ec k h ol e i n s e c s

3   F = 2   // f r eq u e nc y o f c h ec k in g d im en si o n4   t c = Tc *F   // t i m e t a ke n t o c h e c k one p i e c e i n s e c s5   N = 200   // number o f p i e c e s6   Tc = tc *( N + 1)   // T o ta l t i m e i n s e c7   printf ( ” \n T ot al t im e t ak en t o c he ck d i me n si o ns = %d

min”   , T c / 60 )

Scilab code Exa 4.10  To find direct labour cost

1   clc

2   f or gi ng s = 40

3   setup = 4

4   T c = 12   // m ac hi ni ng t im e i n min . p er f o r g i n g

25

Page 27: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 27/126

5   n mt = 21   / / non−m ac hi ni ng i n min . p er f o r g i n g

6   s t = 45   // s e t up t i m e p e r s e t up7   t s = 5   // t o t a l s ha rp en i n g i n min . p er f o r g i n g8   f = 2 0   // f a t i g u e i n p e r ce nt9   f = f / 1 0 0

10   p n = 5   // p e r so n a l n ee ds i n p e rc e n t11   p n = pn / 10 0

12   T k = 10   / / t o o l ch an he t im e i n min .13   T = 8   / / t o o l l i f e i n h ou rs14   c t = 15   // c he ck in g t i m e w i t h 5 c he ck s i n 15 s e c s15   R = 1.4   // p er fo rm a nc e f a c t o r16   dlc = 5   // d i r e c t l ab ou r c o st i n Rs p er hour

17   tt = Tc + nmt   / / m a ch i n in g and non−m ac hi ni ng t im e i nmin .

18   f t = f *tt   / / f a t i g u e t i me i n min .19   p nt = pn * tt   // p e r s o n a l n ee ds i n min .20   t = ( T c * Tk ) / ( T *6 0)   / / t o t a l s h ar p en i ng t ime i n min .

p er f o r g i n g21   m c t = ( t s * ct ) / 60   // m ea su ri ng and c h ec k in g t im e i n

min . p e r f o r g i n g22   su = Tc + nmt + p nt + ft + t + mct   // sum o f t im es i n

min .23   t f = s u * fo r gi n gs

  // t i m e f o r 40 f o r g i n g s i n min .24   t s t = s t * se tu p   / / t o t a l s e t up t i m e i n min .25   Te = tf + tst   // t o t a l e s ti m at e d t i me i n min .26   T a = Te *R   // t o t a l a c t ua l t i me i n min .27   l c = ( T a * dl c ) /6 0   // d i r e c t l ab ou r c o s t i n Rs28   printf ( ” \n D i r e ct l a b ou r c o s t = Rs %0 . 1 f ”   , l c )

Scilab code Exa 4.11  To find machining time

1   clc

2   // f rom f i g u r e 4 . 43   v = 100   // c u t t i n g s pe ed i n m/ min4   D = 5 0   / / mm

26

Page 28: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 28/126

5   l 1 = 76   / / mm

6   f = 7.5   / / f e e d i n mm/ r e v .7   // Case 1 , t im e t o t ur n 38 mm d i am e te r by 76 mml e n g t h o f c u t

8   N 1 = ( 10 0 0* v ) / ( %p i * D) // r . p .m9   t m 1 = l 1 * 10 /( f * N 1 )   // min .

10   // Case 2 , t im e t o t ur n 25 mm by 38 mm l e n g t h11   N 2 = ( 10 0 0* v ) / ( %p i * 38 )   // r . p .m12   l 2 = 38   / / mm13   t m 2 = l 2 * 10 /( f * N 2 )   / / min14   t t = tm1 + tm2   // t o t a l t i me i n min15   printf ( ” \n T o t a l t i m e = %0 . 2 f min . ”   , t t )

Scilab code Exa 4.12  To find time to turn relief 

1   clc

2   // f rom f i g u r e 4 . 53   v = 6 0   // c u t t i n g s pe ed m/ min .4   f = 0. 37 5   / / f e e d i n mm/ r e v5   D = 3 8   / / mm

6   N = ( 1 00 0 *6 0 ) /( % p i *D )   // r e v / min7   l = 3 2   / / mm8   T m = l /( f *N )   / / mi n9   printf ( ” \n Time t o t u r n e x t e r n a l r e l i e f = %0 . 2 f min .

”   , T m )

Scilab code Exa 4.13  calculate time to face on lathe

1   clc2   // from f i g u r e 4 . 1 13   l = 7.5   / / cm4   D av e = ( 25 + 1 0) / 2   // a v er a ge d i am et er i n cm5   v = 2 7   // c u t t i n g s pe ed i n m/ min

27

Page 29: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 29/126

6   f = 0.8   / / f e e d i n mm/ r e v

7   N = ( 1 00 0 * v ) / ( % pi * D a v e * 1 0)   // r . p .m.8   t m = l * 10 /( f * N)   // min .9   printf ( ” \n The m ac hi ni ng t im e t o f a c e on l a t h e = %0

. 2 f min . ”   , t m )

Scilab code Exa 4.14  To find time to drill hole

1   clc

2   D = 12.7   / / d i a me t er i n mm3   d = 5 0   / / d ep th i n mm4   v = 7 5   / / c u t t i n g s p ee d i n m/ min .5   f = 0. 17 5   / / f e e d i n mm/ r e v6   l = d + 2*0. 29* D   // l em gt h o f d r i l l t r a v e l i n mm7   N = ( 10 00 * v ) /( % pi * D )   // r . p .m.8   t m = l /( f *N )   / / mi n9   printf ( ” \n Time t a k e n t o d r i l l h o l e = %0 . 3 f min . ”   ,

tm )

Scilab code Exa 4.15  To find time to complete cut

1   clc

2   k = 1/4   // r e t u r n t i m e t o c u t t i n g r a t i o3   l = 900 + 2*75   // l e ng t h o f s t r o k e i n mm4   v = 6   // c u t t i n g s t r o k e i n m/ min5   f = 2   / / f e e d mm/ s t r o k e6   w = 600   / / b r ea d th i n mm7   N = ( v * 10 00 ) / ( l *1 . 25 )   // r . p .m

8   N =   round ( N )9   time = w /( f* N)   / / min

10   printf ( ” \n Time r e q ui r e d f o r s ha pe r t o c om pl et e onec u t = % d m i n ”   , t im e )

28

Page 30: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 30/126

Scilab code Exa 4.16  To find time to broach

1   clc

2   l = 7 0   // l e n g t h o f s t r o k e i n cm3   c s = 11   // c u t t i n g s pe ed i n m/ min4   r s = 24   // r e t u r n s p ee d i n m/ min5   t m = ( l / (1 00 * c s )) + ( l / (1 0 0* r s ) )   / / min6   printf ( ” \n Time t ak en t o b ro ac h a f o u r s p l i n e b r as s

= %0 . 4 f m in ”   , t m )

7   / / A nswers v ar y d ue t o ro und o f f e r r o r

Scilab code Exa 4.17  find feed cutter travel and time

1   clc

2   v = 5 0   // c u t t i n g s pe ed i n m/ min3   D = 150   // d i a me te r o f f a c e c u t t e r i n mm

4   N = ( 10 00 * v ) /( % pi * D )   // r . p .m.5   f = 0.25   / / f e e d mm/ t o o t h6   n = 1 0   // n umber o f t o o t h7   t f = N *f *n   // t a b l e f e e d i n mm/ min8   l = 200   // l e ng t h o f work p i e c e i n mm9   d = 2 5   // de pt h o f s l o t i n mm

10   t ot =   sqrt ( D* d - d ^2)   // t o t a l o v e r t r a v e l i n mm11   tct = l + tot   // t o t a l c u t t e r t r a v e l i n mm12   t im e = t ct / tf   // min .13   printf ( ” \n T abl e f e e d = %d mm/min .   \n T ot al c u t t e r

t r a v e l = %0 . 1 f mm\n Time r e q u i r e d t o m ac hi ne t h e

s l o t = %0 . 3 f min . ”   , tf , tct , time )

29

Page 31: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 31/126

Scilab code Exa 4.18  To find cutting time

1   clc

2   D = 63.5   // d ia me te r o f p l a i n m i l l i n g c u t t e r i n mm3   w = 3 0   // w id th o f b l o ck i n mm4   l = 180   // l e ng t h o f b l o c k i n mm5   f = 0. 12 5   / / f e e d i n mm/ t o o t h6   n = 6   // no . o f t e e t h7   N = 1500   // s p i n d l e s pe ed i n r . p .m8   tot = ( D -   sqrt ( D ^2 - w ^ 2) ) /2   // t o t a l o v e r t r a v e l

i n mm9   tct = l + tot   // t o t a l c u t t e r t r a v e l i n mm

10   T m = t ct / ( f *n * N )   // c u t t i n g t i me i n min11   printf ( ” C u t t i n g t i m e = %0 . 3 f min . ”   , T m )

12   / / A nswers v ar y d ue t o ro und o f f e r r o r

Scilab code Exa 4.19   To find milling time

1   clc

2   // from f i g u r e 4 . 1 7

3   d = 1 9   // d ep th o f c ut i n mm4   D 1 = 5   // d i am et e r o f ro un d b ar i n cm5   v = 5 0   // c u t t i n g s pe ed i n m/ min6   n = 8   // number o f t e e t h7   f = 0.2   / / f e e d i n mm/ t o o t h8   l = 2 * sqrt ( d *D1 * 10 - d ^ 2)   // l e ng t h o f c ho rd i n mm9   D 2 = 10   // d ai me te r o f c u t t e r i n cm

10   o v e rr u n =   sqrt ( D 2 * 1 0* d + D 1 * 1 0 * d - d ^ 2) -   sqrt ( D 1 * 1 0 * d - d

^2) // mm11   t t = l + ov erru n   // t a b l e t r a v e l i n mm

12   N = ( 10 00 * v ) /( % pi * D 2 * 10 )   // r . p .m13   t m = t t /( f *n * N)   / / t im e i n min .14   printf ( ” \n The m i l l i n g t i me = %0 . 2 f min . ”   , t m )

30

Page 32: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 32/126

Scilab code Exa 4.20  To find time to grind shaft

1   clc

2   w = 5 0   // w id th o f g r i n d i n g wheep i n mm3   f = w /2   // f e e d i n mm4   t = 0.25   // t o a t a l s t oc k i n mm5   d = 0. 02 5   // d ep th o f c ut i n mm6   n = t / d   // number o f c u t s7   v = 1 5   // c u t t i n g s pe ed i n m/ min8   D = 3 8   / / d i a me t e r i n mm9   N = ( 10 00 * v ) /( % pi * D )   // r . p .m.

10   l = 200   // l e ng t h o f p ar t i n mm11   T m = ( l * 10 ) /( f * N )   // min .12   printf ( ” Time r e q u i r e d t o g r i nd t he s h a f t = %0 . 2 f min

. ”   , T m )

Scilab code Exa 4.21  To find time to cut threads

1   clc

2   v = 6   // c u t t i n g s pe ed i n m/ min3   n = 5   // number o f c u t s4   D = 4 4   / / d i a me t e r i n mm5   N = ( 10 00 * v ) /( % pi * D )   // r . p .m6   f = 0.5   // f e e d i n cm7   l = 8.9   // l e n g th o f c u t i n cm8   T m = ( l *n ) /( f *N )   // t im e i n min9   printf ( ” \n Time t o c u t t h e t h r e a d s = %0 . 2 f min ”   , Tm

)10   / / A nswers v ar y d ue t o ro und o f f e r r o r

31

Page 33: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 33/126

Scilab code Exa 4.22  find time to produce one piece

1   clc

2   v t = 40   // c u t t in g s pe ed f o r t u rn i ng i n m/ min3   v s = 8   // c u tt i n g s p ee d f o r c u t t i ng and k n u r li n g i n

m/min4   f t = 0.4   / / f e e d f o r t u r ni n g i n mm/ r e v .5   f f = 0.2   // f e e d f o r f or m in g i n mm/ r e v6   d 1 = 25   / / d i a m et e r i n mm7   l 1 = 50   / / mm8   N 1 = 1 00 0* v t / ( %p i * d1 )   / / s p i n d l e s p ee d i n r e v . / min .9   t im e1 = l 1 /( f t * N1 )   // min .

10   t t = 2* t im e1   / / t o t a l t im e i n min .11   d 2 = 15   / / mm12   N 2 = 1 00 0* v t / ( %p i * d2 ) / / r e v / m in .13   l 2 = 30   / / mm14   t im e2 = l 2 /( f t * N2 )   // min .15   e ft = 0 .1 5   / / end f o rm i n g t im e i n min .16   d 3 = 10   / / mm17   N 3 = 1 00 0* v s / ( %p i * d3 )   // r e v . / min .18   l 3 = 15   / / mm19   f = 1.5   / / f e e d i n min .20   t i m e3 = l 3 /( f * N3 )

  // min .21   N 4 = 1 00 0* v s / ( %p i * d1 )   // r e v . / min .22   l 4 = 10   / / mm23   t im e4 = l 4 /( f t * N4 )   // min .24   t im e5 = 0 .1 5   // t im e f o r c h am f er i ng i n min .25   D a ve = d 1 /2   / / mm26   N 5 = 1 00 0* v t / ( %p i * D av e )   // r . p .m.27   t im e6 = D av e / ( N5 * f f )   // min ,28   t m t = t t + t i me 2 + t i m e 3 + t i me 4 + t i m e5 + t i m e 6 + e f t   // t o t a l

m a ch i ni n g t i me i n min .29   t = 0.05   // min .

30   h t = t im e5 + 6 * t im e6 + 4 * t +3 * t   / / h a nd l in g t im e i n min .31   t o t = ht + tm t   // t o t a l h a nd l i ng t i me i n min .32   c t = 1 5* t o t / 10 0   / / c o n t i n g en c y i n min .33   t c t = t ot + ct   / / t o t a l c y c l e t i m e i n min .34   s t = 60   // s e t up t i m e f o r t u r r e t l a th e

32

Page 34: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 34/126

35   p = 100   // t o t a l p i e c e s

36   s tp = st / p   // s e t up t i me p er p i e c e i n min .37   t pt = t ct + st p   // T ot al p r o d uc ti o n t im r p er p i e c e i nmin .

38   printf ( ” \n T ot al p r o du c ti o n t im r p er p i e c e = %0 . 2 f  min”   , tpt )

39   / / An swers v ar y due t o ro un d o f f e r r o r

33

Page 35: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 35/126

Chapter 5

Economics of tooling

Scilab code Exa 5.1  To find value of machine tool

1   clc

2   C o = 2 50 00 0   // o r i g i n a l v al ue o f machi ne t o o l i n Rs3   C s = 2 50 00   // s a l v a ge v al ue i n Rs4   n = 2 0   // u s e f u l l i f e i n y e a rs5   d = ( Co - C s) / n   // d e p r e c i a t i o n p er y e ar i n Rs6   v 1 = Co - 10* d   // v al ue o f machi ne t o o l a t t he end

o f 10 y ea r s i n Rs7   s = C o - C s   / / sum a t t he end o f u s e f u l l i f e i n Rs8   i = 8/ 10 0   // a n nu a l i n t e r s t r a t e9   D = ( s* i ) /( (1 + i ) ^n - 1)   // a nn ua l d e p o s i t

10   a = D * (( 1+ i )^ 10 - 1) / i   // amount a t t h e end o f 1 0y e ar s i n Rs

11   v2 = Co - a   // v al ue a t t h e e nd o f 10 y ea r s12   printf ( ” \n V al ue o f machi ne a t t he end o f 10 y e ar s

t hr ou gh s t r a i g h t l i n e d e p r e c i a t i o n method = Rs %d”   , v 1 )

13   printf ( ” \n V al ue o f machi ne a t t he end o f 10 y e ar st h ro u g h s i n k i n g f un d meth od = Rs %d”   , v 2 )

14   / / A nswers v ar y d ue t o ro und o f f e r r o r

34

Page 36: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 36/126

Scilab code Exa 5.2  To find annual investment

1   clc

2   p = 2 00 00 0   // p r e s e n t wor th i n Rs3   i = 1 0   // a n nu a l i n t e r e s t r a te4   i = 1 0/ 10 0

5   n = 2 0   // number o f y e a r s6   a 1 = ( p * i) / ( (1 + i ) ^n - 1)   // a nn ua l i n ve s tm e nt u s i ng

s i n k i n g f un d f a c t o r i n Rs7   a 2 = ( p * i * ( i + 1) ^ n ) / ( ( i + 1) ^ n - 1 ) / / a n nu a l i n v es t m en t

u si ng c a p i t a l r ec ov e r y f a c t o r i n Rs8   printf ( ” \ nAnnua l i n v e s t me n t u s i n g s i n k i n g f un d

f a c t o r = R s % d /−   pe r y ea r ”   , a 1 )

9   printf ( ” \ nAnnual i n ve st m en t u s i ng c a p i t a l r e c o ve r yf a c t o r = R s % d /−   pe r y ea r ”   , a 2 )

10   / / A nswers v ar y d ue t o ro und o f f e r r o r

Scilab code Exa 5.3  find project is economical or not

1   clc

2   // c as h i n f l o w s3   a = 21 24 0   // a nn ua l r ev en u e i n Rs4   i = 1 0   // a n nu a l i n t e r e s t r a te5   i = 1 0/ 10 0

6   n = 5   // p er od i n y e a r s7   f 1 = 80 00   // s a l v a ge v al ue i n Rs8   p 1 = ( a * (( i + 1) ^ n - 1) ) / ( i *( i + 1) ^ 5 ) / / a n nu a l r e ve n ue

i n Rs9   p 2 = f 1 /( i +1 ) ^5   / / p r e s e n t w or th i n Rs

10   t1 = p1 + p2   // t o t a l c a s h i n f l o w s i n Rs11   // c as h o ut f l o w s12   I = 40 00 0   // i n ve s tm e nt i n Rs

35

Page 37: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 37/126

13   f 2 = 1 20 00   // a n n ua l p aymen t i n Rs

14   p 3 = ( f 2 * ( ( 1+ i ) ^ 5 - 1 ) ) / ( i * (1 + i ) ^ 5 )   // a n n u a l p ay me nt si n Rs15   t 2 = I + p3   // t o t a l c a s h ou t f l o w s i n Rs16   printf ( ” \ n To ta l c as h i n f l o w s = Rs %0 . 2 f   \ n T o ta l c a s h

o u t f l o w s = Rs %0 . 2 f ” , t1 , t2 )

17   disp ( ” S i n ce c as h o ut f l o ws a r e more t ha n c as h i nf l ow s t h e r e f o r e p r o j e c t i s no t e co no mi ca l ”)

18   / / A nswers v ar y d ue t o ro und o f f e r r o r

Scilab code Exa 5.4   selection of economical machine

1   clc

2   / / M a c h i n e A3   f 1 = 20 00   // a nn ua l b e n e f i t from b e t t e r p r o d uc ti o n

q u a l i t y i n Rs4   i = 1 0   // i n t e r e s t r a t e5   i = 1 0/ 10 0

6   f 2 = 1 20 00   // s a l v a ge v al ue i n Rs7   f 3 = 80 00   // o p e r a t i n g and m ai nt en an ce c o s t i n Rs

8   I 1 = 1 00 00 0   / / i n i t i a l c o s t i n Rs9   n = 5   // y e ar s

10   p 1 = ( f 1 * ( ( 1+ i ) ^ n - 1 ) ) / ( i *( i + 1 ) ^ n )

11   p 2 = f 2 /( 1+ i ) ^n

12   c1 = p1 + p2   // c a s h i n f l o w s i n Rs13   p 3 = ( f 3 * ( ( 1+ i ) ^ n - 1 ) ) / ( i *( i + 1 ) ^ n )

14   c2 = I1 + p3   // c a sh ou t f l ow s i n Rs15   Pa = c1 - c 2   / / n e t P .W. i n Rs16   / / M a c h i n e B17   I 2 = 6 00 00   / / i n i t i a l c o s t i n Rs

18   f 4 = 1 60 00   // o p e r a t i ng and m ai nt en an ce c o s t i n Rs19   f 5 = 1 40 00   // r e c o n d i t i o n i n g a t t he end o f t h i r dy ea r i n Rs

20   p 4 = ( 1 6 00 0 * ( (1 + i ) ^ 5 - 1 ) ) / ( i * (1 + i ) ^ 5 )

21   p 5 = f 5 /( 1+ i ) ^5

36

Page 38: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 38/126

22   Pb = - I2 - p4 - p5   / / n e t P .W. i n Rs

23   printf ( ” \n N et P .W. of M ac hi ne A= R s %0. 2 f   \n N et P .W.o f M a ch i ne B = Rs%0 . 2 f ”   , Pa , Pb )

24   disp ( ” I t i s c l e a r t ha t Net P .W o f Machine A i s l e s sn a g a t iv e a s compared t o t h at o f Machine B ,t h e r e f o r e Ma ch in e A i s e co no mc al . ” )

25   / / A nswers v ar y d ue t o ro und o f f e r r o r

Scilab code Exa 5.5   selection of machine

1   clc

2   / / m a c h i n e A3   c 1 = 2 00 00   // manual c o s t i n Rs4   c 2 = 4 00 00   // o p er a ti n g c o st i n Rs5   n 1 = 2   / / m ac hi ne l i f e i n y e a r s6   i = 1 0   // i n t e r e s t r a t e7   i = 1 0/ 10 0

8   c r f 1 = ( ( 1+ i ) ^ n 1 - 1 ) / ( i *( i + 1 ) ^ n 1 )   // c a p i t a l r e c o v e r yf a c t o r

9   p w 1 = c 1 + c2 * c r f1   // p r e s e nt worth i n Rs

10   / / m ac hi ne B11   c 3 = 5 00 00   // manual c o s t i n Rs12   c 4 = 3 00 00   // o p er a ti n g c o st i n Rs13   n 2 = 4   / / m ac hi ne l i f e i n y e a r s14   i = 1 0/ 10 0   // i n t e r e s t r a t e15   c r f 2 = ( ( 1+ i ) ^ n 2 - 1 ) / ( i *( i + 1 ) ^ n 2 )   // c a p i t a l r e c o v e r y

f a c t o r16   p w 2 = c 3 + c4 * c r f2   // p r e s e n t worth i n Rs f o r 4 y e a r s17   p w3 = ( p w2 * c r f1 ) / c rf 2   // p r e s e n t worth i n Rs f o r 2

y e a r s

18   printf ( ” \n P .W. o f e x pe n se s f o r A = Rs %d\n P .W. o f  e x p e n s e s f o r B = Rs %0 . 2 f ”   , p w 1 , p w 3 )

19   disp ( ”As t h e e xp en se s o f machi ne B a re l e s s , s ot h i s i s e co no mi ca l ”)

20   / / A nswers v ar y d ue t o ro und o f f e r r o r

37

Page 39: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 39/126

Scilab code Exa 5.6   selection of economical machine

1   clc

2   / / M a c h i n e A3   i = 8   // / / i n t e r e s t r a t e4   i = i / 1 0 0   // i n t e r e s t r at e5   n 1 = 10   / / e co no mi c l i f e i n y e a r s6   C R F 1 = i * ( 1 + 0 .0 8 ) ^ n 1 / ( ( 1+ i ) ^ n 1 - 1 )   // c a p i t a l

r e co v e r y f a c t o r7   p 1 = 4 60 00   // f i r s t c o s t i n Rs8   s 1 = 80 00   // s a l v a ge v al ue i n Rs9   o 1 = 1 00 00   // o p e r a t i n g c h ar g es i n Rs

10   AC1 = ( p1 - s1 )* CR F1 + s1 * i + o1   // a nn ua l c o s t i n Rs11   / / M a c h i n e B12   n 2 = 15   / / e co no mi c l i f e i n y e a r s13   C R F 2 = i * ( 1 + 0 .0 8 ) ^ n 2 / ( ( 1+ i ) ^ n 2 - 1 )   // c a p i t a l

r e co v e r y f a c t o r14   p 2 = 6 00 00   // f i r s t c o s t i n Rs15   s 2 = 1 00 00   // s a l v a ge v al ue i n Rs16   o 2 = 92 00   // o p e ra t i ng c ha r ge s i n Rs17   AC2 = ( p2 - s2 )* CR F2 + s2 * i + o2   // a nn ua l c o s t i n Rs18   printf ( ” \n Annu al c o s t o f m ac hi ne A = Rs %0 . 2 f   \n

An nu al c o s t o f M ac hi ne B = R s %0 . 2 f ”   , AC1 , A C2 )

19   disp ( ” Machine B w i l l be e c on o mi c al ” )

20   / / E rr or i n t ex tb oo k

Scilab code Exa 5.7 find ERR and economicality of project

1   clc

2   a = 1 00 00 0   / / E j ( p / f , e% , j ) i n Rs3   n = 5   // l i f e i n y e ar s

38

Page 40: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 40/126

4   e = 2 0   / / M . A . R . R .

5   e = e / 1 0 0   / / M . A . R . R .6   i = e

7   A = 32 00 0   // s a v i n gs i n Rs8   s = 20 00 0   // s a l v a ge v al ue i n Rs9   b = ( ( A * ( (( i + 1 ) ^ n ) - 1 ) / i ) +s ) / a   / / ( F/ p , I , 5 )

10   i 2 = ( b ) ^( 1/ n ) -1   // i n t e r n a l r a t e o f r e t ur n11   printf ( ” \n ERR = %0.4 f   \n I n t e r n a l r a t e o f r et ur n =

%0 . 2 f p e r c e n t ”   , b , i 2 * 1 0 0 )

12   disp ( ” S i n ce I n t e r n a l r a t e o f r et ur n i s   >   M. A . R . R ,t h e r e f o r e p r o j e c t i s f e a s i b l e ” )

Scilab code Exa 5.9  find ERR and economicality of project

1   clc

2   e = 2 0   // M , A . R . R .3   i = e   // i n t e r e s t r s t e4   i = i / 1 0 0

5   n = 5   // l i f e i n y e ar s6   s = 32 00 0   // a nn ua l n et s a v i n g s i n R s

7   p = 1 00 00 0   // p r e s e n t wor th i n Rs8   S = 20 00 0   // s a l v a ge v al ue i n Rs9   a = ( p - S) * ( i /( (1 + i ) ^n - 1 ) )   / / ( p−s ) (A/F , e% , n )

10   E = (s - a) /p   / / E . R . R . R11   printf ( ” \n ERRR = %0. 2 f pe r c e n t ” , E * 1 00 )

12   disp ( ” S i n c e E . R . R . R i s   >   M. A. R. R. t h e r e f o r e p r o j e c ti s f e a s i b l e . ” )

Scilab code Exa 5.10  To determine acceptance of machine

1   clc

2   / / m ac hi ne A3   r _e 1 = 9 60 0   / / c as h f l o w i n Rs

39

Page 41: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 41/126

4   p 1 = 4 60 00   / / i n t i a l c o s t i n Rs

5   s = 0   // s a l v a g e v al u e6   e = 8   / / M . A . R . R7   e = e / 1 0 0

8   i = 8   // i n ve s tm e nt r a t e9   i = i / 1 0 0

10   n = 6   // l i f e i n y e ar s11   x = i / ( (1 + i ) ^n - 1)

12   E RR R1 = ( r _e 1 - ( p1 - s )* x )/ p1

13   / / m a c h i n e B14   r _e 2 = 7 20 0   / / c as h f l o w i n Rs15   p 2 = 3 20 00   / / i n t i a l c o s t i n Rs

16   E RR R2 = ( r _e 2 - ( p2 - s )* x )/ p217   printf ( ” \n ERRR1 = %0. 2 f pe r c e n t   \n ERRR2 = %0 . 2 f 

p e r c e n t ”   , E RR R1 * 1 00 , E RR R2 * 1 0 0)

18   disp ( ” Only m ac hi ne B i s a c c e p t e b l e ” )

Scilab code Exa 5.11  find investment cost and unamortized value

1   clc

2   p m v = 1 50 00   // p r e s e nt m arket v a lu e i n Rs3   s s = 60 00   // sum n eed ed t o make i t s e r v i c e a b l e i n Rs4   ic = ss + pmv   // i nv es tm en t c o st i n Rs5   p b v = 3 00 00   // p r e s e nt book v al ue i n Rs6   s v = 1 50 00   // s a l v a ge v al ue i n Rs7   ui = pbv - sv   // u n am o rt i ze d i n v es t m en t i n Rs8   printf ( ” \n I n ve s tm e nt c o s t = Rs %d\n U n a m o r ti z e d

i n v e s t m e n t = R s % d ”   , ic , ui )

Scilab code Exa 5.13  To make decision of machines replacement

1   clc

2   / / E x i s t i n g m ac hi ne

40

Page 42: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 42/126

3   p mp = 1 00 00 0   // p r e s e n t market p r i c e i n Rs

4   i o = 5 00 00   // i mm ed ia te o v e r h a ul i n g i n Rs5   asl = 5   / / a d d i t i o n a l s e r v i c e l i f e i n y ea r s6   a o c = 5 00 00   // a nn ua l o p e ra t i ng c o s t i n Rs7   s v o = 1 00 00   // s a l v a ge v al ue a f t e r o v e r h a u l in g i n Rs8   pc = io + pmp   // p r e s e n t c o st i n Rs9   i = 1 0   // i n t e r e s t r a t e

10   i = 1 0/ 10 0

11   c rf 1 = ( i * (1 + i ) ^ as l ) / (( 1+ i ) ^ a sl - 1 )   // c a p i t a lr e co v e r y f a c t o r

12   AC1 = ( pc - svo ) * cr f1 + svo * i + aoc   // a v e ra ge c o s ti n Rs

13   / / p r o p os e d m ac hi ne14   n = 1 0   / / e x p ec t e d e co no mi c l i f e i n y e a r s15   i c = 3 00 00 0   / / i n i t i a l c o s t i n Rs16   s v = 1 00 00 0   // s a l v a ge v al ue i n Rs17   o = 30 00 0   // a nn ua l o p e ra t i ng c o s t i n Rs18   c rf 2 = ( i * (1 + i ) ^1 0) / ( (1 + i ) ^1 0 - 1 )

19   A C 2 = ( i c - s v ) * c r f 2 + s v * i + o   // a ve ra ge c o st i nRs

20   printf ( ” E x i s t i n g m ac hi ne = Rs %0 . 3 f    \n P r op o se dmac hi ne = Rs %0. 2 f ”   , AC1 , AC2 )

21   disp (” S i n ce t he e q u i v a l e n t a nn ua l c o s t o f p ro po se dmachi ne i s l e s s than t ha t o f t h e e x i s t i n g machine

, t h e r e f o r e , t h e r e p l a c e m e n t i s j u s t i f i e d . ” )

22   / / A nswers v ar y d ue t o ro und o f f e r r o r

Scilab code Exa 5.15   Determine economic repair life

1   clc

2   c = 20 00 0   // f i r s t c o s t o f ma ch in e i n Rs3   s = 1000   // s c r a p v al ue i n machi ne i n Rs4   b = 180   // a n n u a l i n c r e a s e i n c o s t o f r e p a i r s i n Rs5   n =   sqrt ( 2 * ( c - s ) / b )   // y e a rs6   printf ( ” \n Number o f y e a rs o f e co no mi c r e p a i r l i f e =

41

Page 43: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 43/126

%0 . 2 f y e a r s ”   , n )

Scilab code Exa 5.16  find time to pay for itself 

1   clc

2   C n = 7 20 00   // c o s t o f new m achine i n s t a l l e d andt o ol e d i n Rs

3   C o = 2 80 00   // c o s t o f new machime i n s t a l l e d andt o ol e d i n Rs

4   p = 1 6   // h ou rl y p i e c e s5   N n = 2 20 0* p   // e s t i m a t ed a n nu a l p r o d u c ti o n on new

mac hi ne6   K o = 1 72 00   // p r e s e n t book v al u e o f o l d machi ne i n

Rs7   S o = 64 00   // s c ra p v al u e o f o l d machi ne i n R s8   S n = 80 00   // p r o ba bl e s c r a p v al ue o f o l d machine i n

a t t h e end o f i t s u s e f u l l i f e Rs9   o co = 2.5   // o p r e a t o r c o s t p er hour

10   m c o = 4 8   // m ac hi ne c o s t11   r o = 10   // p r od u ct i o n r a t e p er hour

12   ocn = 2   // o p r e a t o r c o s t p er hour13   m c n = 6 2   // m ac hi ne c o s t14   r n = 16   // p r od u ct i o n r a t e p er hour15   P o = ( o co + m co ) / r o   // l a b ou r and m ach ine c o s t p er

u n i t on o l d ma ch in e i n Rs16   P n = ( o cn + m cn ) / r n   // l a b ou r and m ach ine c o s t p er

u n i t on new m ac hi ne i n Rs17   i = 6   // i n t e r e s t on i nv es tm en t18   i = i / 1 0 0

19   t = 6   // a nn ua l t a x es

20   t = t / 1 0 021   d = 1 0   // a nn ua l a l lo w a n ce f o r d e p r e c i a t i o n22   d = d / 1 0 0

23   m = 3   // a nn ua l a l l o wa n c e f o r m ai nt en an ce24   m = m / 1 0 0

42

Page 44: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 44/126

25   n = ( ( Cn - S n ) +( Ko - S o ) ) /( ( Nn * ( Po - P n ) ) - C n *( i + t +d + m ))

26   printf ( ” \n The n umber o f y e a r s i n w hi ch t h e newm ac hi ne w i l l p ay f o r i t s e l f = %0 . 3 f y e a r s ”   , n )

Scilab code Exa 5.17  selection of machine for job

1   clc

2   C = 80 00 0   // c o s t o f new m achi ne i n s t a l l e d andt o ol e d i n Rs

3   nel = 2   // number o f e n g in e l a t h e s4   c = 3 20 00 * ne l   // f i r s t c o s t o f e ng i ne l a t h e5   N = 4000   // a n n ua l p r o du ct io n o f t u r r e t l a t h e6   n = 3800   // a nn ua l p r od u ct i o n i n e ng i ne l a t h e7   n hp1 = 4   / / hp m ot or8   L = 2 25 6* n hp 1   // a n n ua l l ab ou r c o st o f t u r r e t l a t h e9   w = 5   // wage i n p er h ou r

10   t im e = 2 30 0   // h o ur s11   l = t im e * ne l *w   // l ab ou r c o st o f e ng i n e l a t h e12   n h p2 = 2 .5   / / hp m ot or13   p r = 0. 35   // power r a t e i n kwh

14   p = ( n e l * n hp 2 * 7 4 6 * t i me * p r ) / 1 0 00   // p ower c o s t15   P = ( n h p1 * 7 46 * t i m e * p r ) / 1 00 0   // po we r c o s t16   F = 480   / / s a v i n g17   I = 6/100   // i n t e r e s t r a t e18   T = 4/ 10 0   // t a x r a t e19   D = 1 0/ 10 0   // a l l ow an c e f o r d e p r e c i a t i o n i n e ng in e

l a t h e20   M = 6/ 10 0   // a l l o wa n c e f o r m ai nt en an ce i n e n gi n e

l a t h e21   B = 5 5/ 10 0   // l a bo ur burden i n e ng i ne l a t h e

22   i = 6/100   // i n t e r e s t r a t e23   t = 4/ 10 0   // t a x r a t e24   d = 1 0/ 10 0   // a l l ow an c e f o r d e p r e c i a t i o n i n t u r r e t

l a t h e25   m = 6/ 10 0   // a l lo w a n ce f o r m ai nt en an ce i n t u r r e t

43

Page 45: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 45/126

l a t h e

26   X = ( L + B *L + P + C*( I+ T+ D+ M) - F )/ N27   x = ( l+ l* B + p + c *( i+ t+ d+ m) )/ n

28   printf ( ” \n U ni t p r o du ct io n c o st on t u r r e t l a t he = Rs%0 . 2 f p er p i e c e \n U ni t p r od u ct i o n c o s t on e ng i nel a t h e = Rs %0 . 2 f p e r p i e c e ”   , X , x )

29   disp ( ” T u rr et l a t h e w i l l be m ore e c on o mi c al th an twoe n gi n e l a t h e ” )

30   / / A nswers v ar y d ue t o ro und o f f e r r o r

Scilab code Exa 5.18  Calculate maximum investment on turret lathe

1   clc

2   X = 9.16   // p ro du ct io n c o st on t u r r e t l a t h e3   N = 4000   // a nn u al r e q u ir e m e nt4   c = X * N   // c os t f o r 4 000 p i e c e s on t u r r e t l a t h e5   n = 3800   // p r o d uc t i o n o f e ng i ne l a t h e6   l = 23 00 0   // l a bo u r c o s t7   p = 3002   // p ower c o s t8   i = 6   // i n t e r e s t r a t e

9   i = i / 1 0 010   t = 4   // t a x r a t e11   t = t / 1 0 0

12   d = 1 0   // a ll ow an ce f o r d e p r e c i a t i o n i n t u r r e t l a t h e13   d = d / 1 0 0

14   m = 6   // a l lo w an c e f o r m ai nt en an ce i n t u r r e t l a t h e15   m = m / 1 0 0

16   b = 5 5/ 10 0   / / l a b o u r b u rd e n17   a = i +t +d +m

18   t c = 6 40 00   // f i r s t c o s t o f e ng i ne l a t h e

19   c 1 = ( N *( l * ( 1 + b ) + p ) ) /n + ( t c * a )   // c o s t f o r e ng in el a t h e20   s = c1 - c   // s a v i n g s21   amt = s /a   // a mount i n v e st e d i n t u r r e t l a t h e o ve r

t h e c os t o f e ng in e l a th e

44

Page 46: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 46/126

22   printf ( ” \n Amount i n v e s t e d i n t u r r e t l a t h e o ve r t he

c o s t o f e ng i ne l a t h e = Rs %d”   , amt )23   / / A nswers v ar y d ue t o ro und o f f e r r o r

Scilab code Exa 5.19  To find years for new machine

1   clc

2   C n = 6 00 00   // c o s t o f new ma ch in e3   S n = 50 00   // s c r ap v a lu e o f new m ach ine

4   S o = 10 00   // s c ra p v al u e o f o l d machi ne5   N n = 2 00 00 0   // a n n u al p r o d u c t io n6   I = 1 0   // i n t e r e s t r a t e7   I = I / 1 0 0

8   M = 7   // a l l ow a n ce f o r m ai nt en an e9   M = M / 1 0 0

10   T = 6   // a nn ua l t a x es11   T = T / 1 0 0

12   D = 1/10   // a l l ow an ce f o r d e p r e c i a t i o n13   l co = 300   // l a bo u r c h ar g es f o r o l d machi ne14   m = 1 2   / / m on th s

15   r c o = 1 50 00   // r un ni ng c h a r ge s f o r o l d ma ch in e16   p r o = 5 00 00   // p r o d uc t i o n r a t e f o r o l d machine17   l cn = 500   // l a b ou r c h a rg e s f o r new ma ch in e18   r c n = 1 00 00   // r un ni ng c h a r ge s f o r o l d ma ch in e19   p rn = 2 00 00 0 // p ro du ct i o n r a te f  20   Po = ( lco * m + rco ) /pro   // l a b ou r and m ach ine c o s t on

o l d m ac hi ne21   Pn = ( lcn * m + rcn ) /prn   // l a b ou r and m ach ine c o s t on

new mac hi ne22   n = (( C n - S n ) - S o ) / (( N n * ( Po - P n ) ) - C n * ( I + T + D +M ) )   / / y e a r s

23   printf ( ” \n Y ea rs i n wh ich new m ach ine w i l l pay f o ri t s e l f = %0. 2 f y e ar s ”   , n )

45

Page 47: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 47/126

Scilab code Exa 5.20  To find cost and pieces

1   clc

2   a = 1.50   / / s a v i ng i n l a b ou r3   b = 5 5 / 1 0 0   // b ur de n a p p l i e d on l a b ou r4   T = 4/ 10 0   // a l lo w a n ce f o r t a xe s5   M = 5/ 10 0   // a l l o wa n c e f o r m ai nt en an ce6   I = 8/ 10 0   // i n t e r e s t r at e7   D = 5 0/ 10 0   // a l l ow an c e f o r d e p r e c i a t i o n8   H = 2   // y e ar s t o a mo r t i z e t he i nv es tm en t9   S = 5 0   // y e a r l y c o s t f o r s e t up

10   C = 3000   / / f i r s t c o s t

11   N 1 = ( C * ( I + T + M +D ) + S ) / ( a * (1 + b ) )   // a n nu al p r o d u c t io nwhen 1 r un i s made

12   r = 5   // number o f r u n s13   N 2 = ( C * ( I + T + M +D ) + S * r ) /( a * ( 1 + b ) )   // a n n ua l

p r o d u c ti o n when 1 r un i s made14   D 1 = 1 00 /1 00   // a l l ow an c e f o r d e p r e c i a t i o n15   N 3 = ( C * ( I + T + M + D1 ) + S ) / ( a * (1 + b ) )   / / p r o d u c ti o n when D

= 1 0 016   n 1 = 15 30   // p i e c e s17   C 1 = ( n 1 * ( a * (1 + b ) ) - S ) /( I + T + M + D 1 )   // e c o n om i c a l

i n v e s t m e n t18   n 2 = 950   // p i e c e s19   a 1 = 2   // l a bo u r c o s t20   r 1 = 6   // number o f r u n s21   S 1 = r1 *S   // y e ar l y c o st22   V = n 2 * a 1 * (1 + b ) - C * ( I + T +M + D ) - S 1   // p r o f i t23   printf ( ” \n Number o f p i e c e s when o ne r un i s made and

c o s t i s Rs 3 00 0 = %d p i e c e s ” , N 1 )

24   printf ( ” \n Annu al p r o d u c ti o n when 5 r u ns a r e madep e r y e a r = %d p i e c e s ”   , N 2 )

25   printf ( ” \ nAnnua l p r o d u c ti o n when f i x t u r e pay f o r

i t s e l f = %d p i e c e s ”   , N 3 )26   printf ( ” \ n Ec on om ic al i n v es t m en t when 1 53 0 p i e c e s f o r

s i n g l e run w i t h s a vi n gs Rs 1 . 5 0 p er p i e c e = Rs%d” , C 1 )

27   printf ( ” \ nAnnua l p r o f i t when 9 50 p i e c e s made p e r

46

Page 48: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 48/126

y ea r i n 6 r un s a nd s av i n g i n l ab ou r c o st Rs 2 p e r

p i e c e = Rs %d p er y ea r ”   , V )28   / / ’ Answers v a ry due t o round o f f e r ro r ’

Scilab code Exa 5.21  To find number of components

1   clc

2   a = 0. 12 5   // s a vi n g i n l a bo u r c o s t p er u n it3   b = 0.4   // o ve rh ea d a p p l i e d on d i r e c t l a bo u r s av ed

4   D = 1/2   // a l l ow an c e f o r d e p r e c i a t i o n5   C = 2400   / / f i r s t c o s t6   I = 6/ 10 0   // i n t e r e s t r at e7   T = 4/ 10 0   // a l lo w a n ce f o r t a xe s8   M = 1 0/ 10 0   // a l l ow a n ce f o r m ai nt en an ce9   S = 8 0   // c os t o f s e t up

10   N = ( C *( I + T +D + M )+ S ) /( a * ( 1+ b ) )   // p i e c e s p er y ea r11   t = N *2   // t o t a l number o f p i e c e s12   printf ( ” \n T o ta l number o f p i e c e s p ro du ce d = %d”   , t

)

13   / / A nswers v ar y d ue t o ro und o f f e r r o r

Scilab code Exa 5.22  To find number of components

1   clc

2   a = 0. 12 5   // s a v i n g i n l ab ou r c o st p er u n i t3   b = 0.4   // o ve rh ea d a p p l i e d on d i r e c t l a bo u r s av ed4   D = 1/2   // a l l ow an c e f o r d e p r e c i a t i o n5   C = 2400   / / f i r s t c o s t

6   I = 6/ 10 0   // i n t e r s t r at e7   T = 4/ 10 0   // a l lo w a n ce f o r t a xe s8   M = 1 0/ 10 0   // a l l ow a n ce f o r m ai nt en an ce9   n = 6   // number o f b a c h es

10   S = 8 0   // c os t o f s e t up

47

Page 49: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 49/126

11   s 1 = S * n   // t o t a l s e t up c o s t

12   N = ( C * ( I + T + D+ M ) + s 1 ) /( a * ( 1 + b ) )   // p i e c e s13   t = N *2   // t o t a l number o f p i e c e s14   printf ( ” \n T o ta l number o f p i e c e s p ro du ce d = %d”   , t

)

15   / / A nswers v ar y d ue t o ro und o f f e r r o r

Scilab code Exa 5.23  To find time and profit

1   clc2   C 1 = 20 00   / / f i r s t c o st s ma l l t o o l i n Rs3   N = 5000   // p a r t s p er y ea r4   n = 5   // number o f b a t c h es5   S = 50* n   // c os t o f s e t up6   a = 0.15   // s av i n g i n l ab ou r c o st p er u ni t7   b = 5 0/ 10 0   // burde n a p p l i e d on d i r e c t l ab o ur s av ed8   I = 1 0/ 10 0   // i n t e r e s t r a t e9   T = 5/ 10 0   // a l lo w a n ce f o r t a x

10   M = 1 0/ 10 0   // a l l ow a n ce f o r m ai nt en an ce11   H = C 1 / (( N * a * ( 1 + b ) ) - ( C1 * ( I + T + M ) ) - S )   // y e ar s

12   C 2 = 16 00   // c os t o f f i x t u r e13   D = 1/ H   // a l l ow an c e f o r d e p r e c i a t i o n14   V = N * a *( 1+ b ) - C2 * ( I +T + D +M ) - S   // p r o f i t15   printf ( ” \n Number o f y e a r s t ak en by f i x t u r e o f Rs

2 0 00 = %0 . 2 f y e a r s \n p r o f i t made when f i x t u r e o f  Rs 1 6 0 0 = R s %d”   , H ,V )

Scilab code Exa 5.24  To find minimum number of components

1   clc

2   c 1 = 3   // machi ne c o s t p er component u s in g e x i s t i n ge ui p me nt i n Rs

3   c 2 = 1   // machi ne c o st u si ng f i x t u r e i n R s

48

Page 50: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 50/126

4   s = c 1 - c 2   // s a vi n g i n machi ne c o s t p er p i e c e

5   f = 1 00 0   // c os t o f f i x t u r e i n R s6   N = f /2   / / c o m p on e n ts7   printf   ( ” \n M inimum n um be r o f c o m p on e n t s t o b e

p ro du ce d i f c o s t o f f i x t u r e t o be r e co v e r e d = %d”,N )

Scilab code Exa 5.25  To calculate number of pieces

1   clc2   C = 1000   // c os t o f f i x t u r e3   C o = 700   // c os t o f o l d f i x t u r e4   C s = 250   // s c r a p v al ue5   a = 1 0   // s a vi n g p er p i e c e i n p a i sa6   a = a / 1 0 0

7   b = 3 0   // o ve rh ea d a p p li e d on d i r e c t l a bo u r s av ed8   b = b / 1 0 0

9   I = 8   // i n t e r e s t r a t e10   I = I / 1 0 0

11   M = 3   // a l l ow a n ce f o r m ai nt en an ce

12   M = M / 1 0 013   T = 1 2   // a l l ow an ce f o r t a x14   T = T / 1 0 0

15   H = 3/2   // a m o r t i za t i o n16   D = 1/ H   // a l l ow an c e f o r d e p r e c i a t i o n17   N = ( C * ( I + T + D+ M ) + ( Co - C s ) * I ) / ( a * ( 1+ b ) )   // p i e c e s p e r

y e a r18   printf ( ” \n Number o f p i e c e s w hi ch must be p ro du ce d

t o b re ak e ve n s o t h at f i x t u r e may pay f o r i t s e l f  = %d p i e c e s p er y ea r ”   , N )

19   / / A nswers v ar y d ue t o ro und o f f e r r o r

Scilab code Exa 5.26  To find cost for new fixture

49

Page 51: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 51/126

1   clc

2   N = 9000   // number o f p i e c e s3   C o = 700   // c os t o f o l d f i x t u r e4   C s = 250   // s c r a p v al ue5   a = 1 0   // s a vi n g p er p i e c e i n p a i sa6   a = a / 1 0 0

7   b = 3 0   // o ve rh ea d a p p li e d on d i r e c t l a bo u r s av ed8   b = b / 1 0 0

9   I = 8   // i n t e r e s t r a t e10   I = I / 1 0 0

11   M = 3   // a l l ow a n ce f o r m ai nt en an ce12   M = M / 1 0 0

13   T = 1 2   // a l l ow an ce f o r t a x14   T = T / 1 0 0

15   H = 3/2   // a m o r t i za t i o n16   D = 1/ H   // a l l ow an c e f o r d e p r e c i a t i o n17   C = ( N * a * ( 1+ b ) - ( Co - C s ) * I ) / ( I + T + D + M )   // c o s t i n Rs18   printf ( ” \n Co st f o r new f i x t u r e = Rs %d”   , C )

19   / / A nswers v ar y d ue t o ro und o f f e r r o r

Scilab code Exa 5.27  find time to amortize fixture

1   clc

2   n = 6500   // y e a r l y p r o du c ti o n3   c = 1350   // c os t o f f i x t u r e4   a = 1 0   // s a vi n g p er p i e c e i n p a i sa5   a = a / 1 0 0

6   b = 3 0   // o ve rh ea d a p p li e d on d i r e c t l a bo u r s av ed7   b = b / 1 0 0

8   I = 8   // i n t e r e s t r a t e

9   I = I / 1 0 010   M = 3   // a l l ow a n ce f o r m ai nt en an ce11   M = M / 1 0 0

12   T = 1 2   // a l l ow an ce f o r t a x13   T = T / 1 0 0

50

Page 52: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 52/126

14   c o = 700   // c os t o f o l d f i x t u r e

15   c s = 250   // s c r a p v al ue16   H = ( c ) / (( n * a * ( 1 + b ) ) - I *( c o - c s ) - c *( I + T + M ) )   //a m ot i za t io n i n y e ar s

17   printf ( ” \n Time t ak en t o a m or t iz e t he f i x t u r e = %0 . 1f y e a rs ”   , H )

Scilab code Exa 5.28  To find profit

1   clc2   n = 9000   // p ro du ct io n o f p i e c e s p e r y ea r3   c = 1000   // f i x t u r e c o s t s4   C o = 700   // c os t o f o l d f i x t u r e5   C s = 250   // s c r a p v al ue6   a = 1 0   // s a vi n g p er p i e c e i n p a i sa7   a = a / 1 0 0

8   b = 3 0   // o ve rh ea d a p p li e d on d i r e c t l a bo u r s av ed9   b = b / 1 0 0

10   I = 8   // i n t e r e s t r a t e11   I = I / 1 0 0

12   M = 3   // a l l ow a n ce f o r m ai nt en an ce13   M = M / 1 0 0

14   T = 1 2   // a l l ow an ce f o r t a x15   T = T / 1 0 0

16   h = 1.5   // a m o r t i za t i o n17   D = 1/ h   // a l l ow an c e f o r d e p r e c i a t i o n18   V = ( n * a * ( 1+ b ) ) - ( c * ( I + T + D+ M ) ) - ( ( Co - C s ) * I )   // p r o f i t19   printf ( ” \n p r o f i t = Rs %d ”   , V )

20   / / A nswers v ar y d ue t o ro und o f f e r r o r

Scilab code Exa 5.29  To find BEP Cost and Components

1   clc

51

Page 53: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 53/126

2   f c1 = 1 00 00 0   // f i x e d c o s t i n Rs

3   v c1 = 100   // v a r i a b l e c o s t i n Rs p e r u ni t4   s p = 200   / / s e l l i n g p r i c e i n Rs p er u ni t5   q 1 = f c1 / ( sp - v c 1 )   // q ua n ti t y o f p r o d uc ti o n a t b re ak

e ve n p o i n t6   f c2 = 1 25 00 0   // f i x e d c o s t i n Rs7   v c2 = 90   // v a r i a b l e c os t i n Rs p e r u ni t8   q 2 = f c2 / ( sp - v c 2 )   // q ua n ti t y o f p r o d uc ti o n a t b re ak

e ve n p o i n t9   p = 20 00 0   // p r o f i t i n Rs

10   q3 = ( fc1 + p )/( sp - vc1 )   // q u an t i t y o f p r o d uc t i o n a tp r o f i t o f Rs 2 00 00

11   printf ( ” \n B rea k e ven p o i nt = %d p i e c e s   \n I f f i x e dc o s t i s 1 2 5 00 0 and v a r i a b l e c o s t i s Rs 9 0 p e ru n i t t he n b re ak e ve n p o i n t = %d p i e c e s \n Numbero f c omponent s t o g e t p r o f i t o f Rs 2 00 00 = %dp i e c e s ”   , q1 , q2 , q3 )

Scilab code Exa 5.30  To find break even point

1   clc2   f c 1 = 1 20 00   // f i x e d c o st f o r machi ne A i n R s3   f c 2 = 4 80 00   // f i x e d c o st f o r machi ne B i n Rs4   n 1 = 6   // u n i t p ro du ct i o n c o s t i n Rs p e r p i e c e f o r

m a c h i n e A5   n 2 = 1.2   // u n i t p ro du ct io n c o st i n Rs p e r p i e c e f o r

m a c h i n e B6   q = ( fc2 - f c1 ) / ( n1 - n 2 )   // b re ak e ve n p o i nt7   printf ( ” \n B rea k e ve n p o i n t = %d p i e c e s ”   , q )

Scilab code Exa 5.31  To find break even quantity

1   clc

52

Page 54: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 54/126

2   / / c ap st an l a t h e

3   t c1 = 300   // t o t a l c os t i n Rs4   m c1 = 2.5   // m a t e r i a l c o s t p e r p i e c e i n Rs5   o lc1 = 5   // o p er a t i on l ab ou r c o st p er hour i n Rs6   ct1 = 5   // c y c l e t im e p er p i e c e i n min .7   s lc1 = 20   // s e t t i n g up l ab ou r c o s t i n Rs p er hour8   st1 = 1   // s e t t i n g up t i m e i n ho ur9   m o 1 = 3 00 / 10 0   // m ach in e o ve r h ea ds o f o p e r a t i on

l a bo u r c o s t10   o 1 = m o1 * o lc 1   // o ve rh ea ds o f c ap st an l a t h e i n Rs

p e r h ou r11   fc1 = tc1 + s lc1 * st1 + o1 * st1   // f i x e d c os t o f  

c ap st an l a t h e i n Rs12   v c1 = m c1 + ( o lc 1 * ct 1) / 60 + ( o1 * ct 1 ) /6 0   // v a r i a b l e

c o st i n Rs13   // Au to ma ti c ( s i n g l e s p i n d l e )14   t c2 = 300   // t o t a l c os t i n Rs15   c c2 = 1 50 0   // c o st o f cams i n R s16   m c2 = 2.5   // m a t e r i a l c o s t p e r p i e c e i n Rs17   o lc2 = 2   // o p er a t i on l ab ou r c o st p er hour i n Rs18   ct2 = 1   // c y c l e t im e p er p i e c e i n min .19   s lc2 = 20   // s e t t i n g up l ab ou r c o s t i n Rs p er hour20   st2 = 8

  // s e t t i n g up t i m e i n ho ur21   m o 2 = 1 0 00 / 10 0   // m achi ne o v er h ea ds o f o p e r a t i o nl a bo u r c o s t

22   o 2 = m o2 * o lc 2   // o ve rh ea ds o f s i n g l e s p i n d l e i n Rsp e r h ou r

23   fc2 = tc2 + cc2 + sl c2 * st2 + o2 * st2   // f i x e d c os t o f  s i n g l e s p i n d l e i n Rs

24   v c2 = m c2 + ( o lc 2 * ct 2) / 60 + ( s lc 2 ) /6 0   // v a r i a b l ec o st i n Rs

25   q = ( fc2 - f c1 ) / ( vc1 - v c2 )   // b re ak e ve n q u a n ti t y26   printf ( ” \n B rea k e ve n q u a n t i t y f o r a co mpo nen t w hi ch

can be p ro du ce d on e i t h e r t he c ap st an l a t h e o rs i n g l e s p i n d l e a u to m at ic = %d p i e c e s ”   , q )

53

Page 55: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 55/126

Scilab code Exa 5.32  To do break even analysis

1   clc

2   / / E ng in e l a t h e3   t = 1 2   // t im e / p i e c e i n min .4   l = 7   / / o v er h ea d c o s t / h r5   o = 4   // d i r e c t l a bo u r c o s t / hr6   s = 2   // s e t up t i m e i n hour7   s r = 8   // s e t up r a t e p e r8   / / t u r r e t l a t h e9   T = 5   / / t im e / p i e c e i n min .

10   L = 5   / / o v er h ea d c o s t / h r11   O = 8   // d i r e c t l a bo u r c o s t / hr12   S = 8   // s e t up t i m e i n hour13   S R = 8   // s e t up r a t e p e r14   q = 6 0 *( S * S R - s * s r ) /( t * ( l + o ) - T *( L + O ) )   // b r ea k e ve n

p o i n t15   q =   round ( q )

16   printf ( ” \n B rea k e ve n p o i n t = %d p i e c e s ”   , q )

Scilab code Exa 5.33  To calculate minimum number of pieces

1   clc

2   f c 1 = 8 00 00   // f i x e d c os t f o r t u r r e t l a t h e i n Rs3   f c 2 = 3 20 00   // f i x e d c o s t f o r e ng in e l a t h e i n Rs4   n 1 = 16   // p r o du c t io n o f p i e c e s p er y ea r i n t u r r e t

l a t h e

5   n 2 = 10   // p r o du c t io n o f p i e c e s p er y ea r i n e ng in el a t h e

6   vc1 = 2   // o p e r a t o r s c o st i n t u r r e t l a t h e7   v c2 = 2.5   // o p e r a t o r s c o st i n e ng i n e l a t h e8   Q = poly (0 , ’Q ’ )

54

Page 56: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 56/126

9   Q = roots ( ( f c 1 + 1 / n 1 * v c 1 * Q ) - ( f c 2 + 2 . 5 * Q / 1 0 ) )

10   printf ( ” \n B rea k e ve n p o i n t = %d p i e c e s ”   , Q )

Scilab code Exa 5.34  To determine the point

1   clc

2   s t1 = 15   // s e t up t i me f o r e ng i n e l a t h e i n min .3   u t1 = 15   // u n i t t i m e f o r e ng i n e l a t h e i n min .4   s t2 = 90   // s e t up t ime f o r a ut om at ic l a t h e i n min .

5   u t2 = 1.5   // u ni t t i m e f o r e ng i n e l a t h e i n min .6   q = ( st2 - s t1 ) / ( ut1 - u t2 )   // q u an t i t y o f p r o d uc t i o n7   printf ( ” \n The p o i nt a t whi ch t he a ut om a ti c l a t h e

w i l l b e j u s t i f i e d = %0 . 2 f ”   , q )

8   / / A nswers v ar y d ue t o ro und o f f e r r o r

Scilab code Exa 5.35  To find quantity of pieces

1   clc2   / / A ut om at ic l a t h e3   p = 3 0   // number o f p i e c e s p ro du ce d p er ho ur4   l = 4   // l ab ou r r a te p er ho ur i n R s5   d = 4.50   // h o ur l y d e p r e c i a t i o n r a t e p er machine i n

hour6   s = 4   // s e t up t i m e i n hour7   / / t u r r e t l a t h e8   P = 1 0   // number o f p i e c e s p ro du ce d p er ho ur9   L = 4   // l ab ou r r a te p er ho ur i n R s

10   D = 1.50   // h o ur l y d e p r e c i a t i o n r a t e p er machine i n

hour11   S = 2   // s e t up t i m e i n hour12   q = ( P * p * ( S * L+ S * D - s *l - s * d ) ) / ( P *( l + d ) - p * ( L + D) )   //

q ua nt i t y o f p i e c e s a t b r e a k e v e n p oi nt

55

Page 57: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 57/126

13   printf ( ” \n Q ua nt it y o f p i e c e s a t Break e ve n p o in t =

%d p i e c e s ”   , q )

Scilab code Exa 5.36  To determine quantity of production

1   clc

2   P a = 8.4   // u n i t t o o l p r o c e s s c o st f o r method A inRs

3   P b = 14 .8   // u ni t t o o l p r oc e ss c o st f o r method B i n

Rs4   T a = 64 80   // t o t a l t o o l c o s t f o r method A i n Rs5   T b = 16 16   // t o t a l t o o l c o st f o r method B i n Rs6   q = ( Ta - T b ) /( Pb - P a )   // b re ak ev en p o i nt7   printf ( ” \n Q ua nt it y o f p r o du c ti o n a t b re ak e ve n

p o i n t = %d p i e c e s ”   , q )

Scilab code Exa 5.37  find preference between machines and production

1   clc

2   / / m ac hi ne A3   i c 1 = 5 00 00   / / i n i t i a l c o s t4   h oc1 = 10   // h ou rl y o p e ra t i ng c h ar g es5   p p1 = 5   // p i e c e s p ro du ce d p er ho ur6   i = 1 5   // i n t e r e s t r a t e7   i = i / 1 0 0

8   o h = 20 00   // o p e r a t i n g h ou rs9   f c1 = i c1 * i   // f i x e d c o s t

10   v c1 = oh * h oc 1   // v a r i a b l e c o s t

11   t c1 = f c1 + vc 1   // t o t a l c ha r g e s12   a o 1 = oh * pp 1   // a n nu a l o u tp ut13   c 1 = t c1 / ao 1   // c o s t p e r u n i t14   / / m ac hi ne B15   i c 2 = 8 00 00   / / i n i t i a l c o s t

56

Page 58: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 58/126

16   h oc2 = 8   // h o ur l y o p e r a t i n g c h ar g es

17   p p2 = 8   // p i e c e s p ro du ce d p er ho ur18   f c2 = i c2 * i   // f i x e d c o s t19   v c2 = oh * h oc 2   // v a r i a b l e c o s t20   t c2 = f c2 + vc 2   // t o t a l c ha r g e s21   a o 2 = oh * pp 2   // a n nu a l o u tp ut22   c 2 = t c2 / ao 2   // c o s t p e r u n i t23   printf ( ” \n ( i ) C os t p er u n i t f o r m achi ne A = Rs %0 . 2

f  \n C os t p e r u n i t m ac hi ne B = Rs %0 . 2 f ” , c 1 , c 2 )

24   disp ( ” m achi ne B w i l l be p r e f e r r e d ” )

25   / / m ac hi ne A26   ao3 = 4 00 0   // a n nu a l o u tp ut

27   o c 3 = a o3 * h o c1 / p p 1   // o p e ra t i ng c h ar g es28   t c3 = o c3 + fc 1   // t o t a l a nn ua l c ha rg e29   c 3 = t c3 / ao 3   / / c o s t / p i e c e30   / / m ac hi ne B31   ao4 = 4 00 0   // a n nu a l o u tp ut32   o c 4 = a o4 * h o c2 / p p 2   // o p e ra t i ng c h ar g es33   t c4 = o c4 + fc 2   // t o t a l a nn ua l c ha rg e34   c 4 = t c4 / ao 4 / / c o s t / p i e c e35   printf ( ” \n ( i i ) Co st p er u n i t f o r ma ch in e A = Rs %0

. 2 f  \n C os t p e r u n i t m ac hi ne B = Rs %0 . 2 f ” , c 3 , c 4 )

36   disp (” m achi ne A w i l l be p r e f e r r e d ”

)

37   A = h oc 1 / pp 1   // o p e ra t i ng c o s t p er p i e c e on machineA

38   B = h oc 2 / pp 2   // o p e ra t i ng c o s t p er p i e c e on machineB

39   Q = fc2 - fc1   // a nn u al p r o d u c t io n40   printf ( ” \n ( i i i ) Annu al p r o d u c ti o n t o make c o s t p e r

p i e c e e q ua l f o r two m ac hi ne s = %d p i e c e s ”   , Q )

Scilab code Exa 5.38  To find BEP and various sales

1   clc

2   a s = 8 00 00   // a nn u al s a l e s i n Rs

57

Page 59: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 59/126

3   v c = 6 40 00   // v a r i a b l e e xp en se s i n R s

4   c = 16 00 0   // c o n t r i b ut i o n i n Rs5   f c = 2 40 00   // f i x e d e xp en se s i n Rs6   l = 8000   // l o s s e s i n Rs7   p = 9000   // p r o f i t i n Rs8   s1 = fc + vc   // s a l e s a t B . E . P i n Rs9   s2 = ( fc + vc + p )/ 0.945   // s a l e s a t n et i ncome o f  

Rs9000 and c o r p o r a te t ax r a t e b e in g 5 . 5%10   q = 10 00 0   // q ua n t it y o f u n i t s11   s p = ( fc + vc ) /q    / / s e l l i n g p r i c e p e r u ni t i n Rs12   printf ( ” \n S a l e s a t b re ak e v e n p o in t = %d u n i t s ”   ,

s1 )

13   printf ( ” \n S a l e s a t n et i ncome o f Rs9000 andc o r p o r at e t a x r a t e b ei ng 5 . 5 = Rs %0 . 2 f   \n S a l e sp er u n i t i f B . E . P b ro ug ht down t o 1 00 00 u n i t s =Rs %0 . 2 f p e r u n i t ”   , s2 , sp )

Scilab code Exa 5.39  To determine break even point

1   clc

2   f c = 5 50 00   // f i x e d c o s t i n Rs3   v c = 45   // v a r i a b l e c o s t p e r p i ec e i n Rs4   s p = 100   / / s e l l i n g p r i c e p e r p i e c e i n Rs5   p = ( vc / sp ) * 10 0   // p e r c e nt ag e o f v a r i a b l e c o st t o6   p m = 100 - p   // p r o f i t margi n7   b e p = ( ( 5 5 00 0 / 5 5) * 1 00 ) / 1 0 0   // B re ak e ve n p o i n t8   printf ( ” \n B rea k e ve n p o i n t = %d p i e c e s ”   , b ep )

Scilab code Exa 5.40  To calculate economic lot size

1   clc

2   f 1 = 335   // f i x e d c o s t i n Rs f o r c a ps t a n l a th e3   k = 0.25   // s t o ck c a r r y i n g f a c t o r i n p a i s e p e r p i e c e

58

Page 60: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 60/126

4   k = k / 1 0 0

5   N1 =   sqrt ( f 1 / k )   // p i e c e s f o r c ap st an l a t h e6   a 1 = 4. 16   // v a r i a b l e c o s t p e r p i e c e f o r c a ps t anl a t h e

7   t c1 = a 1 + f1 / N 1 +k * N1   // t o t a l c o s t f o r c a ps t a n l a th e8   f 2 = 21 20   // f i x e d c os t i n Rs f o r t u r r e t l a t he9   N2 =   sqrt ( f 2 / k )   // p i e c e s f o r t u r r e t l a t h e

10   a 2 = 2 .8 63   // v a r i a b l e c o s t p e r p i ec e f o r t u r r e tl a t h e

11   t c2 = a 2 + f2 / N 2 +k * N2   // t o t a l c os t f o r t u r r e t l a t h e12   printf ( ” \n T o t a l c o s t p e r p i e c e f o r c a ps t an l a t h e =

Rs %0. 2 f   \n T ot a l c o s t p e r p i e c e f o r t u r r e t l a t h e

= Rs %0. 2 f ”   , tc1 , tc2 )13   / / A nswers v ar y d ue t o ro und o f f e r r o r

Scilab code Exa 5.41  To find EOQ and total cost

1   clc

2   R = 5 0 0   // c o s t o f o r d e r i n g i n Rs p e r o rd er3   A = 1 2 0 0 0   / / a n nu a l c on su mp ti on u n i t s

4   C = 3 . 0 0   // u ni t c o s t o f i t e m5   K =3   // u n i t s t o r a g e c o st6   I 1 = 0 . 2   // i n t e r e s t r a t e7   function   y = f ( N )

8   function   G = f 2 ( N )

9   G = C * A + I 1 * C * N / 2 + K * N / 2 + A * R / N   // t o t a l c o s t p e r y e a r10   e n d f u n c t i o n

11   y = d e r i v a t i v e ( f 2 , N )

12   e n d f u n c t i o n

13   funcprot (0)

14   N = fsolve ( 2 0 0 0 , f )15   O = A / N   // number o f o r d e r s16   N 1 = 24 00   // u n i t s17   tc = C *A + I1 * C* N1 /2 + K * N1 /2 + A *R /N1   // t o t a l c o s t

i n Rs

59

Page 61: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 61/126

18   I 2 = ( 2* R * A ) /( C * N1 ^ 2 )

19   printf ( ” \n Eco no mi c o r d e r q u a n t i t y = %d u n i t s \n T ot lc o s t = Rs %d p er y ea r \n I = %0 . 4 f ” , N 1 , t c , I 2 )

20   disp ( ” I t i s c l e a r t h a t i nv en to ry c os t w i l l g e ti n c r e as e d v er y g r e a t l y ” )

Scilab code Exa 5.42   Determine optimum lot size

1   clc

2   A = 40 00 0   // number o f u n i t s p er y ea r3   I = 2 5   // c a r r y i n g c o st i n p e r c e nt4   I = I / 1 0 0

5   C 1 = 8   // c o st f o r 0   <   N   <   10 00 p er u ni t i n Rs6   C 2 = 7.5   // c o st f o r 1000   <   N   <   10 00 0 p er u n i t i n Rs7   C 3 = 7. 25   // c os t f o r N   >= 10 00 0 p er u n i t i n Rs8   R = 250   // o r de r i n g c o st p er o r d er i n Rs9   N = 10 00 0   // u n i t s

10   N1 =   sqrt ( 2 * R * A / ( I * C 3 ) )   // o pt im al q u an t it y f o rl o w e st c u rv e

11   G 1 = C 3 * A +( A * R ) / N + I * C3 * N / 2   // t o t a l c os t i n Rs

12   N2 =   sqrt ( 2 * R * A / ( I * C 2 ) )   // o pt im al q u an t it y f o rh i g h e r c ur ve

13   G 2 = C 2 * A +( A * R ) / N 2 + I * C2 * N 2 / 2   // t o t a l c os t i n Rs14   N3 =   sqrt ( 2 * R * A / ( I * C 1 ) )   // o pt im al q u an t it y f o r

h i g h e s t c ur ve15   G 3 = C 1 *A + ( A* R ) +1   // t o t a l c os t i n Rs16   printf ( ” \n T o ta l c o st f o r l o w e s t c o st c ur ve = Rs %0

. 2 f  \n T ot al c o s t f o r n ex t h i gh e r c ur ve = Rs %0 . 2 f  \n T ot al c o s t f o r h i g h e st c ur ve = Rs %0 . 2 f ”   , G1

, G 2 , G 3 )

17   disp ( ” Comparing a l l t o t a l c o st l o w e s t i s Rs3 0 0 , 0 62 . 50 f o r an o r de r q ua n ti t y o f 1 0 , 0 00 . ” )

18   disp ( ”N = 1 0 , 00 0 and No . o f o r d e r s = 4 ” )

60

Page 62: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 62/126

Scilab code Exa 5.43  To find most economical lot size

1   clc

2   c = 50 00 0   / / c o m po n e n ts3   R = 5 0 0   // c o s t o f o r d e r i n g i n Rs p e r o rd er4   A = 1 2 0 0 0   / / a n nu a l c on su mp ti on u n i t s5   C = 3 . 0 0   // u ni t c o s t o f i t e m6   K = 1 . 5 0   // u n i t s t o r a g e c o st7   I = 0 . 2   // i n t e r e s t r a t e8   function   y = f ( N )

9   function   G = f 2 ( N )

10   G = 0 . 0 2 * N + 1 5 0 0 0 0 0 / N

11   e n d f u n c t i o n

12   y = d e r i v a t i v e ( f 2 , N )

13   e n d f u n c t i o n

14   funcprot (0)

15   N = fsolve ( 2 0 0 0 , f )

16   l = c / N   // number o f l o t s17   l =   ceil ( l )

18   l s = c / l   // l o t s i z e19   printf ( ” \n The l o t s i z e = %d c o mp on en ts ” , l s )

61

Page 63: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 63/126

Chapter 9

Limits Tolerences and Fits

Scilab code Exa 9.1  To find allowance and tolerence

1   clc

2   h 1 = 3 7. 52   // h ig h l i m i t o f h ol e i n mm3   h 2 = 3 7. 50   // low l i m i t o f h o l e i n mm4   s 1 = 3 7. 47   // h i g h l i m i t o f s h a f t i n mm5   s 2 = 3 7. 45   // low l i m i t o f s h a f t i n mm6   h t = h1 - h2   // h o le t o l e r e n c e i n mm

7   s t = s1 - s2   // s h a f t t o l e r e n c e i n mm8   a = h2 - s1   // a l l o w a n c e i n mm9   printf ( ” \n H ol e t o l e r e n c e = %0 . 2 f mm\n S h a f t

t o l e r e n c e = %0 . 2 f mm\n A l l ow anc e = %0. 2 f mm”   , ht

, st , a)

Scilab code Exa 9.2  Determine dimensions of shaft and hole

1   clc

2   t = 0. 07 5   // t o l e r e n c e i n mm3   h 2 = 75   // l ow l i m i t o f h o l e i n mm4   a = 0.10   // a l l o w a n c e i n mm

62

Page 64: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 64/126

5   h 1 = h2 +t   // h ig h l i m i t o f h ol e i n mm

6   s 1 = h2 - a   // h i g h l i m i t o f s h af t i n mm7   s 2 = s1 - t   // l ow l i m i t o f s h a f t i n mm8   printf ( ” \n High l i m i t o f h o l e = %0 . 3 f mm\n H ig h

l i m i t o f s h a f t = %0 . 2 f mm\n Low l i m i t o f s h a f t =%0 . 3 f mm”   , h1 , s1 , s2 )

Scilab code Exa 9.3  Determine dimensions of hole and shaft

1   clc2   t = 0. 22 5   // t o l e r e n c e i n mm3   h 2 = 75   // l ow l i m i t o f h o l e i n mm4   a = 0 .0 37 5   // i n t e r f e r e n c e i n mm5   h 1 = h2 +t   // h ig h l i m i t o f h ol e i n mm6   s 2 = h1 +a   // l ow l i m i t o f s h a f t i n mm7   s 1 = s2 +t   // h i g h l i m i t o f s h af t i n mm8   printf ( ” \n High l i m i t o f h o l e = %0 . 3 f mm\n Low l i m i t

o f s h a f t = %0 . 4 f mm\n High l i m i t o f s h a f t = %0 . 4f mm”   , h1 , s2 , s1 )

Scilab code Exa 9.4  Calculate fundamental deviations and tolerences

1   clc

2   s 1 = 50   // d i am e te r o f s t e p1 i n mm3   s 2 = 80   // d i am e te r o f s t e p2 i n mm4   d = ( s 1 * s2 ) ^ ( 1/ 2)   / / mm5   i = ( 0 . 45 * ( d ) ^ ( 1 /3 ) + 0 . 0 0 1* d ) / 1 0 ^ 3   / / mm6   t 1 = 25* i   // t o l e r e n c e f o r h o l e i n mm

7   t 2 = 16* i   // t o l e r e n c e f o r s h a f t i n mm8   a 1 = 0   // f un da me nt al d e v i a t i o n f o r h o le i n mm9   a 2 = 5 .5 *( d ) ^ 0 .4 1   // f un da me nt al d e v i a t i o n f o r s h a f t

i n m i cr o ns10   a 2 = a2 / 10 ^4   / / mm

63

Page 65: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 65/126

11   h 1 = 60   // l ow l i m i t o f h o l e i n mm

12   h 2 = h1 + t1   // h ig h l i m i t o f t o l e r e n c e i n mm13   s1 = h1 - t 2   // h i g h l i m i t o f s h a f t i n mm14   s 2 = s1 - t2   // low l i m i t o f s h a f t i n mm15   printf ( ” \n T o l er e n ce f o r h o l e = %0 . 3 f mm\n T o l er e n ce

f o r s h a f t = %0 . 3 f mm”   , t1 , t2 )

16   printf ( ” \n Fu nd am en ta l d e v i a t i o n f o r h o l e = %0 . 2 f mm\n F un da men ta l d e v i a t i o n f o r s h a f t = %0 . 3 f mm”   ,

a1 , a2 )

17   printf ( ” \n Low l i m i t o f h o l e = %d mm\n H igh l i m i t o f  h o l e = %0 . 3 f mm\n High l i m i t o f s h a f t = %0 . 2 f mm

\n Low l i m i t o f h o l e = %0 . 2 f mm”   , h1 , h2 , s1 ,

s2 )18   / / A nswers v ar y d ue t o ro und o f f e r r o r

Scilab code Exa 9.5  Find tolerences limits and clearance

1   clc

2   b = 3 0   // b a s i c s i z e i n mm3   s 1 = 0 .0 05   // maximum l i m i t o f s h a f t i n mm

4   s 2 = 0 .0 18   // minimum l i m i t o f s h a f t i n mm5   h 1 = 0 .0 20   // maximum l i m i t o f h o l e i n mm6   h 2 = 0.0   // minimum l i m i t o f h o l e i n mm7   t 1 = s2 - s1   // s h a f t t o l e r e n c e i n mm8   t 2 = h1 - h2   // h o le t o l e r e n c e i n mm9   S h = b -s1   // h i g h l i m i t o f s h af t i n mm

10   S l = b -s2   // l ow l i m i t o f s h a f t i n mm11   H h = b +h1   // h i gh l i m i t o f h o l e i n mm12   H l = b +h2   // l ow l i m i t o f h o l e i n mm13   c 1 = Hh - Sl   / / maximum c l e a r a n c e i n mm

14   c 2 = Hl - Sh   / / m inimum c l e a r a n c e i n mm15   printf ( ” \n B a s i c s i z e = %d mm\n S ha f t t o l e r e n c e = %0. 3 f mm\n H o le t o l e r e n c e = %0 . 3 f mm” , b , t 1 , t 2 )

16   printf ( ” \n High l i m i t o f s h a f t = %0 . 3 f mm\n Lowl i m i t o f s h a f t = %0 . 3 f mm\n H igh l i m i t o f h ol e =

64

Page 66: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 66/126

%0 . 3 f mm   \n Low l i m i t o f h o l e = %0 . 3 f mm” , S h , S l ,

H h , H l )17   printf ( ” \n Maximum c l e a r a nc e = %0. 3 f mm\n Minimumc l e a r a n c e = %0 . 3 f mm” , c 1 , c 2 )

Scilab code Exa 9.6  Determine limits of shaft and hole

1   clc

2   m in c = 0 .0 1   / / minimum c l e a r a n c e i n mm

3   b s = 25   // b a s i c s i z e i n mm4   m ax c = 0 .0 2   / / maximum c l e a r a n c e i n mm5   x = poly (0 , ’ x ’ )

6   y = 1 . 5 * x

7   x = roots ( y + 0 . 0 1 + x - 0 . 0 2 )

8   y = horner ( y , x )

9   // h o l e b a s i s s ys te m10   l o w_ h1 = bs   // low l i m i t o f h ol e i n mm11   h ig h_ h1 = bs + y   // h i gh l i m i t o f h o l e i n mm12   u _ s = l ow _h 1 - m i n c   // u ppe r l i m i t o f s h a f t i n mm13   l ow _s 1 = u_s - x   // l ow er l i m i t o f s h a f t i n mm

14   / / s h a f t b a s i s s y st e m15   h i gh _s = bs   // h i g h l i m i t o f s h af t i n mm16   l ow _s 2 = bs - x   // low l i m i t o f s h a f t i n mm17   l ow _ h2 = b s + mi nc   // low l i m i t o f h ol e i n mm18   h i gh _ h2 = l ow _ h2 + y   // h ig h l i m i t o f h ol e i n mm19   printf ( ” H ol e b a s i s s ys te m   \n Lower l i m i t o f h o l e =

%d mm\n H ig he r l i m i t o f h o l e = %0 . 3 f mm\n H i gh erl i m i t o f s h a f t = %0 . 3 f mm   \n Lower l i m i t o f s h a f t= %0 . 3 f mm” , l o w_ h 1 , h i g h _ h1 , u _ s , l o w _ s 1 )

20   printf ( ” \n S ha f t b a s i s sy st e m   \n h ig h l i m i t o f s h a f t

= %0. 3 f mm\n l ow er l i m i t o f s h a f t = %0 . 3 f mm\nl o we r l i m i t o f h o l e = %0 . 3 f mm\n u ppe r l i m i t o f  ho l e = %0. 3 f mm”   , h ig h_ s , l o w_ s2 , l o w_ h2 , h i g h _ h2 )

65

Page 67: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 67/126

Scilab code Exa 9.7  Determine dimensions of shaft and hole

1   clc

2   b s = 100   // b a s i c s i z e i n mm3   s 1 = 120 // d i am e te r o f s t e p1 i n mm4   s 2 = 80   // d i am e te r o f s t e p2 i n mm5   d = ( s 1 * s2 ) ^ ( 1/ 2)   / / mm6   d =   ceil ( d )

7   i = ( 0 . 45 * ( d ) ^ ( 1 /3 ) + 0 . 0 0 1* d ) / 1 0 ^ 3   / / mm8   t 1 = 16* i   // t o l e r e n c e f o r h o l e i n mm9   t 2 = 25* i   // t o l e r e n c e f o r s h a f t i n mm

10   G = ( 2. 5* ( d ) ^ 0. 34 ) / 1 0^ 3   // f un da me nt al d e v i a t i o n f o rh o l e i n mm

11   e = ( 11 *( d ) ^ 0 .1 1) / 1 0 ^3   // f un da me nt al d e v i a t i o n f o rs h a f t i n m ic ro ns

12   / / H ol e13   L Lh = bs + G   // l ow er l i m i t o f h o l e i n mm14   H L h = L Lh + t1   // h i g h e r l i m i t o f h o l e i n mm15   / / s h a f t

16   U Ls = bs - e   // u ppe r l i m i t o f s h a f t i n mm17   L L s = ULs - t 2   // l ow er l i m i t o f s h a f t i n mm18   printf ( ” \n l ow er l i m i t o f h o le = %0 . 3 f mm\n h i g h e r

l i m i t o f h o l e = %0 . 3 f mm\n u pp er l i m i t o f s h af t =%0 . 3 f mm\n l o we r l i m i t o f s h a f t = %0 . 3 f mm”   ,

L L h , H L h , U L s , L L s )

19   / / E rr or i n t ex tb oo k

Scilab code Exa 9.8  Determine size of bearing and journal

1   clc

2   t b = 0 .0 05   // t o l e r e n c e on b e ar i ng i n mm3   t j = 0 .0 04   // t o l e r e n c e on j o u r n a l i n mm

66

Page 68: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 68/126

4   a = 0. 00 2   / / a l l o w a n c e i n mm

5   / / h o l e −b a s i s s ys te m6   b = 100   // b a s i c s i z e i n mm7   B l = b   // l ow er l i m i t o f b e a r i ng i n mm8   B h = Bl + tb   // h i g h e r l i m i t o f b e a r i ng i n mm9   J h = Bl - a   // h i g h e r l i m i t o f j o u r n a l i n mm

10   Jl1 = Jh - tj   // l ow e r l i m i t o f j o u r n a l i n11   / / s h a ft −b a s i s s ys te m12   J u = b   // upp e r l i m i t o f j o u r n a l i n mm13   J l2 = Ju - t j   // l ow er l i m i t o f j o u r n a l i n mm14   B l = Ju +a   // l ow er l i m i t o f b e a r i n g i n mm15   B u = Bl + tb   // u ppe r l i m i t o f b e ar i ng i n mm

16   printf ( ” \n H ol e b a s i s s ys te m   \n L ower l i m i t o f   j o u r n a l = %d mm\n H ig he r l i m i t o f b e ar i ng = %0 . 3 f  

mm\n H ig he r l i m i t o f j o u r n a l = %0 . 3 f mm   \n L ow erl i m i t o f j o u r n a l = %0 . 3 f mm” , B l , Bh , J h , J l 1 )

17   printf ( ” \n s h a f t b a s i s sy s t e m   \n u ppe r l i m i t o f   j o u r n a l = %0 . 3 f mm\n l ow er l i m i t o f j o u rn a l = %0. 3 f mm\n l o we r l i m i t o f b e a ri n g = %0 . 3 f mm\nu pp er l i m i t o f b e a r i n g = %0 . 3 f mm”   , Ju , J l2 , B l , B u

)

Scilab code Exa 9.9  Determine size of two mating parts

1   clc

2   / / H ol e−b a s i s s ys te m3   b = 100   // b a s i c s i z e i n mm4   i 1 = 0. 12   / / maximum i n t e r f e r e n c e i n mm5   i 2 = 0. 05   / / minimum i n t e r f e r n c e i n mm6   t = ( i1 - i 2) /2   // t o l e r e n c e i n mm

7   S h = b +i1   // up pe r l i m i t o f s h a f t i n mm8   H l = b   // l ow er l i m i t o f h o l e i n mm9   H h = b + t   // h i g h er l i m i t o f h ol e i n mm

10   S l1 = Sh - t   // l ow er l i m i t o f s h a f t i n mm11   / / s h a ft −b a s i s s ys te m

67

Page 69: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 69/126

12   S u = b   // upp e r l i m i t o f s h a f t i n mm

13   Sl2 = b -t   // l ow er l i m i t o f s h a f t i n mm14   Hl1 = b - i1   // l ow er l i m i t o f h o l e i n mm15   H u = Hl 1+ t   // h i g h e r l i m i t o f h o l e i n mm16   printf ( ” \n H ol e b a s i s s ys te m   \n u pp er l i m i t o f s h af t

= %0. 3 f mm\n l ow er l i m i t o f h o le = %0 . 3 f mm\nh i g h e r l i m i t o f h o l e = %0 . 3 f mm\n l o w e r l i m i t o f  sh af t = %0. 3 f mm”   , S h , Hl , H h , S l 1 )

17   printf ( ” \n S ha f t b a s i s sy st e m   \n u ppe r l i m i t o f  s h a f t = %0 . 3 f mm\n l ow er l i m i t o f s h a f t = %0 . 3 f  

mm\n l ow er l i m i t o f h o l e = %0 . 3 f mm\n up pe r l i m i to f h o l e = %0 . 3 f mm”   , S u , S l2 , H l1 , H u )

Scilab code Exa 9.10  Determine size of hole and shaft

1   clc

2   a a = 0. 04   / / a v er a ge a l l o wa n c e i n mm3   a = 0. 01 2   / / a l l o w a n c e i n mm4   M ax = aa + a   / / maximum a l l o w a n c e i n mm5   M in = aa - a   / / minimum a l l o w a n c e i n mm

6   t = ( Max - M in ) /3   // t o l e r e n c e i n mm7   t s = t   // t o l e r e n c e i n s ha t i n mm8   t h = 2* t   // t o l e r e n c e i n h o l e i n mm9   b = 100   // b a s i c s i z e i n mm

10   H l = b   // l ow er l i m i t o f h o l e i n mm11   H u = b +th   // up pe r l i m i t o f h ol e i n mm12   S u = b - 0 .0 28   // u ppe r l i m i t o f s h a f t i n mm13   S l = Su - ts   // l ow er l i m i t o f s h a f t i n mm14   printf ( ” \n l ow er l i m i t o f h o le = %d mm\n u ppe r l i m i t

o f h o l e = %0 . 3 f mm\n uppe r l i m i t o f s h a f t = %0 . 3

f mm\n l o we r l i m i t o f s h a f t = %0 . 3 f mm”   , H l , H u , S u, S l )

68

Page 70: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 70/126

Chapter 11

Surface finish

Scilab code Exa 11.1  Calculate CLA value

1   clc

2   v = 15 00 0   // v e r t i c a l m a g ni f i c a t i o n3   h = 100   // h o r i z o n t a l m a g ni f i c a t i o n4   l = 0.8   // s a mp l in g l e n g t h i n mm5   a 1 = 160   // a r e a a bo ve datum l i n e i n mmˆ 26   a 2 = 90   // a r e a a bo ve datum l i n e i n mmˆ 2

7   a 3 = 180   // a r e a a bo ve datum l i n e i n mmˆ 28   a 4 = 50   // a r e a a bo ve datum l i n e i n mmˆ 29   a 5 = 95   / / a r e a b el ow datum l i n e i n mmˆ 2

10   a 6 = 65   / / a r e a b el ow datum l i n e i n mmˆ 211   a 7 = 170   // a r e a b el o w d atum l i n e i n mmˆ 212   a 8 = 150   // a r e a b el o w d atum l i n e i n mmˆ 213   a = ( a 1 + a 2 + a3 + a 4 + a 5 + a 6 + a7 + a 8 ) / ( v * h )

14   C LA = a / l

15   printf ( ” \n C . L . A v a l u e = %0 . 2 f   ∗10 ˆ −6 m ”   , C LA * 1 0 0 0 )

Scilab code Exa 11.2  Calculate average and rms value

69

Page 71: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 71/126

1   clc

2   / / from f i g u r e 1 1. 2 33   y 1 = 0. 15   // mu m4   y 2 = 0. 25   // mu m5   y 3 = 0. 35   // mu m6   y 4 = 0. 25   // mu m7   y 5 = 0. 30   // mu m8   y 6 = 0. 15   // mu m9   y 7 = 0. 10   // mu m

10   y 8 = 0. 30   // mu m11   y 9 = 0. 35   // mu m12   y 10 = 0 .1 0   // mu m

13   y 1s qr = y1 ^ 2   // mu m14   y 2s qr = y2 ^ 2 // mu m15   y 3s qr = y3 ^ 2   // mu m16   y 4s qr = y4 ^ 2   // mu m17   y 5s qr = y5 ^ 2   // mu m18   y 6s qr = y6 ^ 2   // mu m19   y 7s qr = y7 ^ 2   // mu m20   y 8s qr = y8 ^ 2   // mu m21   y 9s qr = y9 ^ 2   // mu m22   y 1 0 sq r = y 10 ^ 2   // mu m23   n = 1 0

24   y n = ( y 1 + y 2 + y3 + y 4 + y 5 + y6 + y 7 + y 8 + y 9 + y 10 ) / n   //a r i t h m e t i c a v er a ge i n mu m

25   r ms =   sqrt ( ( y 1 s q r + y 2 s q r + y 3 s q r + y 4 s q r + y 5 s q r + y 6 s q r +

y 7 s q r + y 8 s q r + y 9 s q r + y 1 0 s q r ) / n )   / / r .m. s v a l u e i nmu m

26   printf ( ” \n The a r i t h m e t i c a v e ra g e = %0 . 2 f   ∗10ˆ −6 m   \nThe r . m. s . v a l u e = %0 . 3 f   ∗10 ˆ −6 m” , y n , r m s )

70

Page 72: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 72/126

Chapter 13

Analysis of metal forming

processes

Scilab code Exa 13.1  To find drawing load

1   clc

2   s ig ma _0 = 2 40   / / N/mmˆ23   d 1 = 5   / / i n i t i a l w i r e d i a m e t e r i n mm4   d 0 = 5.5   // f i n a l w ir e d ia me te r i n mm5   x = d1 /d0   / / mm6   alpha = 8   // a n g l e o f c on t a c t7   a lp ha = a lp ha * % pi / 1 80

8   m u = 0.1   // c o e f f i c i e n t o f f r i c t i o n9   B = mu *cotg ( a l p h a )

10   s i gm a _d = ( s i g ma _ 0 * (1 + B ) *( 1 -( x ) ^ (2 * B )) ) / B   / / N/mmˆ211   l = 3   // d i e l an d i n mm12   m u = 0.1   // c o e f f i c i e n t o f f r i c t i o n13   r 1 = d1 /2   / / mm14   s ig ma _t = s ig ma _0 - ( s ig ma _0 - s ig ma _d ) / exp ( ( 2 * m u * l )

/ r 1 )   / / N/mmˆ215   d l = s i gm a _t * % p i *( r 1 ) ^2   // d ra wi n g l oa d i n N16   printf ( ” \n T o ta l d ra wi ng l o a d = %0 . 1 f N”   , d l )

17   / / A nswers v ar y d ue t o ro und o f f e r r o r

71

Page 73: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 73/126

Scilab code Exa 13.2   Calculate drawing force

1   clc

2   a lp ha = 15   // a ng l e o f c on t a c t3   a lp ha = a lp ha * % pi / 1 80

4   b ita = 0   // d e gr e e5   m u = 0.1   // c o e f f i c i e n t o f f r i c t i o n6   m u1 = mu

7   m u2 = mu

8   h 1 = 1. 75   / / mm9   h 0 = 2.5   / / mm

10   B = ( mu 1 + mu 2 )/( tan ( a l p h a ) -tan ( b i t a ) )

11   y 1 = ( 1+ B ) * (1 - ( h 1 / h0 ) ^ B )/ B   // s i gm a d / s i g ma 0 f o rp l u g m a n d r e l s i n N/mmˆ 2

12   z = 1 /( ( h 0 / h1 ) - 1)

13   y2 =   log10 ( z ) // s ig ma d / s i g ma 0 f o r m ovab le m an dr el si n N/mmˆ2

14   printf ( ” \n The p i p e d ra wi ng f o r c e f o r c e on p lu gm a n d r e l s = %0 . 3 f    \n The p i p e d ra wi ng f o rc w on

m a n d r e l s = %0 . 3 f ” , y 1 , y 2 )15   disp ( ” Use o f mo vabl e m an dr el s u b s t a n t i a l l y r e d uc e s

d ra wi ng f o r c e ” )

Scilab code Exa 13.3  find neutral section slips and pressure

1   clc

2   h 0 = 25   // t h i c k n e s s o f p l a t e i n mm

3   h 1 = 20   / / mm4   d e l ta _ h = h0 - h 1   // mm5   s i gm a = 1 00   // maximum pr e s s ur e i n N/mmˆ26   D = 500   // r o l l e d d ia me te r i n mm7   r = D /2   // r o l l e d r a di u s i n mm

72

Page 74: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 74/126

8   a l ph a =   acos ( 1 - ( d e l t a _ h / D ) )   // a ng l e o f c o n t a c t i n

r a d i a n s9   mu =   tan ( a l p h a )   // c o e f f i c i e n t o f f r i c t i o n10   H o = 2* sqrt ( r / h 1 ) * atan ( sqrt ( r / h 1 ) * m u )

11   H n = ( Ho - ( log ( h 0 / h 1 ) ) / m u ) / 2

12   t h et a =   sqrt ( h 1 / r ) * tan ( sqrt ( h 1 / r ) * ( H n / 2 ) )   // r a d ia n13   h n = h1 + r * th eta ^ 2   // n e u t ra l s e c t i o n i n mm14   x = hn /h0

15   b s = (1 - x ) *1 00   // b ac kw ar d s l i p16   y = hn /h1

17   f s = ( y -1 ) *1 00   // f or wa rd s l i p18   s i g ma 0 = 2 * s ig ma / sqrt (3)

19   p n = s ig ma 0 * hn * exp ( m u * H n ) / h 1   //N/mmˆ220   printf ( ” \n N e u t r a l s e c t i o n = %0 . 1 f mm”   , h n )

21   printf ( ” \n Backward s l i p = %0 . 1 f p e r c e n t \n F o rw a rds l i p = %0 . 1 f p e r c e n t ”   , bs , f s)

22   printf ( ” \n Maximum p r e s s u r e = %0. 1 f N/mmˆ2”   , p n )

23   // ’ Answers v ar y due t o ro un d o f f e r r or ’

Scilab code Exa 13.4  To determine maximum force

1   clc

2   D o = 250   / / d i a me t er i n mm3   h o = 250   // h i e g h t i n mm4   d el ta _h = 1 00   / / mm5   h = 150   / / mm6   s i gm a0 = 55   / / N/mmˆ27   d = Do *sqrt ( h o / ( h o - d e l t a _ h ) )   / / d i a me t er i n mm8   m u = 0. 42   // c o e f f i c i e n t o f f r i c t i o n9   R = 16 2. 5   / / mm

10   p a = s i g ma 0 / 2 * ( h / ( mu * R ) ) ^ 2 *( % e ^ ( 2 * m u * R / h ) - 2* m u * R / h-1)   / / N/mmˆ211   p = p a * %p i *( R ) ^2   // f o r c e i n kN12   printf ( ” \n F o r c e = %d kN ”, p / 1 0 0 0 )

73

Page 75: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 75/126

Scilab code Exa 13.5  Determine sticking radius and total load

1   clc

2   d = 150   / / d i a m et e r i n mm3   h = 1 0   // t h i c k n e s s i n mm4   R = d /2   // r a d i u s i n mm5   m u = 0.2   // c o e f f i c i e n t o f f r i c t i o n6   s ig ma _0 = 2 00   / / N/mmˆ27   R s = R - ( h /(2 * mu )) *log (1/( sqrt ( 3 ) * m u ) )   // s t i c k i n g

r a d i u s i n mm8   P s = s ig ma _0 * exp ( 2 * m u * ( R - R s ) / h )   // p r e s s u re a t

s t i c k i n g r a d i u s i n N/mmˆ 29   function   y = f ( r )

10   y = 2 * % p i * r * s i g m a _ 0 * exp ( 2 * m u / h * ( R - r ) )

11   e n d f u n c t i o n

12   L _ sl d =   intg ( 4 8 . 5 , 7 5 , f )

13   L _s ld = L _s ld / 1 0 00   // l oa d o n s l i d i n g p o r t i o n i n kN14   P c = P s + ( 2* s i gm a_ 0 * Rs ) /( h *sqrt ( 3 ) )   // p r e s s u re a t

c e nt r e i n N/mmˆ2

15   L _ s p = ( P c + P s ) * %p i * ( R s ) ^ 2 / ( 2* 1 0 0 0)   // l oa d ons t i c k i n g p o rt i on i n kN

16   F_l = L _s ld + L _sp   // t o t a l f o r g i n g l oa d i n kN17   printf ( ” \n S t i c k i n g r a d i u s = %0 . 1 f mm   \n T ot al

f o r g i n g l o a d = %0 . 3 f MN” , R s , F _l / 1 0 0 0 )

18   // ’ Ans wers v ar y due t o ro un d o f f e r r or ’

Scilab code Exa 13.7  To find drawing load and power

1   clc

2   R A = 0. 30

3   d = 1 2   / / d i a me t e r i n mm4   alpha = 6   // a ng l e o f c on t a c t i n d e g re e

74

Page 76: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 76/126

5   a lp ha = 6 * %p i / 18 0   // a n g l e o f c o n t a c t i n r ad ia n

6   m u = 0. 10   // c o e f f i c i e n t o f f r i c t i o n7   s ig ma _0 = 2 40   // N/mmˆ28   B = mu *cotg ( a l p h a )

9   x = 1 - RA

10   s ig ma _ d = ( s i g ma _ 0 * (1 + B ) *( 1 -( x ) ^ B) ) / B   / / N/mmˆ211   r1 =   sqrt ( x ) * ( d / 2 )   / / mm12   l = s ig m a_ d * % pi * ( r 1 )^ 2   // l oa d i n kN13   i ta = 98   // e f f i c i e n c y14   i ta = i ta / 10 0

15   s = 2.3   // d ra wi ng s p ee d i n m/ s16   P = ( l* s )/ it a   / / kW

17   printf ( ” \n D ra wi ng l o a d = %0 . 2 f kN\n Power o f m ot or= %0 . 2 f kW”   , l / 10 00 , P /1 00 0 )

18   // ’ Ans wers v ar y due t o ro un d o f f e r r or ’

Scilab code Exa 13.8  calculate drawing load and power rating

1   clc

2   m u1 = 0 .1 5   // c o e f f i c i e n t o f f r i c t i o n

3   m u2 = 0 .1 8   / / c o e f f i c i e n t o f f r i c t o n4   a lp ha = 14   // a ng l e o f c on t a c t i n d e g re e5   a lp ha = a lp ha * % pi / 1 80

6   b ita = 10   / / s em i−c o ne a n gl e i n d e g r e e7   b it a = b it a * %p i / 18 0

8   s i g ma _ 0 = 1 .4 0   / / kN/mmˆ29   h 0 = 1.5   //mm

10   h 1 = 1   / / mm11   B = ( mu 1 + mu 2 )/( tan ( a l p h a ) + tan ( b i t a ) )

12   s i g m a d = ( s i g m a_ 0 * ( 1 + B ) * (1 - ( h 1 / h 0 ) ^ B ) ) / B   / / d r aw i ng

s t r e s s i n kN /mmˆ 213   d 1 = 11   // o u t s i d e d i am et er i n mm14   t = 1   // t h i c k n e s s i n mm15   d 2 = d1 - 2* t   / / mm16   a = ( % pi * ( ( d1 ) ^ 2 -( d 2 ) ^2 ) ) /4   / / a r e a i n mmˆ 2

75

Page 77: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 77/126

17   l = s ig ma d *a   // l oa d i n kN

18   s = 0.65   // d ra wi ng s p ee d i n m/ s19   w = l * s   // work i n kJ / s20   p = w   / / p ow er i n kW21   printf ( ” \n D ra wi ng l o a d = %0 . 3 f kN\n P ower r a t i n g o f  

motor = %0. 2 f kW”   , l , p )

22   // ’ Ans wers v ar y due t o ro un d o f f e r r or ’

Scilab code Exa 13.9  To calculate forging loads

1   clc

2   s ig ma _0 = 50   // p r e s s u r e a t s t a r t i n MPa3   B = 0.9   // w i d th i n m4   h 1 = 0.2   // t h i c k n e ss i n m5   b = 0.3   // t o o l b i t e i n m6   / / At commencement o f f o r g i n g7   F L = s i g ma _ 0 * B * b * ( 1+ ( b / ( 4 * h 1 ) ) )   // f o r g i n g l o ad i n

MN8   / / At c om pl et i o n o f f o r g i n g9   h 2 = 0.1   // t h i c k n e ss i n m

10   s i g ma _ 0c = 1 50   // p r e s s u r e a t c o mp l et i on i n MPa11   F L 2 = s i g ma _ 0 c * B * b * ( 1+ ( b / ( 4 * h 2 ) ) )   // f o r g i n g l oa d i n

MN12   printf ( ” \n F or gi ng l oa d a t s t a r t o f f o r g i n g = %0 . 4 f  

MN\n F or gi ng l oa d a t c om pl et i o n o f f o r g i n g = %0 . 3f MN”   , FL , FL2 )

Scilab code Exa 13.10   Determine extrusion load

1   clc

2   s ig ma _0 = 2 50   / / N/mmˆ23   d 1 = 5   / / i n i t i a l w i r e d i a m e t e r i n mm4   d 0 = 15   // f i n a l w ir e d ia me te r i n mm

76

Page 78: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 78/126

5   r 0 = d0 /2

6   r 1 = d1 /27   x = ( r0 / r1 ) ^2   / / mm8   a lp ha = 45   // a ng l e o f c on t a c t9   a lp ha = a lp ha * % pi / 1 80

10   m u = 0.1   // c o e f f i c i e n t o f f r i c t i o n11   B = mu *cotg ( a l p h a )

12   s ig m a_ x 0 = ( s i g ma _0 * ( 1 + B) * (1 - ( x ) ^B ) ) /B   / / N/mmˆ213   s i gm a_ x 0 = - s i gm a _x 0

14   l = 37.5   / / l e n g t h 0 f b i l l e t i n mm15   t a u1 = s i gm a_ 0 / 2   // Mpa16   P e = s ig ma _x 0 + ( 4* t au 1 *l )/ d0   // e x t r us i o n p r e s s ur e

in Mpa17   e l = P e * %p i *( r 0 ) ^2   // e x t r us i o n l oa d i n MN18   printf ( ” \n E x t r u s i o n l o a d = %d MN”   , e l / 1 0 00 0 )

Scilab code Exa 13.11  To find roll pressures

1   clc

2   h 0 = 4. 05   // t h i c k n e s s o f p l a te i n mm

3   h 1 = 3. 55   / / mm4   D = 500   // r o l l e d d ia me te r i n mm5   r = D /2   // r o l l e d r a di u s i n mm6   m u = 0. 04   // c o e f f i c i e n t o f f r i c t i o n7   s i gm a = 2 10   / / N/mmˆ28   d e l ta _ h = h0 - h 1   // mm9   p = 2* s ig ma / sqrt (3)   / / N/mmˆ2

10   a l ph a =   acos ( 1 - ( d e l t a _ h / D ) )   // a n g l e o f c o n t a c t11   H o = 2* sqrt ( r / h 1 ) * atan ( sqrt ( r / h 1 ) * a l p h a )

12   Hn1 = ( Ho - ( log ( h 0 / h 1 ) ) / m u ) / 2

13   t h et a =   sqrt ( h 1 / r ) * tan ( sqrt ( h 1 / r ) * ( H n 1 / 2 ) )   //r a d i a n s14   hn = h1 + 2* r*(1 - cos ( t h e t a ) )   / / mm15   pn1 = p * hn * exp ( m u * H n 1 ) / h 1   / / r o l l p r e s s u r e i n N/mmˆ 216   / / b ) r o l l p r e s s u r e when c o e f f i c i e n t o f f r i c t i o n i s

77

Page 79: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 79/126

0 . 4

17   m u2 = 0.4   // c o e f f i c i e n t o f f r i c t i o n18   Hn2 = ( Ho - ( log ( h 0 / h 1 ) ) / m u 2 ) / 2

19   t h et a =   sqrt ( h 1 / r ) * tan ( sqrt ( h 1 / r ) * ( H n 2 / 2 ) )   //r a d i a n s

20   hn2 = h1 + r * th et a ^2   // mm21   p n 2 = ( p * hn 2 *exp ( m u 2 * H n 2 ) ) / h 1   // r o l l p r e s s u r e i n N/

mmˆ222   // c ) i f t e n s i o n i s a p p l i e d o f 35 N/mmˆ223   s ig ma _f = 35   // f r o n t t e n s i o n i n N/mmˆ 224   p n3 = ( p - s ig m a_ f ) * hn * exp ( m u * H n 1 ) / h 1   // r o l l r e s s u r e

i n N/mmˆ2

25   printf ( ” \n ( a ) R ol l p r e s s u r e a t e n t e r and e x i t = %0. 1 f N/mmˆ2 \ n R o l l p r e s s ur e a t n e u t r a l p la n e =%0 . 2 f N/mmˆ2 ”   , p , p n 1 )

26   printf ( ” \n ( b ) R ol l p r e s s u r e a t n e u t r al p oi nt whenco− e f f i c i e n t of f r i c t i o n i s 0. 40 = %0. 2 f N/mmˆ2”, pn2 )

27   printf ( ” \n ( c ) R o l l p r e s s u r e when 3 5 N/mmˆ 2 t e n s i o ni s a p p l i e d a t n e u t r a l p o i n t = %0 . 2 f N/mmˆ 2 ”   , pn3

)

28   // ’ Ans wers v ar y due t o ro un d o f f e r r or ’

Scilab code Exa 13.12   Determine neutral plane

1   clc

2   h 1 = 6. 35   // t h i c k n e s s i n mm3   m u = 0.2   // c o e f f i c i e n t o f f r i c t i o n4   r = 5 0   // r o l l e d r a d i u s i n cm5   r = r *10   / / mm

6   R = 3 0   // r e du c t io n i n p e rc e n t7   h 0 = h 1 * 10 0/ (1 00 - R )   / / mm8   d e l ta _ h = h0 - h 1   // mm9   a l ph a =   acos ( 1 - ( d e l t a _ h / ( 2 * r ) ) )   // a ng l e o f c on t a c t

10   H o = 2* sqrt ( r / h 1 ) * atan ( sqrt ( r / h 1 ) * a l p h a )

78

Page 80: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 80/126

11   H n = ( Ho - ( log ( h 0 / h 1 ) ) / m u ) / 2

12   t h et a =   sqrt ( h 1 / r ) * tan ( sqrt ( h 1 / r ) * ( H n / 2 ) )   // n e u t ra lp l a ne i n r a di a n s13   t he ta = t he ta * 1 8 0/ % p i   // n e ut r al p la ne i n d e g r e e s14   printf ( ” \n N e ut r al p l an e = %0 . 2 f d e g re e ”   , t he ta )

15   // ’ Ans wers v ar y due t o ro un d o f f e r r or ’

79

Page 81: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 81/126

Chapter 14

Theory of metal cutting

Scilab code Exa 14.1  calculate the tool life

1   clc

2   v 1 = 18   // c u t t i n g s pe ed i n m/ min3   t 1 = 3   / / t o o l l i f e i n h ou rs4   n = 0. 12 5   / / e x po n en t5   c = v1 * ( t1 * 60 ) ^n   // c o n st a n t6   v 2 = 24   // c u t t i n g s pe ed i n m/ min

7   t = ( c / v2 ) ^ ( 1/ 0 .1 2 5)   // t o o l l i f e i n min .8   printf ( ” T ool l i f e = %d min . ”   , t )

Scilab code Exa 14.2  Calculate the optimum cutting speed

1   clc

2   c_t = 8   // t o o l c ha ng e t im e i n min .3   r_t = 5   // t o o l r e −g r i n d t im e i n min .4   m r_c = 5   // ma ch in e r un ni ng c o s t p er h ou r5   d = 3 0   // t o t a l d e pr e c i a t i o n p e r r e −g ri nd i n p a i s a6   n = 0.25   / / e x po n en t7   c = 150   // c o n st a n t

80

Page 82: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 82/126

8   c _ c = m r_ c * c _t / 6 0   // t o t a l c h an g e c o st i n Rs

9   r _ c = m r_ c * r _t / 6 0   // r e g r i n d c o s t i n Rs10   c t = c _c + r _c + d / 10 0   // t o o l i n g c o s t i n Rs11   c m = m r_ c /6 0   // m ac hi ni ng c o s t i n Rs12   v = c * (( c m * n) / ( ct * (1 - n ) ) ) ^n   // c u t t i n g s pe ed i n m/

min .13   printf ( ” \n C u t t i n g s p e e d = %0 . 1 f m/ min . ”   , v )

Scilab code Exa 14.3  To find different orthogonal cutting picture

1   clc

2   m u1 = 0 .1 5   // c o e f f i c i e n t o f f r i c t i o n3   m u2 = 0 .1 8   / / c o e f f i c i e n t o f f r i c t o n4   a lp ha = 14   // a ng l e o f c on t a c t i n d e g re e5   a lp ha = a lp ha * % pi / 1 80

6   b ita = 10   / / s em i−c o ne a n gl e i n d e g r e e7   b it a = b it a * %p i / 18 0

8   s i g ma _ 0 = 1 .4 0   / / kN/mmˆ29   h 0 = 1.5   //mm

10   h 1 = 1   / / mm

11   B = ( mu 1 + mu 2 )/( tan ( a l p h a ) + tan ( b i t a ) )12   s i g m a d = ( s i g m a_ 0 * ( 1 + B ) * (1 - ( h 1 / h 0 ) ^ B ) ) / B   / / d r aw i ng

s t r e s s i n kN /mmˆ 213   d 1 = 11   // o u t s i d e d i am et er i n mm14   t = 1   // t h i c k n e s s i n mm15   d 2 = d1 - t   / / mm16   a = ( % pi * ( ( d1 ) ^ 2 -( d 2 ) ^2 ) ) /4   / / a r e a i n mmˆ 217   l = s ig ma d *a   // l oa d i n kN18   s = 0.65   // d ra wi ng s p ee d i n m/ s19   w = l * s   // work i n kJ / s

20   p = w   / / p ow er i n kW21   printf ( ” \n D ra wi ng l o a d = %0 . 3 f kN\n P ower r a t i n g o f  motor = %0. 2 f kW”   , l , p )

22   clc

23   t = 0. 12 7   // u ncu t c h ip t h i c k n e s s i n mm

81

Page 83: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 83/126

24   b = 6.35   // wi dt h o f c ut i n mm

25   v = 2   // c u t t i n g s pe ed i n m/ s26   a lp ha = 10   // r a ke a ng l e i n d e g r ee s27   f c = 567   // c u t t i n g f o r c e i n N28   f t = 227   // t h r u s t f o r c e i n N29   t c = 0 .2 28   // c hi p t h i c k n e s s i n mm30   r = t / tc   // c hi p t h i c k n e ss r a t i o31   a lp ha = a lp ha * % pi / 1 80   // r ak e a ng l e i n r a di a ns32   p hi =   atan ( r * cos ( a l p h a ) / ( 1 - ( r * sin ( a l p h a ) ) ) )   // s h e ar

a n g l e33   p hi 1 = p hi * 1 8 0/ % p i   // s h ea r a n gl e34   printf ( ” \n S he ar a n g le = %0 . 2 f d e g re e ”   , p hi 1 )

35   m u = (( f c * sin ( a l p h a ) + f t * cos ( a l p h a ) ) / ( f c * cos ( a l p h a ) - f t* sin ( a l p h a ) ) )   // c o e f f i c i e n t o f f r i c t i o n

36   b i ta =   atan ( m u )   / / f r i c t i o n a n g l e37   b it a = b it a * 1 80 /( % p i )

38   printf ( ” \n F r i c t i o n a n gl e = %0 . 2 f d e g r e e ” , b i t a )

39   f s = fc *cos ( p h i ) - f t *sin ( p h i )   // s h ea r f o r c e i n N40   ta us = ( fs * sin ( p h i ) ) / ( b * t )   // s he ar s t r e s s41   printf ( ” \n S h e a r s t r e s s = %0 . 1 f N/mmˆ 2 ”   , t au s )

42   c p = fc * v /1 00 0   // c u t t i n g power i n kw43   printf ( ” \n C u t ti n g p ow er = %0 . 3 f kw ”   , c p )

44   v c = v * r  // c hi p v e l o c i t y i n m/ s45   printf ( ” \n Chip v e l o c i t y = %0 . 3 f m/ s ” , v c )

46   ss =   cotg ( ph i ) +   tan ( p h i - a l p h a )   // s he ar s t r a i n47   printf ( ” \n s h e ar s t r a i n = %0 . 3 f ”   , s s )

48   spl = t /sin ( p h i )   // s h ea r p la ne l e ng t h49   v s = v * cos ( a l p h a ) / cos ( p h i - a l p h a )   // s he ar v e l o c i t y50   S = vs * 10 / sp l   // s he ar s t r a i n r a t e51   S = S *1 0^ 3   // s he a r s t r a i n r a t e52   printf ( ” \n S h e a r s t r a i n r a t e = %. 3 f s ˆ−1”   , S )

53   // ’ Ans wers v ar y due t o ro un d o f f e r r or ’

Scilab code Exa 14.4  To find tool life

82

Page 84: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 84/126

1   clc

2   v = 3 0   // c u t t i n g s pe ed i n m/ min3   f e ed = 0 .3   / / f e e d r a t e i n mm/ r e v .4   d = 2.5   // d ep th o f c ut i n mm5   t = 6 0   // t o o l l i f e i n min .6   c = v * t ^ 0 . 13 * f e e d ^ 0 . 77 * d ^ 0 . 3 7   // c o n st a n t7   printf ( ” \n c o n st a n t = %0 . 2 f ”   , c )

8   v 2 = v *1. 2   // c u t t i n g s pe ed i n m/ min9   t 2 = ( c / ( v 2 * f ee d ^ 0 . 7 7* d ^ 0 . 3 7 ) )   / / t o o l l i f e when

c u t t i n g s pe ed i n c r e a s e d by 20% i n min .10   t 2 = t 2 ^ (1 / 0. 1 3)

11   f 2 = f ee d *1 .2   / / f e e d r a t e i n mm/ r e v .

12   t 3 = ( c /( v * d ^ 0. 37 * f 2 ^ 0. 7 7) )   // t o o l l i f e when f e e dr a t e i n c r e a s e d by 20% i n min .

13   t 3 = t 3 ^ (1 / 0. 1 3)

14   d 2 = d *1. 2   // d ep th o f c ut i n mm15   t 4 = ( c / ( v * f ee d ^ 0 . 7 7* d 2 ^ 0 . 3 7 ) )   / / t o o l l i f e when

d ep th o f c ut i n c r e a s e d by 20% i n min .16   t 4 = t 4 ^ (1 / 0. 1 3)

17   t 5 = ( c / ( v 2 * d2 ^ 0 . 3 7* f 2 ^ 0 . 7 7 ) )   / / t o o l l f e i n min .18   t 5 = t 5 ^ (1 / 0. 1 3)

19   printf ( ” \n To ol l i f e when c u t t i n g s pe ed i n c r e a s e d by

20 = %0. 2 f min . ”  , t 2 )

20   printf ( ” \n To ol l i f e when f e e d r a t e i n c r e a s e d by 20= %0. 2 f min . ”   , t 3 )

21   printf ( ” \n To ol l i f e when d ep th o f c ut i n c r e a s e d by20 = %0. 2 f min . ”   , t 4 )

22   printf ( ” \n Too l l i f e when a l l t ak en t o g e t h e r a f t e ri n c r e a s i n g by 2 0 = %0 . 2 f min . ”   , t 5 )

23   // ’ Ans wers v ar y due t o ro un d o f f e r r or ’

Scilab code Exa 14.5  find force and coefficient of friction

1   clc

2   t = 0.25   // u nc ut c h ip t h i c k n e s s i n mm

83

Page 85: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 85/126

3   b = 2.5   // w id th o f c ut i n mm

4   v = 2.5   // c u t t in g s pe ed i n m/ s5   a lp ha = 10   // r a ke a ng l e i n d e g r ee s6   f c = 11 30   // c u t t i n g f o r c e i n N7   f t = 295   // t h r u s t f o r c e i n N8   t c = 0. 45   // c hi p t h i c k n e s s i n mm9   r = t / tc   // c hi p t h i c k n e ss r a t i o

10   a lp ha = a lp ha * % pi / 1 80   // r ak e a ng l e i n r a di a ns11   p hi =   atan ( ( r * cos ( a l p h a ) ) / ( 1 - r * sin ( a l p h a ) ) )   // s h e ar

a n g l e12   p hi 2 = p hi * 1 8 0/ % p i   // s h ea r a n gl e13   f s = fc *cos ( phi ) - ft * sin ( p h i )   / / s he ar f o r c e i n N

14   printf ( ” \n F or ce o f s h ea r a t s h ea r p l a ne = %0 . 2 f N”, f s )

15   mu =   atan ( ( f c * sin ( a l p h a ) + f t * cos ( a l p h a ) ) / ( f c * cos (

a l p h a ) - f t * sin ( a l p h a ) ) )   // f r i c t i o n a n g l e l e16   printf ( ” \n F r i c t i o n a n gl e = %0 . 3 f d e g r e e ” , m u )

17   // ’ Ans wers v ar y due t o ro un d o f f e r r or ’

Scilab code Exa 14.6  To find terms of orthogonal cutting

1   clc

2   t = 0.2   // u nc ut c h ip t h i c k n e s s i n mm3   a lp ha = 15   // r a ke a ng l e i n d e g r ee s4   t c = 0. 62   // c hi p t h i c k n e s s i n mm5   r = t / tc   // c hi p t h i c k n e ss r a t i o6   c rc = 1/ r   / / c h i p r e d u c t i o n c o e f f i c i e n t7   printf ( ” \n C ut ti ng r a t i o = %0 . 3 f   \n Chip r e d u c t io n co

− e f f i c i e n t = %0 . 1 f ”   , r , crc )

8   a lp ha = a lp ha * % pi / 1 80   // r ak e a ng l e i n r a di a ns

9   p hi =   atan ( r * cos ( a l p h a ) / ( 1 - r * sin ( a l p h a ) ) )   // s h e ara n g l e10   p h i = p hi * 1 80 / % pi   // s h ea r a n gl e11   printf ( ” \n S he ar a n g le = %0 . 2 f d e g re e ”   , phi )

12   ss =   cotg ( p h i * % pi / 1 8 0 ) +   tan ( ( p h i * % p i ) / 1 8 0 - ( a l p h a *

84

Page 86: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 86/126

% p i ) / 1 8 0 )   // s he ar s t r a i n

13   printf ( ” \n s h e ar s t r a i n = %0 . 3 f ”   , s s )14   // ’ Ans wers v ar y due t o ro un d o f f e r r or ’

Scilab code Exa 14.7  To solve tool life equation

1   clc

2   v 1 = 25   // c u t t i n g s pe ed i n m/ min3   t 1 = 90   // t o o l l i f e i n min .

4   v 2 = 35   // c u t t i n g s pe ed i n m/ min5   t 2 = 20   // t o o l l i f e i n min6   n =   log ( v 2 / v 1 ) / log ( t 1 / t 2 )   / / e x po n en t7   C = v1 * ( t1 ) ^n   // c o n st a n t8   t = 6 0   // t o o l l i f e i n min .9   v = C /( t) ^n   / / c u t t i n g s p ee d i n m/ min .

10   printf ( ” \n n = %0 . 3 f   \n C = %0 . 1 f   \n C ut ti ng s pe ed =%0 . 2 f m/min . ”   , n , C ,v )

11   // ’ Ans wers v ar y due t o ro un d o f f e r r or ’

Scilab code Exa 14.8   Determine normal and tangential force

1   clc

2   t = 0.5   // u nc ut c h ip t h i c k n e s s i n mm3   b = 3   // w id th o f c ut i n mm4   a lp ha = 15   // r a ke a ng l e i n d e g r ee s5   a lp ha = a lp ha * % pi / 1 80   // r ak e a ng l e i n r a di a ns6   r = 0. 38 3   // c hi p t h i c k n e s s r a t i o7   m u = 0.7   / / a v e r a g e c o e f f i c i e n t o f f r i c t i o n o n t o o l

f a c e8   b i ta =   atan ( m u )   / / f r i c t i o n a n g l e9   t au = 280   // y i e l d s t r e s s i n N/mmˆ2

10   p hi =   atan ( ( r * cos ( a l p h a ) ) / ( 1 - r * sin ( a l p h a ) ) )   // s h e ara n g l e

85

Page 87: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 87/126

11   f c = ( t a u * b * t ) /( s e c ( b it a - a l ph a ) * cos ( p h i + b i t a - a l p h a ) *

sin ( p h i ) )   // c u t t i n g f o r c e i n N12   f t = ( fc * (mu - tan ( a l p h a ) ) ) / ( 1 + m u * tan ( a l p h a ) )   //t h r u s t f o r c e i n N

13   F = fc *sin ( a l p h a ) + f t * cos ( a l p h a )   // t a n g e n t i a l f o r c eon t o o l f a c e i n N

14   F =   ceil ( F )

15   N = fc *cos ( a l p h a ) - f t * sin ( a l p h a )   // no rmal f o r c e ont o o l f a c e i n N

16   printf ( ” T a n ge nt i al f o r c e on t o o l f a c e = %d N\nn or ma l f o r c e on t o o l f a c e = %0 . 1 f N”   , F , N )

17   // ’ Ans wers v ar y due t o ro un d o f f e r r or ’

Scilab code Exa 14.9  To find cutting and thrust force

1   clc

2   t = 0.25   // u nc ut c h ip t h i c k n e s s i n mm3   b = 0.5   // w i d th o f c ut i n cm4   v = 8.2   / / c u t t i n g s p ee d i n m/ min .5   a lp ha = 20   // r a ke a ng l e i n d e g r ee s

6   a l p h a2 = a l ph a * % p i / 1 80   // r ak e a n g l e i n r a d i an s7   r = 0. 35 1   // c u t t i n g r a t i o8   p hi =   atan ( r * cos ( a l p h a 2 ) / ( 1 - r * sin ( a l p h a 2 ) ) )   // s h e ar

a ng le i n r a d ia ns9   p hi 2 = p hi * 1 8 0/ % p i   // s he ar a n g l e i n d e g r e e s

10   a l p h a2 = a l ph a * % p i / 1 80   // r ak e a n g l e i n r a d i an s11   b it a = 3 5+ a l ph a - p h i2   // d e g r e es12   s =   cotg ( p hi ) +   tan ( p h i - a l p h a 2 )   // s he ar s t r a i n13   e = s / sqrt (3)   // n a tu r a l s t r a i n14   s ig ma = 7 84 *( e ) ^ 0 .1 5   // t e n s i l e p r o p e r ty i n N/mmˆ 2

15   t a u = s ig ma / sqrt (3)   // y i e l d s h ea r s t r e s s i n N/mmˆ216   A s = ( b *1 0* t ) /sin ( p h i )   // s h e a r p l a n e a r e a i n mmˆ 217   Fs = ta u* As   // s he ar g o r ce i n N18   R = Fs /cos ( p h i + ( b i t a * % p i / 1 8 0 ) - a l p h a 2 )

19   F c = R * cos ( ( b i t a * % p i / 1 8 0 ) - a l p h a 2 )   // c u t t i n g f o r c e

86

Page 88: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 88/126

i n N

20   F t = R * sin ( ( b i t a * % p i / 1 8 0 ) - a l p h a 2 )   // t h r u s t f o r c e i nN21   printf ( ” \n C u tt i ng f o r c e = %0 . 1 f N\n Th ru st f o r c e =

%0. 1 f N”   , Fc , Ft )

22   // ’ Ans wers v ar y due t o ro un d o f f e r r or ’

Scilab code Exa 14.10  find terms of orthogonal rake system

1   clc2   f = 0.2   / / f e e d i n mm/ r e v .3   t = 0.2   // u nc ut c h ip t h i c k n e s s i n mm4   a lp ha = 10   // r a ke a ng l e i n d e g r ee s5   f c = 16 00   // c u t t i n g f o r c e i n N6   f t = 850   // t h r u s t f o r c e i n N7   t c = 0. 39   // c hi p t h i c k n e s s i n mm8   r = t / tc   // c hi p t h i c k n e ss r a t i o9   d = 2   // d ep th o f c ut i n mm

10   b = 2   // mm11   a l p h a2 = a l ph a * % p i / 1 80   // r ak e a n g l e i n r a d i an s

12   p hi =   atan ( r * cos ( a l p h a 2 ) / ( 1 - r * sin ( a l p h a 2 ) ) )   // s h e ara ng l e i n r a d i an s

13   p hi 2 = p hi * 1 8 0/ % p i   // s he ar a n g l e i n d eg re e14   f s = fc *cos ( p h i ) - f t *sin ( p h i )   // s h ea r f o r c e i n N15   f n = fc *sin ( p h i ) + f t *cos ( p h i )   // nor mal f o r c e i n N16   f = fc *sin ( a l p h a 2 ) + f t * cos ( a l p h a 2 )   / / f r i c t i o n f o r c e

i n N17   m u = (( f c * tan ( a l p h a 2 ) + f t ) / ( f c - f t * tan ( a l p h a 2 ) ) )   //

k i n e t i c c o e f f i c i e n t of f r i c t i o n18   s = fc / (b * t)   / / s p e c i f i c c u t t i n g e n e r g y i n N/mmˆ 2

19   printf ( ” \n S he ar f o r c e = %d N\n No rma l f o r c e = %0 . 1 f  N\n F r i c t i o n f o r c e = %0 . 1 f N\n K i n e t i cc o e f f i c i e n t o f f r i c t i o n = %0. 3 f ”   , fs , f n ,f ,

 mu )

20   printf ( ” \n S p e c i f i c c u t t i n g e n er g y = %d N/mmˆ2 ”   , s )

87

Page 89: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 89/126

21   // ’ Ans wers v ar y due t o ro un d o f f e r r or ’

Scilab code Exa 14.11   Calculate CLA

1   clc

2   c s = 20   // s i d e c u t t i n g e d g e a ng l e i n d eg r e e3   c e = 30   // end c u t t i n g e d ge a n gl e i n d e g r e e4   f = 0.1   / / f e e d i n mm/ r e v .5   r = 3   // n os e r a d i u s i n mm

6   c s 2 = c s * %p i / 18 0   // s i d e c u tt i n g e d g e a n g l e i nr a d i a n s7   c e 2 = c e * %p i / 18 0   // end c u t t i n g e dg e a n gl e i n

r a d i a n s8   h = (1 -cos ( c e2 ) )* r + f * sin ( c e 2 ) * cos ( c e2 ) -   sqrt ( ( 2 * f

* r * ( sin ( c e 2 ) ) ^ 3 ) - ( ( f ^ 2 ) * ( sin ( c e 2 ) ) ^ 4 ) )

9   Ra = h /4   // C en tr e l i n e a v er a ge r o ug h ne s s i n mm10   printf ( ” \n C en tr e l i n e a v er a ge r o ug h ne s s = %0 . 2 f  

∗10 ˆ −6m”   , R a * 10 ^ 3)

11   // ’ Ans wers v ar y due t o ro un d o f f e r r or ’

Scilab code Exa 14.12  Calculate back and side rake angle

1   clc

2   i = 0   // i n c l i n a t i o n a ng le i n d eg re e3   a lp ha = 10   // o r th o go n al r ak e a n gl e i n d e g r e e4   l em da = 75   // p r i n c i p a l c u t t i n g e d g e a ng l e i n d eg r e e5   a lp ha = a lp ha * % pi / 1 80   // o r th o go n al r ak e a n gl e i n

r a d i a n6   l em da = l em da * % pi / 1 80   // p r i n c i p a l c u t t i ng e d g e

a n gl e i n r a di a n7   a l p ha _ b =   atan ( cos ( l e m d a ) * tan ( a l p h a ) + sin ( l e m d a ) * tan (

i ) )   // b ack r ak e a n gl e i n r a d ia n s

88

Page 90: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 90/126

8   a l p h a _b = a l p ha _ b * 1 8 0/ % p i   // back r ak e a n gl e i n

d e g r e e9   a l p ha _ s =   atan ( sin ( l e m d a ) * tan ( a l p h a ) -cos ( l e m d a ) * tan (

i ) )   // s i d e r a ke a ng l e i n r a di a ns10   a l p h a _s = a l p ha _ s * 1 8 0/ % p i   // s i d e r a ke a ng le i n

d e g r e e11   printf ( ” \n Back r a k e a n g l e = %0 . 2 f d e g r e e \n S i d e

r ak e a n g le = %0 . 2 f d e g re e ”   , a l p ha _ b , a l p h a _ s )

Scilab code Exa 14.13   Calculate inclination and rake angle

1   clc

2   a lp ha b = 8   // back r ak e i n d e g r e e3   a lp ha s = 4   // s i d e r a ke i n d eg re e4   c s = 15   // s i d e c u t t i n g e d g e a ng l e i n d eg r e e5   lemda = 90 - cs   // a pp ro ac h a n g l e i n d e gr e e6   a l p h ab = a l ph a b * % p i / 18 0   // back r ak e i n r ad i an7   a l p h as = a l ph a s * % p i / 18 0   // s i d e r ak e i n r ad i a n8   c s = c s * %p i / 18 0   // s i d e c u t t i n g e dg e a ng l e i n r ad i a n9   l em da = l em da * % pi / 1 80   // a pp ro ac h a n g le i n r a d ia n

10   a l ph a =   atan ( tan ( a l p h a s ) *sin ( l e m d a ) + tan ( a l p h a b ) * cos (l e m d a ) )   // o r th o go n al r ak e a n gl e i n r a di a n

11   a lp ha = a lp ha * 1 8 0/ % p i   // o r th o go n al r ak e a n gl e i nd e g r e e

12   i =   atan ( sin ( l e m d a ) * tan ( a l p h a b ) -cos ( l e m d a ) * tan (

a l p h a s ) )   // i n c l n a t i o n a ng l e i n r ad i a n13   i = i * 18 0/ % pi   // i n c l n a t i o n a n g l e i n d eg re e14   printf ( ” \n O th og on al r a k e a n g l e = %0 . 2 f d e g r e e \n

I n c l i n a t i o n a n gl e = %0 . 1 f d e g r ee ”   , alpha , i )

Scilab code Exa 14.14  find different powers and resistance

1   clc

89

Page 91: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 91/126

2   c s = 15   // s i d e c u t t i n g e d g e a ng l e i n d eg r e e

3   v = 0.2   // c u t t in g s pe ed i n m/ s4   f = 0.5   / / f e e d r a t e i n mm/ r e v .5   d = 3.2   // d ep th o f c ut i n mm6   f c = 1 5 9 3* ( f ) ^ 0 . 8 5* ( d ) ^ 0 . 98   // c u t t i n g f o r c e i n N7   p c = fc * v /1 00 0   // c u t t i n g power i n kw8   i t a _m t = 0 .8 5   // e f f i c i e n c y o f l a t he9   p m = pc / i ta _m t   / / m ot or p ow er i n kw

10   a = f * d   // a r ea o f u nc ut c h i o i n mmˆ211   r = fc /a   / / s p e c i f i c c u t t i n g r e s i s t a n c e i n N/mmˆ 212   p = pc / (a * v) / / u n i t p o we r i n W/ (mmˆ 3 ) ∗ s13   printf ( ” \n C u t ti n g p ow er = %0 . 3 f kw\n M ot or p ow er =

%0. 2 f kw\n S p e c i f i c c u t t i n g r e s i s t a n c e = %0 . 2 f N/mmˆ2\ n U ni t pow er = %0. 3 f W/(mmˆ3) ∗ s ”   , pc , p m , r ,p

)

14   // ’ Ans wers v ar y due t o ro un d o f f e r r or ’

Scilab code Exa 14.15  Calculate percentage increase in tool life

1   clc

2   C = 4003   n = 0 . 5

4   a =2   / / ( T1 /T2 ) ˆ n5   b = 2 ^ ( 1 / n )   / / T26   i = ( b -1 ) *1 00   // p e rc e n t ag e i n c r e a s e7   printf ( ” \n P e rc en t ag e i n c r e a s e = %d p e r ce n t ”   , i )

Scilab code Exa 14.16  To find percentage of total energy

1   clc

2   t = 0. 12 7   // u ncu t c h ip t h i c k n e s s i n mm3   b = 6.35   // wi dt h o f c ut i n mm4   v = 1.20   / / c u t t i n g s p ee d i n m/ min .

90

Page 92: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 92/126

5   a lp ha = 10   // r a ke a ng l e i n d e g r ee s

6   f c = 5 56 .2 5   // c u t t i n g f o r c e i n N7   f t = 2 22 .5 0   // t h r u s t f o r c e i n N8   t c = 0 .2 29   // c hi p t h i c k n e s s i n mm9   r = t / tc   // c hi p t h i c k n e ss r a t i o

10   R =   sqrt ( ( f c ^ 2 ) + ( f t ^ 2 ) )

11   b ita = ( acos ( f c /R ) ) + a lp ha * % p i / 18 0   //12   f = R * sin ( b i t a )   //13   f e = f * r   / / f r i c t i o n e n e r g y14   p = ( f* r *1 00 ) / fc   // p e r c e nt ag e o f f r i c t o n e n r gy and

t o t a l e ne rg y15   printf ( ” \n The p e rc e n t ag e o f t o t a l e ne rg y t ha t g oe s

i n t o o ve rc om in g f r i c t i o n a t t o o l c h ip i n t e r f a c e =%0 . 2 f p e r c e n t ”   , p )

16   // ’ Ans wers v ar y due t o ro un d o f f e r r or ’

Scilab code Exa 14.17  To find power and different energies

1   clc

2   D = 300   / / d i a m et e r i n mm

3   r = 4 5   / / r e v / m in .4   d = 2   // d ep th o f c ut i n mm5   f = 0.3   / / f e e d i n mm/ r e v6   f c = 18 50   // c u t t i n g f o r c e i n N7   f f = 450   // f e ed f o r c e i n N8   V = 2 .5 *1 0^ 6   / / m e t a l r em ov ed i n mm9   v = ( % pi * D * r) / ( 6 0* 1 00 0 )   // c u t t i n g v e l o c i t y i n m/ s

10   p c = f c* v /1 00 0   / / c u t t i n g power i n kW11   f v = f * r / 60 * 10 00   // f e e d v e l o c i t y i n m/ s12   f p = fv * ff   // f e ed power i n W

13   m rr = d * f *v * 6 0* 1 00 0   // mmˆ3 / min .14   c e = p c * 10 0 0* 6 0/ m r r   / / s p e c i f i c c u t t i n g e n er g y i n W∗s /mmˆ2

15   E = c e *V / ( 3 60 0 *1 0 00 )   / / e n e r g y c on su me d16   printf ( ” \n Po wer c o n s um p t i on = %0 . 2 f W\n S p e c i f i c

91

Page 93: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 93/126

c u t t i n g e n er g y = %0 . 2 f W∗ s /mmˆ3 \ n E n e rg y c on s um ed

= %0 . 3 f kWh”   , p c , c e , E )17   // ’ Ans wers v ar y due t o ro un d o f f e r r or ’

Scilab code Exa 14.18   Determine components of force and power

1   clc

2   D = 100   / / d i a m et e r i n mm3   c s = 30   // s i d e c u t t i n g e d g e a ng l e i n d eg r e e

4   lemda = 90 - cs   // a pp ro ac h a n g l e i n d e gr e e5   d = 2.5   // d ep th o f c ut i n mm6   f = 0. 12 5   / / f e e d i n mm/ r e v .7   N = 300   / / t u r ni n g s pe ed o f j o b i n r ev . / min .8   m u = 0.6   // c o e f f i c i e n t o f f r i c t i o n9   t au = 400   // u l t i m a te s h ea r s t r e s s i n Mpa

10   b i ta = a ta nd ( m u )   // f r i c t i o n a n g l e i n r a d i a n11   a l ph as = 10   // s i d e r ak e a ng l e12   a lp ha b = 6   // ba ck r a ke a n g le13   a l ph a = a t an d ( t a n d ( a l ph a s ) * s i nd ( l e m d a ) + t a nd ( a l p h a b ) *

c o s d ( l e m d a ) )   // o r th o go n al r ak e a n gl e i n d e g r ee

14   phi = 45 - ( bita - alpha )   // s h ea r a n gl e15   F c = t a u * d *f / ( s e cd ( b i ta - a l p ha ) * c o s d ( p h i + bi ta - a l p ha ) *

s i n d ( p h i ) )   // c u t t i n g f o r c e i n N16   F t = F c * ta nd ( b it a - a l ph a )   // t h r u s t component i n N17   F f = F t * si nd ( l e md a )   // f ee d f o r c e a lo n g a x i s o f j o b

i n N18   R f = F t * co sd ( l e md a )   // r a d i a l f o r c e normal t o a x i s

o f j o b i n N19   v = % pi * D * N / (1 0 00 * 60 )   // v e l o c i t y i n m/ s20   p = Fc *v   // p ower i n w a tt s

21   printf ( ” \n C ut ti ng f o r c e = %d N\n T hr us t f o r c e = %0. 3 f N\n Feed f o r c e = %0 . 1 f N\n R ad ia l f o r c e = %0. 3 f N\n C u t ti n g p ow er = %d w a t ts ”   , F c , Ft , F f , R f , p

)

22   // ’ Ans wers v ar y due t o ro un d o f f e r r or ’

92

Page 94: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 94/126

93

Page 95: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 95/126

Chapter 15

Design and manufacture of 

cutting tools

Scilab code Exa 15.1  calculate horsepower at cutter and motor

1   clc

2   w = 1 0   // w i dt h o f c ut i n cm3   h = 0.32   // de pt h o f c ut i n cm4   n = 8   // number o f t e e t h i n c u t t e r5   f t = 0 .0 33   // f e e d r a t e p er t oo th6   N = 200   // c u t t e r s pe ed i n rpm7   i ta = 6 0/ 10 0   // e f f i c i e n c y8   f = n * f t * N   / / f e e d r a t e i n cm/ min .9   mrr = w *h *f   // m e ta l r e mo v a l r a t e i n cm ˆ3 / min .

10   k = 8.2   // m a c h i n i b i l i t y f a c t o r from t a b l e 1 5 . 311   h pc = m rr / k   // h or se po we r a t c u t t e r12   h pm = h pc / it a   // h o rs e po w er a t mo to r13   printf ( ” \n H or se po we r a t c u t t e r = %0 . 2 f   \n H o r se p o we r

a t m o to r = %0 . 2 f ”   , hpc , hpm )

14   // ’ Ans wers v ar y due t o ro un d o f f e r r or ’

94

Page 96: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 96/126

Scilab code Exa 15.2  Determine broaching power and Design broach

1   clc

2   l = 3 5   // l e ng t h o f b or e i n mm3   v = 0.15   // c u t t i n g s pe ed i n m/ s4   t 1 = 0. 01   // u pp er l i m i t i n mm5   t 2 = 0. 05   // u pp er l i m i t i n mm6   D = 32 .2 5   // f i n i s h e d b ro ac h i n mm7   D 1 = 3 2. 25 + t2   / / mm8   d = 32 .7 5   // f i n i s h d ia me te r i n mm9   d1 = 32.75 + t1   // f i n i s h d ia me te r o f h o l e i n mm

10   s = 0.05   / / mm

11   B = 1.30   // b lu nt b ro ac h f a c t o r12   c = 4 5   / / s p e c i f i c c u t t i n g f o r c e i n N/mmˆ 213   n = 3   // number o f t e e t h c u t t i n g a t a t i me14   F = n * % pi * d 1 *s * c *B   // f o r c e n e e d e d f o r b ro ac hi ng i n

N15   b p = F * v /1 00 0   / / B r oa c hi n g p ower i n kw16   / / b ro ac h d e s i g n17   p = 1. 75 * sqrt ( l )   // p i t c h i n mm18   t he ta = 10   // f a c e a ng l e i n d eg r e e19   a l ha 1 = 1 .5   // r e l i e f a n g le f o r r o ug h in g i n d e gr e e20   a l ha 2 = 1 .0

  / / r e l i e f a n gl e f o r f i n i s h i n g i n d e g r e e21   w = 0.3* p   // w id th o f l an d i n mm22   h = 0.4* p   // de pt h o f c u t t i n g t e et h i n mm23   r = 0.3* p   / / t o o t h f i l l e t r a d i u s i n mm24   T = ( d1 - D 1) /2   / / mm25   n = T / s   // number o f c u t t i n g t e e t h26   n =   round ( n )

27   l = ( n +7) * p   // l e ng t h o f t oo th ed p o r ti o n o f b ro ac h i nmm

28   printf ( ” \n ( i ) Br oa c hi n g pow er = %0. 4 f kW” , b p )

29   disp ( ” ( i i ) B r oa c h D e s i g n ” )

30   printf ( ” ( a ) P i t ch d i a me t er = %0 . 2 fmm\n ( b ) wi dt h o f  l and = %0. 2 f mm   \n de pt h of c u t t i n g t e e t h =

%0 . 2 f mm\n Tooth f i l l e t r a d i u s = %0 . 2 f mm” , p , w

, h , r )

31   printf ( ” \n ( c ) Length o f t oo th ed p o r ti o n o f b ro ac h =

95

Page 97: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 97/126

%d mm” , l )

32   // ’ Ans wers v ar y due t o ro un d o f f e r r or ’

Scilab code Exa 15.3  Estimate moment thrust force and power

1   clc

2   H b = 200   // b r i n e l l h ar dn es s3   d = 12.7   / / d i a me t er i n mm4   f = 0. 25 4   / / f e e d i n mm/ r e v .

5   N = 100   // rpm6   M = ( H b *( d ) ^ 2* f ) /8   / / moment i n k g f  −mm7   k = 1.1   / / m a t e r i a l f a c t o r8   p = ( 1 . 25 * ( d ) ^ 2 * k * N * ( 0 .0 5 6 + 1. 5 * f ) ) / ( 1 0) ^ 5   / / p ow er

in kW9   T 1 a = ( 1. 7* M ) / d   // t h r us t f o r c e k gf  

10   T 1 b = ( 3. 5* M ) / d   // k gf  11   T 1 = ( T 1a + T 1b ) / 2   // a v e r ag e12   w = 0. 14 * d   // t h i c k n e s s i n mm13   T 2 a = ( 0 .1 * % p i * ( w ) ^ 2* H b ) / 4   // t h r u s t f o r c e k g f  14   T 2 b = ( 0 .2 * % p i * ( w ) ^ 2* H b ) / 4   // t h r u s t f o r c e k g f  

15   T 2 = ( T 2a + T 2b ) / 2   // a v e r ag e16   a vg = T1 + T2   // k gf  17   t h r u s t = 1 . 16 * k * d * ( 1 00 * f ) ^ 0 . 8 5   // k gf  18   printf ( ” \n Moment = %0. 1 f k gf  −mm\n P ow er = %0 . 3 f hp\

n A ve ra ge f o r c e = %d k g f  \n T hr us t f o r c e = %0 . 1 f  k g f ”   , M, p , avg , t hr us t)

19   / / E rr or i n t ex tb oo k

Scilab code Exa 15.4  Design shell inserted blade reamer

1   clc

2   d = 5 5   / / d i a me t e r i n mm3   u l = 0 .0 35   // u ppe r l i m i t i n mm

96

Page 98: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 98/126

4   l l = 0 .0 00   // l ow er l i m i t i n mm

5   D m ax = d + ul   / / maximum d i a m e t e r o f h o l e i n mm6   D m in = d + ll   // minimum d i a m e t e r o f h o l e i n mm7   I T = 0 .0 35   // h o le t o l e r e n c e i n mm8   d m ax = D ma x - 0 .1 5 * I T   // m aximum d i a m e t e r o f r e a me r i n

mm9   d m in = d ma x - 0 .3 5 * I T   // minimum d i a m e t e r o f r e am e r i n

mm10   l = ( ( d /4 ) +( d / 3) ) / 2   // l en g t h o f g ui di ng s e c t i o n i n

mm11   Z = 1.5* sqrt ( d ) + 2   // number o f t e e t h12   Z =   ceil ( Z )

13   printf ( ” \n 1 D ia me te r o f r ea me r   \n Maximum di am et ero f r e a me r = %0 . 3 f mm   \n M inimum d i a m e t e r o f  r e ame r = %0. 3 f mm   \n 2 Back t a p e r = 0 . 0 5 mm   \n 3V al ue s o f v a r i o u s a n g l es   \n Rake a n g l e = 5 d e g re e

\n Pl an a pp ro ac h a n g l e = 45 d e g re e   \n C i r c u l a rl an d = 0 . 2 5 t o 0 . 5 0 mm   \n S ec on da ry c l e a r a n c ea n g le = 1 0 d e g re e   \n 4 L en gth o f r ea me r   \n L e ng t h

o f f l u t e d p o r ti o n = 8 2 . 5 mm   \n L en gt h o f r ea mi nga l l o w a n c e = 0 . 1 8 mm   \n L engt h o f c u t t i n g s e c t i o n

= 2 . 2 5 mm   \n Le ng th o f g u i d in g s e c t i o n = %d mm   \

n 5 Number o f t e e t h = %d”  , d ma x , d m in , l , Z )

14   / / A nswer v ar y due t o ro un d o f f e r r o r

Scilab code Exa 15.5  To design single point cutting tool

1   clc

2   P m = 10   // power o f motor i n kw3   v = 4 0   / / c u t t i n g s p ee d i n m/ min .

4   i ta = 70   // e f f i c i e n c y5   i ta = i ta / 10 0

6   Pc = Pm * ita

7   F c = ( P c * 10 0 0* 6 0) / v   // c u t t i ng f o r c e8   s ig ma b = 2 50   // s t r e s s i n Mpa

97

Page 99: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 99/126

9   B =   sqrt ( ( F c * 1 . 2 5 * 6 ) / ( s i g m a b * 1 . 6 ) )   // w id th o f s ha nk

i n mm10   h = 1.6* B   // h i e g ht o f s ha nk i n mm11   l = 1. 25 * h   // s ha nk o v e ra n g i n mm12   printf ( ” \n The w i dt h o f s h an k = %0 . 1 f mm\n H ei gh t o f  

shank = %0. 2 f mm\n S ha nk o v e r h a n g = %0 . 1 f mm”   ,

B , h , l )

13   // ’ Ans wers v ar y due t o ro un d o f f e r r or ’

Scilab code Exa 15.8  find various terms for stainless steel

1   clc

2   l = 150   / / l e n g th i n mm3   D = 12 .7 0   / / d i a m et e r i n mm4   d i a = 1 2. 19   // d ia me te r on c e n tr e l a t h e i n mm5   N = 400   / / s p i n d l e s pe ed i n r ev . / min6   s = 2 03 .2 0   / / a x i a l s p e e d i n mm/ min.∗####7   v = ( % pi * D * N) / ( 1 00 0 *6 0 )   // c u t t i n g v e l o c i t y i n m/ s8   d = ( D- d ia ) /2   // d ep th o f c ut i n mm9   f = s / N   / / f e e d i n mm/ r e v .

10   D a ve = ( D + di a ) /2   // a v e r ag e d i a m et e r i n mm11   V = % pi * D av e *N

12   a = d * f   // a r ea o f c ut i n mmˆ213   mrr = a *V   / / m e t a l r e m o va l r a t e i n mmˆ 3 / min .14   T = l /( f* N)   / / m ac hi ne t i m i ng i n min .15   c = 5 6   // c o ns t an t fr om t a b l e16   p = d *f * v *6 0* c   // power i n w at ts17   o me ga = ( 2* % p i *N ) / 60   // rpm18   t = p / om eg a   // t o r qu e i n Nm19   F c = ( 2* t * 1 00 0) / D a ve   // c u t t i n g f o r c e i n N

20   printf ( ” \n C u t ti n g s p e ed = %0 . 2 f m/ s \n MRR = %d mmˆ3/ min . \ n Time t o c u t = %0 . 2 f min . \ n P ow er = %0 . 1f w at ts \ n C u tt i n g f o r c e = %d N”   , v , mrr , T ,p ,

Fc )

21   / / A ns wer s a r e g i v e n wrong i n b oo k

98

Page 100: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 100/126

Scilab code Exa 15.9  To find MRR power and torque

1   clc

2   f = 0.2   / / f e e d i n mm/ r e v .3   N = 800   / / s p i n d l e s p ee d i n r e v . / min .4   d = 1 0   // d oa me te r o f h o l e i n mm5   m rr = % pi * ( d ^2 ) * f* N /4   // m e ta l r e mo v a l r a t e i n mmˆ 3/

min .

6   m r r = m rr / 60   // mmˆ3 / s7   p = 0 .5 * mrr   // c u t t i n g power from t a b l e 1 4 . 2 i n

w a t t s8   o me ga = 2 * %p i * N /6 0   // rpm9   T = p / om eg a   // t or qu e i n N .m

10   printf ( ” \n MRR = %0 . 2 f mmˆ3 / s \n C u t t in g p ow er = %0 . 3f w at ts \n T o rq u e = %0 . 2 f N . m”   , mr r , p , T)

Scilab code Exa 15.10  find MRR power torque and time

1   clc

2   l = 300   / / l e n g th i n mm3   w = 100   / / w id t h i n mm4   f = 0.25   / / f e e d i n mm/ t o o t h5   d = 3.2   // d ep th o f c ut i n mm6   D = 5 0   // c u t t e r d i am et er i n mm7   n = 2 0   // number o f c u t t e r t e e t h8   N = 100   / / c u t t e r s p ee d i n r e v . / min .9   t f = f *n *N

  / / t a b l e f e e d i n mm/ min .10   m r r = w * d* tf   / / m e ta l r e mo v al r a t e i n mmˆ 3/ min .11   m r r = m rr / 60   // mmˆ3 / s12   p = 6* mrr   // c u t t i n g power from t a b l e 1 4 .2 i n w at ts13   o me ga = 2 * %p i * N /6 0   // rpm

99

Page 101: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 101/126

14   T = p / om eg a   // t or qu e i n N .m

15   a tt =   sqrt ( ( D * d ) - ( d ^ 2 ) )   // added t a b l e t r a v e l i n mm16   t = ( l+ a tt ) / tf   / / c u t t i n g t im e i n min .17   t = t *60   // s18   printf ( ” \n MRR = %0 . 2 f mmˆ3 / s \n C u t t in g p ow er = %d

w a t t s \n T or qu e = %0 . 2 f N . m\n C u tt i ng t im e = %0 . 1f s ”   , m rr , p , T , t )

100

Page 102: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 102/126

Chapter 16

Gear manufacture

Scilab code Exa 16.1  Calculate settings of gear tooth

1   clc

2   n = 3 4   // number o f t e e t h s3   m = 5   / / m od ul e i n mm4   w = m * n *sin   ( % p i / ( n * 2 ) )   / / t o o th t h i c k n e s s i n mm5   h = m *( 1+ (n *(1 -   cos ( % p i / ( n * 2 ) ) ) / 2 ) )   // c h o r da l

addendum in mm

6   printf ( ” \n To ot h t h i c k n e s s = %0 . 3 f mm\n C h or d aladdendum = %0 . 3 f mm”   , w , h)

7   // ’ Ans wers v ar y due t o ro un d o f f e r r or ’

101

Page 103: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 103/126

Chapter 17

Thread manufacturing

Scilab code Exa 17.1  Calculate best wire size

1   clc

2   d = 8 0   // o u t s i d e d i am e te r i n mm3   p = 6   // p i t c h d i am e te r i n mm4   d = 0 .5 77 4* p   // b es t w ir e s i z e i n mm5   printf ( ” \n B es t w i r e s i z e = %0 . 3 f mm”   , d )

Scilab code Exa 17.2  Calculate size and distances over wire

1   clc

2   D = 2 0   / / d i a me t e r i n mm3   p = 2.5   // p i t c h d i am et er i n mm4   d = 0 .5 77 4* p   / / mm5   W = D + 3* d - 1 .5 1 56 * p // b es t w ir e s i z e i n mm6   printf ( ” \n B es t w i re s i z e = %0 . 3 f mm\n D i s ta n ce o v er

w i r e s = %0. 3 f mm”   , d, W )

7   / / A nswer v ar y due t o ro un d o f f e r r o r

102

Page 104: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 104/126

Chapter 21

Statical quality control

Scilab code Exa 21.1  Construct R and X chart

1   clc

2   c l f ( )

3   n = 1 0   // number o f s a m p l es4   A 2 = 0 .5 77

5   D 3 = 0

6   D 4 = 2 .1 15

7   // n umber o f d e f e c t i v e s8   x 1 = 1 1. 27 4

9   x 2 = 1 1. 24 6

10   x 3 = 1 1. 20 4

11   x 4 = 1 1. 29 4

12   x 5 = 1 1. 25 2

13   x 6 = 1 1. 23 8

14   x 7 = 1 1. 23 0

15   x 8 = 1 1. 27 6

16   x 9 = 1 1. 20 8

17   x 10 = 1 1. 26 618   r 1 = 0. 15

19   r 2 = 0. 20

20   r 3 = 0. 33

21   r 4 = 0. 46

103

Page 105: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 105/126

22   r 5 = 0. 10

23   r 6 = 0. 1524   r 7 = 0. 20

25   r 8 = 0. 23

26   r 9 = 0. 50

27   r10 = 0 .3 0

28   x = x 1 + x 2 + x3 + x 4 + x 5 + x6 + x 7 + x 8 + x 9 + x 10

29   r = r 1 + r 2 + r3 + r 4 + r 5 + r6 + r 7 + r 8 + r 9 + r 10

30   Xa vg = x /n

31   Ra vg = r /n

32   / / f o r X c h ar t33   u cl 1 = X av g + A2 * R av g

34   l cl 1 = X av g - A2 * R av g35   / / f o r R c h ar t36   u c l2 = D 4 * Ra vg

37   l c l2 = D 3 * Ra vg

38   printf ( ” \n c o n t r o l l i m i t s   \n For X c h a r t s   \n UCL =%0. 2 f cm   \n LCL = %0. 2 f cm\n F o r R c h a r t s   \n UCl= %0. 3 f    \n LCL = %0. 3 f ”   , u cl 1 , l c l1 , u cl 2 , l c l 2 )

39   // X c h a rt40   x = [ 1 , 2 , 3 , 4 , 5 , 6 , 7 , 8 , 9 , 1 0 ] ;

41   y

= [ 1 1 . 2 7 4 , 1 1 . 2 4 6 , 1 1 . 2 0 4 , 1 1 . 2 9 4 , 1 1 . 2 5 2 , 1 1 . 2 3 8 , 1 1 . 2 3 0 , 1 1 . 2 7 6 , 1 1

42   plot ( x , y )

43   xtitle ( ”X c h a r t ” , ”Sampl e No . ” , ”X” )

44   // R c h a rt45   xset ( ”window” ,1 )

46   z =

[ 0 . 1 5 , 0 . 2 0 , 0 . 3 3 , 0 . 4 6 , 0 . 1 0 , 0 . 1 5 , 0 . 2 0 , 0 . 2 3 , 0 . 5 0 , 0 . 3 0 ]

47   plot ( x , z )

48   xtitle ( ” R c h a r t ”   , ”Sampl e no . ” ,   ”R” )

Scilab code Exa 21.2  Construct the control charts

104

Page 106: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 106/126

1   clc

2   c l f ( )3   n = 100   // t o t a l number o f sub g ro up s4   s = 1 0   // number o f s a m p l es5   // n umber o f d e f e c t i v e s6   d 1 = 3

7   d 2 = 2

8   d 3 = 3

9   d 4 = 5

10   d 5 = 3

11   d 6 = 3

12   d 7 = 2

13   d 8 = 414   d 9 = 3

15   d10 = 2

16   d = d 1 + d 2 + d3 + d 4 + d 5 + d6 + d 7 + d 8 + d 9 + d 10   // t o t a l numbero f d e f e c t i v e s

17   p 1 = d /( n *s )   // a ve ra ge f r a c t i o n o f d e f e c t i v e s18   s i g ma p 1 =   sqrt ( p 1 * ( 1 - p 1 ) / n )

19   uc l1 = p1 + 3* s ig ma p1

20   lc l1 = p1 - 3* s ig ma p1

21   // c o n t r o l c ha rt f o r f r a c t i o n d e f e c t i v e s22   x =   linspace ( 0 , 1 0 , 1 0 )

23   y =   linspace ( 0 , 0 . 0 8 1 , 1 0 )

24   plot ( x , y )

25   xtitle ( ” C on tr ol c ha r t f o r f r a c t i o n d e f e c t i v e s ”   ,   ”S a m p l e s ”   , ” F r a ct i o n d e f e c t i v e s ” )

26   // p e r ce n t d e f e c t i v e ( mean )27   p1 = p1 * 100

28   s i g ma p 2 =   sqrt ( p 1 * ( 1 0 0 - p 1 ) / n )

29   uc l2 = p1 + 3* s ig ma p2

30   lc l2 = p1 - 3* s ig ma p2

31   printf ( ” \n C o nt ro l l i m i t s   \n F ra c t i o n d e f e c t i v e s   \n

UCL = %0.3 f  \n LCL = %0.4 f   \n P er ce nt d e f e c t i v e s   \nUCL = %0.1 f   \n LCL = %0. 1 f ” , u cl 1 , l c l1 , u cl 2 , l c l2

)

32   // c o n t r o l c ha r t f o r p e r ce nt d e f e c t33   xset ( ”window”   ,1)

105

Page 107: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 107/126

34   z =   linspace ( 0 , 8 . 1 , 1 0 )

35   plot ( x , z )36   xtitle ( ” C o nt ro l c h ar t f o r p e rc e n t d e f e c t s ”   ,   ”Sampl eno . ”   ,   ” p e r c e n t d e f e c t s ” )

37   / / ’ Answers v a ry due t o round o f f e r ro r ’

Scilab code Exa 21.4   Calculate poisson probabilities

1   clc

2   n = 1000   // number o f u n i t s3   s = 4   / / r an do m s a m p l e4   d = 5 0   // d e f e c t i v e s5   z = d *s /n

6   p p0 =   exp ( - 0 . 2 ) * 1   // p oi ss on p r o b a b i l i t i e s f o r 0d e f e c t i v e s

7   p p1 =   exp ( - 0 . 2 ) * ( z )   // p oi ss on p r o b a b i l i t i e s f o r 1d e f e c t i v e s

8   p p2 =   exp ( - 0 . 2 ) * ( z ^ 2 / f a c t o r i a l ( 2 ) )   // p o i ss o np r o b a b i l i t i e s f o r 2 d e f e c t i v e s

9   p p3 =   exp ( - 0 . 2 ) * ( z ^ 3 / f a c t o r i a l ( 3 ) ) // p o i ss o n

p r o b a b i l i t i e s f o r 3 d e f e c t i v e s10   printf ( ” \n P r o a b i l i t i e s f o r 0 , 1 , 2 and 3 d e f e c t i v e s

a r e : %0 . 3 f , %0 . 4 f , %0 . 4 f , %0 . 5 f ”   , p p0 , p p1 , p p2 ,

p p 3 )

Scilab code Exa 21.5  Calculate probabilities of defective items

1   clc

2   d = 5 0   // d e f e c t i v e s3   l = 1000   // l o t o f p i e c e s4   p = d / l   // p r o a b i l i t y o f an e ve nt h ap pe n in g5   q = 1 - p   // p r o a b i l i t y o f an e ve nt no t h ap pe ni ng6   n = 4   // sa mp le s i z e

106

Page 108: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 108/126

7   p 0 = q ^ n   // p r o b a b i l i t i e s f o r 0 d e f e c t i v e s

8   p 1 = 4 *( q ) ^3 * p   // p r o b a b i l i t i e s f o r 1 d e f e c t i v e s9   p 2 = 6 *( q ) ^ 2* p ^ 2   // p r o b a b i l i t i e s f o r 2 d e f e c t i v e s10   p 3 = 4* q *( p ) ^3   // p r o b a b i l i t i e s f o r 3 d e f e c t i v e s11   printf ( ” \n P r o a b i l i t i e s f o r 0 , 1 , 2 and 3 d e f e c t i v e s

a r e : %0 . 4 f %0 . 4 f %0 . 4 f %0 . 6 f ”   , p0 , p 1 , p2 , p 3 )

Scilab code Exa 21.6  Determine producers and consumers risk

1   clc2   / / p ro d uc er ’ s r i s k3   n = 7 1   // s am pl e s i z e4   A Q L = 0 .0 05

5   L TP D = 0 .0 5

6   l _s = 500   // l o t s i z e7   z 1 = n * AQL   / / mean number o f d e f e c t s8   p p1 =   exp ( - z 1 ) + z 1 * exp ( - z 1 )   // p o i ss o n p r o a b i l i t y f o r

1 o r l e s s d e f e c t i v e9   a lp ha = ( 1 - pp 1 ) *1 00   / / p r od u ce r ’ s r i s k

10   a l ph a =   ceil ( a l p h a )

11   / / c on su me r ’ s r i s k12   z2 = n * LT PD   / / mean number o f d e f e c t s13   p p2 =   exp ( - z 2 ) + z 2 * exp ( - z 2 )   // p o i ss o n p r o a b i l i t y f o r

1 o r l e s s d e f e c t i v e14   b i ta = p p2 * 1 00   / / c on su me r ’ s r i s k15   printf ( ” \n P ro d uc er s r i s k = %d p e r ce n t \n C onsume rs

r i s k = %0 . 2 f p e r c e n t ” , a lp ha , b it a )

Scilab code Exa 21.7  Evaluate preliminary and revised control limits

1   clc

2   t d 1 = 2 0   // t o t a l number o f d ays3   n 1 = 200   // sa mpl e s i z e

107

Page 109: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 109/126

4   // n umber o f d e f e c t i v e s

5   d 1 = 106   d 2 = 15

7   d 3 = 10

8   d 4 = 12

9   d 5 = 11

10   d 6 = 9

11   d 7 = 22

12   d 8 = 4

13   d 9 = 12

14   d 10 = 24

15   d 11 = 21

16   d 12 = 1517   d13 = 8

18   d 14 = 14

19   d15 = 4

20   d 16 = 10

21   d 17 = 11

22   d 18 = 11

23   d 19 = 26

24   d 20 = 13

25   d = d 1 + d 2 + d3 + d 4 + d 5 + d6 + d 7 + d 8 + d 9 + d 10 + d 1 1 + d 1 2 + d 13 + d 1 4 +

d 1 5 + d 1 6 + d 1 7 + d 1 8 + d 1 9 + d 2 0  // t o t a l number o f  d e f e c t i v e s

26   p 1 = d /( n 1* t d1 )   // a ve r a ge f r a c t i o n o f d e f e c t i v e s27   s i g ma p 1 =   sqrt ( p 1 * ( 1 - p 1 ) / n 1 )

28   uc l1 = p1 + 3* s ig ma p1

29   lc l1 = p1 - 3* s ig ma p1

30   // r e v i s e d c o n t r o l l i m i t s31   t d2 = 18   // t o t a l number o f d ay s32   D = d - ( d10 + d19 )   // number o f d e f e c t s33   p 2 = D /( n 1* t d2 )

34   s i g ma p 2 =   sqrt ( p 2 * ( 1 - p 2 ) / n 1 )

35   uc l2 = p2 + 3* s ig ma p236   lc l2 = p2 - 3* s ig ma p2

37   printf ( ” \n P r e l i mi n a r y c o n t r o l l i m i t s   \n UCL = %0.3 f  \n LCL = %0.3 f    \n R e v is ed c o n t r o l l i m i t s   \n UCL

= %0. 3 f    \n LCL = %0. 3 f ”   , u cl 1 , l c l1 , u cl 2 , l c l 2 )

108

Page 110: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 110/126

Scilab code Exa 21.8  Find control limits for c chart

1   clc

2   n 1 = 15   // t o t a l number o f sub g ro up s3   // n umber o f d e f e c t i v e s4   d 1 = 77

5   d 2 = 64

6   d 3 = 75

7   d 4 = 938   d 5 = 45

9   d 6 = 61

10   d 7 = 49

11   d 8 = 65

12   d 9 = 45

13   d 10 = 77

14   d 11 = 59

15   d 12 = 54

16   d 13 = 84

17   d 14 = 40

18   d 15 = 92

19   d = d 1 + d 2 + d3 + d 4 + d 5 + d6 + d 7 + d 8 + d 9 + d 10 + d 1 1 + d 1 2 + d 13 + d 1 4 +

d15   // t o t a l number o f d e f e c t i v e s20   c 1 = d /n1

21   ucl1 = c1 + 3* sqrt ( c 1 )

22   lcl1 = c1 - 3* sqrt ( c 1 )

23   // r e v i s e d c o n t r o l l i m i t s24   n 2 = 12   // t o t a l number o f sub g ro up s25   D = d - ( d 4 + d 1 4 + d 1 5 )   // number o f d e f e c t s26   c 2 = D /n2

27   ucl2 = c2 + 3* sqrt ( c 2 )28   lcl2 = c2 - 3* sqrt ( c 2 )

29   printf ( ” \n P r e l i mi n a r y c o n t r o l l i m i t s   \n UCL = %0.2 f  \n LCL = %0.2 f    \n R e v is ed c o n t r o l l i m i t s   \n UCL

= %0. 3 f    \n LCL = %0. 3 f ”   , u cl 1 , l c l1 , u cl 2 , l c l 2 )

109

Page 111: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 111/126

Scilab code Exa 21.9  find control limits for charts

1   clc

2   n = 2 0   // number o f s a m p l es3   A = 1. 34 2

4   A 1 = 1 .5 96

5   A 2 = 0 .5 77

6   d 2 = 2 .3 26

7   d 3 = 0 .8 648   D 1 = 0

9   D 2 = 4 .9 18

10   D 3 = 0

11   D 4 = 2 .1 15

12   // n umber o f d e f e c t i v e s13   x 1 = 32 90

14   x 2 = 31 80

15   x 3 = 33 50

16   x 4 = 34 70

17   x 5 = 30 80

18   x 6 = 32 40

19   x 7 = 32 60

20   x 8 = 33 10

21   x 9 = 36 40

22   x 10 = 4 11 0

23   x 11 = 3 22 0

24   x 12 = 3 59 0

25   x 13 = 4 27 0

26   x 14 = 4 04 0

27   x 15 = 3 58 0

28   x 16 = 3 50 029   x 17 = 3 57 0

30   x 18 = 3 56 0

31   x 19 = 2 74 0

32   x 20 = 3 20 0

110

Page 112: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 112/126

33   r 1 = 560

34   r 2 = 41035   r 3 = 200

36   r 4 = 300

37   r 5 = 90

38   r 6 = 650

39   r 7 = 890

40   r 8 = 410

41   r 9 = 11 20

42   r 10 = 520

43   r 11 = 580

44   r 12 = 670

45   r 13 = 48046   r 14 = 250

47   r 15 = 170

48   r 16 = 670

49   r 17 = 440

50   r 18 = 660

51   r 19 = 560

52   r 20 = 590

53   x = x 1 + x 2 + x3 + x 4 + x 5 + x6 + x 7 + x 8 + x 9 + x 10 + x 1 1 + x 1 2 + x 13 + x 1 4 +

x 1 5 + x 1 6 + x 1 7 + x 1 8 + x 1 9 + x 2 0

54   r = r 1 + r 2 + r3 + r 4 + r 5 + r6 + r 7 + r 8 + r 9 + r 10 + r 1 1 + r 1 2 + r 13 + r 1 4 +

r 1 5 + r 1 6 + r 1 7 + r 1 8 + r 1 9 + r 2 0

55   Xa vg = x /n

56   Ra vg = r /n

57   / / f o r X c h ar t58   u cl 1 = X av g + A2 * R av g

59   l cl 1 = X av g - A2 * R av g

60   / / f o r R c h ar t61   u c l2 = D 4 * Ra vg

62   l c l2 = D 3 * Ra vg

63   // R e vi se d c o n t r o l l i m i t s

64   n 1 = 1565   n 2 = 19

66   X = ( x - ( x 5 + x1 0 + x1 3 + x1 4 + x1 9 ) )/ n 1

67   R = ( r - ( r9 )) /n2

68   / / f o r X c h ar t

111

Page 113: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 113/126

69   ucl3 = X + A2 *R

70   lcl3 = X - A2 *R71   / / f o r R c h ar t72   uc l4 = D4 *R

73   lc l4 = D3 *R

74   printf ( ” \n P r e l i mi n a r y c o n t r o l l i m i t s   \n For Xc h a r t s   \n UCL = %0.2 f    \n LCL = %0.2 f   \n F o r Rc h a r t s   \n UCl = %0. 3 f    \n LCL = %0.3 f    \n R e vi s edc o nt r ol l i m i t s   \n F o r X c h a r t   \n UCL = %0.3 f    \nLCL = %0. 3 f   \n F o r R c h a r t s   \n UCl = %0. 3 f    \n LCL= %0. 3 f ”   , u cl 1 , l c l1 , u cl 2 , l c l2 , u cl 3 , u c l3 , u cl 4 ,

l c l 4 )

75   / / ’ Answers v a ry due t o round o f f e r ro r ’

Scilab code Exa 21.10  Determine producers and consumers risk

1   clc

2   c l f ( )

3   n = 5 0   // s am pl e s i z e4   r n = 2   // r e j e c t i o n number

5   A QL = 0 .0 26   L TP D = 0 .0 8

7   / / P ro du ce r ’ s r i s k8   z 1 = n * AQL   // mean number o f d e f e c t i v e s9   p p1 =   exp ( - z 1 ) + z 1 * exp ( - z 1 )   // p o i ss o n p r o a b i l i t y f o r

1 o r l e s s d e f e c t i v e10   a lp ha = ( 1 - pp 1 ) *1 00   / / p r od u ce r ’ s r i s k11   / / c on su me r ’ s r i s k12   z2 = n * LT PD   // mean n umber o f d e f e c t i v e s13   b ita = ( exp ( - z 2 ) + z 2 *exp ( - z 2 ) ) * 1 0 0   / / c on su me r ’ s r i s k

14   d 1 = 1   // i nc om in g d e f e c t i v e i n p e rc e n t15   z 3 = n * d1 / 10 0   // a v er a ge number o f d e f e c t i v e16   p p a1 =   exp ( - z 3 ) + z 3 * exp ( - z 3 )   // p r o a b i l i t y o f  

a c c e p t a n c e17   p p a1 = p pa 1 * 10 0

112

Page 114: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 114/126

18   p p r1 = 1 00 - p p a1   // p r o a b i l i t y o f r e j e c t i o n

19   A OQ 1 = p pr 1 *0 + p pa 1 * d1 / 10 020   d 2 = 2   // i nc om in g d e f e c t i v e i n p e rc e n t21   z 4 = n * d2 / 10 0   // a v er a ge number o f d e f e c t i v e22   p p a2 =   exp ( - z 4 ) + z 4 * exp ( - z 4 )   // p r o a b i l i t y o f  

a c c e p t a n c e23   p p a2 = p pa 2 * 10 0

24   p p r2 = 1 00 - p p a2   // p r o a b i l i t y o f r e j e c t i o n25   A OQ 2 = p pr 2 *0 + p pa 2 * d2 / 10 0

26   d 3 = 4   // i nc om in g d e f e c t i v e i n p e rc e n t27   z 5 = n * d3 / 10 0   // a v er a ge number o f d e f e c t i v e28   p p a3 =   exp ( - z 5 ) + z 5 * exp ( - z 5 )   // p r o a b i l i t y o f  

a c c e p t a n c e29   p p a3 = p pa 3 * 10 0

30   p p r3 = 1 00 - p p a3   // p r o a b i l i t y o f r e j e c t i o n31   A OQ 3 = p pr 3 *0 + p pa 3 * d3 / 10 0

32   d 4 = 6   // i nc om in g d e f e c t i v e i n p e rc e n t33   z 6 = n * d4 / 10 0   // a v er a ge number o f d e f e c t i v e34   p p a4 =   exp ( - z 6 ) + z 6 * exp ( - z 6 )   // p r o a b i l i t y o f  

a c c e p t a n c e35   p p a4 = p pa 4 * 10 0

36   p p r4 = 1 00 - p p a4   // p r o a b i l i t y o f r e j e c t i o n37   A OQ 4 = p pr 4 *0 + p pa 4 * d4 / 10 0

38   d 5 = 8   // i nc om in g d e f e c t i v e i n p e rc e n t39   z 7 = n * d5 / 10 0   // a v er a ge number o f d e f e c t i v e40   p p a5 =   exp ( - z 7 ) + z 7 * exp ( - z 7 )   // p r o a b i l i t y o f  

a c c e p t a n c e41   p p a5 = p pa 5 * 10 0

42   p p r5 = 1 00 - p p a5   // p r o a b i l i t y o f r e j e c t i o n43   A OQ 5 = p pr 5 *0 + p pa 5 * d5 / 10 0

44   printf ( ” \n P ro d uc er s r i s k = %0 . 2 f p e r ce n t \nC on su me rs r i s k = %0 . 3 f p e r c e n t ” , a lp ha , b it a )

45   x = [ 1 ,2 , 4 ,6 , 8]

46   y = [ 0 .9 1 , 1 . 4 7 16 , 1 . 62 4 , 1 . 1 9 4 , 0 . 73 3 ]47   plot ( x , y )

48   xtitle ( ”AOQ cu rv e ” , ” P e rc en t d e c t i v e s ”   ,   ”AOQ of l o t ”)

113

Page 115: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 115/126

Chapter 22

Kinematics of machine tools

Scilab code Exa 22.1  Find range of cutting velocity

1   clc

2   d 1 = 10   / / min . d i a o f c u t t e r i n mm3   d 2 = 60   // max . d i a o f c u t t e r i n mm4   v = 30 e3   // o p e r a t i n g s p ee d i n m/ min5   n1 = v / ( %pi * d2 )   / / n mi n i n rpm6   n2 = v / ( %pi * d1 )   / / n max i n rpm

7   phi = ( n2 / n1 ) ^( 1/ 5)8   s p i n d l e _s p e e ds =   zeros ()

9   for   i = 0 : 5

10   s p in d le _ sp e ed s ( i + 1) = p hi ^ i * n 1

11   end

12   c ut te r_ di a = v . / ( % pi * s pi nd le _s pe ed s )

13   c l f ( )

14   y = [0; v ]

15   plot ( [0 ; c u tt e r_ d ia ( 1 ) ] , y , [ 0; c u tt e r_ d ia ( 2 ) ] , y ,

[ 0; c u tt e r_ d ia ( 3 ) ] , y , [ 0; c u tt e r_ d ia ( 4 ) ] , y , [ 0;

c u tt e r_ d ia ( 5 ) ] , y , [ 0; c u tt e r_ d ia ( 6 ) ] , y )16   xtitle ( ” ” , ” c u t t e r d i a m e t e r mm” , ” c u t t i n g v e l o c i t y , m/min” )

17   / / f ro m g r ap h18   v ma x1 = 36   // m/min

114

Page 116: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 116/126

19   v mi n1 = 2 4. 5   // m/min

20   r 1 = v ma x1 - v mi n1   // Range o f c u t t i n g s pe ed f o r 12mm d i a m e t e r i n m/ m in21   v ma x2 = 3 6. 5   // m/min .22   v mi n2 = 26   // m/min .23   r 2 = v ma x2 - v mi n2   // Range o f c u t t i n g s pe ed f o r 36

mm d i a m e t e r i n m/ m in24   printf ( ” \n Range o f c u t t i n g s pe ed f o r 12 mm d ia m et er

= %0. 1 f m/min . \ n R ange o f c u t t i n g s pe e d f o r 36mm di a me t e r = %0. 1 f m/min . ”   , r1 , r2 )

Scilab code Exa 22.2  Determine speed ratios and teeth

1   clc

2   m = 2.5   / / m od ul e i n mm3   p hi = 1.2   / / common r a t i o4   n = 150   // s pe ed i n r ev / min . o f d r i v i n g s h a f t5   n 1 = 70   // s pe ed i n r ev / min . o f d r iv e n s h a f t6   n 2 = ( p hi ) ^1 * n1   // s pe ed i n r ev / min . o f d r iv e n s h a f t7   n 3 = ( p hi ) ^2 * n1   // s pe ed i n r ev / min . o f d r iv e n s h a f t

8   n 4 = ( p hi ) ^3 * n1   // s pe ed i n r ev / min . o f d r iv e n s h a f t9   T1 = poly (0 , ’ T1 ’ )

10   t 1 = n 1 / n * T 1

11   T1 = roots ( t 1 + T 1 - 8 0 )

12   t1 = horner ( t 1 , T 1 )

13   T2 = poly (0 , ’ T2 ’ )

14   t 2 = n 2 / n * T 2

15   T2 = roots ( t 2 + T 2 - 8 0 )

16   t2 = horner ( t 2 , T 2 )

17   T3 = poly (0 , ’ T3 ’ )

18   t 3 = n 3 / n * T 319   T3 = roots ( t 3 + T 3 - 8 0 )

20   t3 = horner ( t 3 , T 3 )

21   T4 = poly (0 , ’ T4 ’ )

22   t 4 = n 4 / n * T 4

115

Page 117: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 117/126

23   T4 = roots ( t 4 + T 4 - 8 0 )

24   t4 = horner ( t 4 , T 4 )25   t1 =   floor ( t 1 )   // number o f t e et h on d r i v i n g s h a f t26   T1 =   ceil ( T 1 )   // number o f t e et h on d r iv e n s h a f t27   t2 =   ceil ( t 2 )   // number o f t e et h on d r i v i n g s h a f t28   T2 =   floor ( T 2 )   // number o f t e et h on d r iv e n s h a f t29   t3 =   floor ( t 3 )   // number o f t e et h on d r i v i n g s h a f t30   T3 =   ceil ( T 3 )   // number o f t e et h on d r iv e n s h a f t31   t4 =   ceil ( t 4 )   // number o f t e et h on d r i v i n g s h a f t32   T4 =   floor ( T 4 )   // number o f t e et h on d r iv e n s h a f t33   // r u n ni ng s p ee d s34   n 1 = n * t1 / T1

35   n 2 = n * t2 / T236   n 3 = n * t3 / T3

37   n 4 = n * t4 / T4

38   printf ( ” \n Number o f t e e t h on d r i v e r and d r iv e n a r e:− \n t 1 = %d , T1 = %d\n t 2 = %d , T2 = %d   \n t 3 =

%d , T3 = %d   \n t 4 = %d , T4 = %d ” , t 1 , T 1 , t 2 , T 2 , t 3

, T 3 , t 4 , T 4 )

39   printf ( ” \n The a c t ua l r un ni ng s pe ed o f d r iv e n s h a f tw i l l be :   \n n1 = %0 . 2 f r e v / min \n n2 = %0 . 2 f r e v /mi n   \n n3 = %0 . 2 f r e v / min   \n n4 = %0 . 2 f r e v / min ” ,

n 1 , n 2 , n 3 , n 4 )

40   / / A nswer o f n3 i s g i ve n wrong i n book41   / / A nswer v ar y due t o ro un d o f f e r r o r

Scilab code Exa 22.3  Calculate speed and number of teeths

1   clc

2   z = 6   // number o f s t e p s

3   n 1 = 180   / / r e v / min4   n 2 = 100   / / r e v / min5   R n = n1 / n2

6   p hi = ( R n ) ^( 1/ ( z - 1) )   / / common r a t i o7   n3 = ph i* n2   / / r e v / min

116

Page 118: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 118/126

8   n 4 = ( p hi ) ^2 * n2   / / r e v / min

9   n 5 = ( p hi ) ^3 * n2   / / r e v / min10   n 6 = ( p hi ) ^4 * n2   / / r e v / min11   n 7 = 225   // s pe e d o f i np ut s h a f t i n r ev / min12   Ta = poly (0 , ’ Ta ’ )

13   t b = n 7 / n 5 * T a

14   Ta = roots ( t b + T a - 5 2 )

15   tb = horner ( t b , T a )

16   tb =   ceil ( t b )

17   Tc = poly (0 , ’ Tc ’ )

18   t d = n 7 / n 6 * T c

19   Tc = roots ( t d + T c - 5 2 )

20   td = horner ( t d , T c )21   Tc =   ceil ( T c )

22   Te = poly (0 , ’ Te ’ )

23   t f = n 7 / n 1 * T e

24   Te = roots ( t f + T e - 5 2 )

25   tf = horner ( t f , T e )

26   tf =   ceil ( t f )

27   Th = poly (0 , ’ Th ’ )

28   t j = n 2 / n 5 * T h

29   Th = roots ( t j + T h - 4 6 )

30   Th =   ceil ( T h )

31   tj = horner ( t j , T h )

32   tj =   floor ( t j )

33   Ti = poly (0 , ’ T i ’ )

34   t g = n 5 / n 5 * T i

35   Ti = roots ( t g + T i - 4 6 )

36   tg = horner ( t g , T i )

37   printf ( ” \n Ta = %d Tb = %d   \n Tc = %d Td = %d   \n Te= %d t f = %d   \n T h = % d T j = % d   \n T i = %d Tg =%d”   , T a , tb , T c , t d , T e , tf , t j , T h , T i , t g )

38   // ’ Ans wers v ar y due t o ro un d o f f e r r or ’

Scilab code Exa 22.4   Calculate common ratio

117

Page 119: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 119/126

1   clc

2   v = 2 1   // c u t t i n g s pe ed i n r ev / min .3   z = 6

4   d min = 5   / / d a i me t er i n mm5   d max = 20   / / d a i m et e r i n mm6   n m ax = 1 0 00 * v / ( % p i * d m in )   // s p i n d l e s pe ed i n r ev / min

.7   n m in = 1 0 00 * v / ( % p i * d m ax )   // s p i n d l e s pe ed i n r ev / min

.8   p h i = ( n m a x / n m in ) ^ ( 1 / ( z - 1 ) )   / / common r a t i o9   n 1 = nm in   / / r e v / min .

10   n2 = ph i* n1   / / r e v / m in .

11   n 3 = ( p hi ) ^2 * n1   / / r e v / m in .12   n 4 = ( p hi ) ^3 * n1   / / r e v / m in .13   n 5 = ( p hi ) ^4 * n1   / / r e v / m in .14   n 6 = ( p hi ) ^5 * n1   / / r e v / m in .15   printf ( ” \n Common r a t i o = %0 . 2 f    \n S p i n d le s p ee ds

a r e : %0 . 2 f , %0 . 1 f , %0 . 2 f , %0 . 2 f , %0 . 2 f and %0. 1 f r e v / m in . ” , p h i , n 1 , n 2 , n 3 , n 4 , n 5 , n 6 )

16   // ’ Ans wers v ar y due t o ro un d o f f e r r or ’

Scilab code Exa 22.5  Calculate gear ratio teeth and speed

1   // from f i g . 2 2 .1 8A2   clc

3   // Th ree g e ar r a t i o s b et we en i n pu t and i n t e r m e d i a tes h a f t

4   n ma x = 1 40 0   / / maximum s p e e d i n r e v / m in .5   i 1 = 1/1

6   i 2 = 1 /1 .2 6

7   i 3 = 1 /( 1 .2 6 ) ^28   / / The t wo r a t i o s b et we en i n t e r m e d i at e and o ut pu ts h a f t

9   i 4 = 1/1

10   i 5 = 1 /( 1 .2 6 ) ^3

118

Page 120: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 120/126

11   / / number o f t e et h f o r i np ut and i n t e r m e di a t e s h a f t

12   t 1 = 2 7/ 2713   t 2 = 2 4/ 30

14   t 3 = 2 1/ 33

15   // number o f t e e t h f o r o ut pu t and i n t e r m e di a t es h a f t

16   t 4 = 3 4/ 34

17   t 5 = 2 0/ 48

18   / / o u tp ut s p e e d s i n r e v . / min19   n 1 = t 3 * t5 * n ma x

20   n 2 = t 2 * t5 * n ma x

21   n 3 = t 1 * t5 * n ma x

22   n 4 = t 3 * t4 * n ma x23   n 5 = t 2 * t4 * n ma x

24   n 6 = t 1 * t4 * n ma x

25   printf ( ” \n T hree g e ar r a t i o s b et we en i n pu t andi n t e r m e d i a te s h a f t i 1 = %d i 2 = %0 . 2 f i 3 = %0 . 3 f  \n The two r a t i o s be t we e n i n t er m e di a t e ando ut pu t s h a f t i 4 = %d i 5 = %0 . 3 f    \n nu mb er o f  t e et h f o r e ac h p a i r bet w ee n i np ut andi n t e r m e di a t e s h a f t t 1 = 2 7/ 27 , t 2 = 24/ 30 , t 3 =2 1 / 3 3   \n number o f t e e t h f o r e ac h p a i r b et we en

o ut pu t and i n t e r m e d i a te s h a f t = t 4 = 3 4/ 34 , t 5 =2 0 / 4 8   \n Ou tp ut s p e e d s   \n n 1 = %d r ev / min , n2 =%d r e v / min , n3 = %d r e v / min   \n n 4 = %d r e v / min ,n5 = %d r e v / min , n6 = %d r e v / min ”   , i1 , i2 , i3

, i4 , i5 , n1 , n2 , n3 , n4 , n5 , n6 )

26   / / A nswer v ar y due t o ro un d o f f e r r o r

119

Page 121: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 121/126

Chapter 23

Production planning and

control

Scilab code Exa 23.1   Calculate forecast

1   clc

2   d 1 = 90   / / demand f o r f i r s t q u a r t e r3   d 2 = 100   // demand f o r s e co n d q u a r t e r4   d 3 = 80   // demand f o r t h i r d q u a r te r5   s a = ( d 1 + d2 + d 3 ) /3   // s i m pl e a v er a ge6   printf ( ” \n F o r e c a s t = %d”   , s a )

Scilab code Exa 23.2  Calculate forecat by SMA method

1   clc

2   d 1 = 300   // demand f o r j u l y3   d 2 = 350   // demand f o r a u g u s t4   d 3 = 400   / / demand f o r s e p te m b er5   d 4 = 500   // demand f o r o c t o b e r6   d 5 = 600   / / demand f o r n ov em be r7   d 6 = 700   / / d emand f o r d e ce m be r

120

Page 122: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 122/126

8   // a ssu mi ng n = 3 , wher e n i s number o f t i me p e ri o d

9   f o re ca s t = ( d 6 + d5 + d 4 ) /3   // f o r e c a s t10   printf ( ” \n F o r e c a s t = %d”   , f o re c as t )

Scilab code Exa 23.3  Calculate forecat by WMA method

1   clc

2   d 1 = 500   // demand f o r o c t o b e r3   d 2 = 600   / / demand f o r n ov em be r

4   d 3 = 700   / / d emand f o r d e ce m be r5   w 1 = 0. 25   // r e l a t i v e w ei gh t w it h d ec em ber6   w 2 = 0. 25   // r e l a t i v e w ei gh t w it h november7   w 3 = 0.5   // r e l a t i v e w e ig ht w i t h o c t ob e r8   f = w1 *d1 + w2 *d2 + w3 *d3   // f o r e c a s t9   printf ( ” \n F o r e c a s t by w e ig h te d moving a v e ra g e = %d”

, f )

Scilab code Exa 23.4  Calculate forecast for january

1   clc

2   a l ph a = 0 .7   // sm oo th in g c o e f f i c i e n t3   d 1 = 250   / / demand f o r n ov em be r4   d 2 = 300   / / d emand f o r d e ce m be r5   f 1 = 200   // f o r e c a s t f o r november6   f 2 = a lp ha * d1 + (1 - a lp ha ) * f1   // f o r e c a s t f o r

de c e mbe r7   f 3 = a lp ha * d2 + (1 - a lp ha ) * f2   // f o r e c a s t f o r j an ua ry8   f3 =   ceil ( f 3 )

9   printf ( ” \n F o r ec a s t f o r j a nu a ry = %d u n i t s ”   , f 3 )

121

Page 123: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 123/126

Scilab code Exa 23.5   Calculate total cost

1   clc

2   s = 600   // s e t up c os t p e r l o t i n Rs3   c = 6   // u ni t c o s t o f i t e m i n Rs4   a = 1 00 00 0   / / a n nu a l demand f o r i te m5   i = 2 5   // a nn u al c a r r y i n g c ha r g e s o f a ve ra ge

i n v e n t o r y6   i = 2 5/ 10 0

7   k = c * i   // c a r r y i n g c o st f a c t o r i n u n i t / y ea r8   n =   sqrt ( 2 * s * a / k )   // most e c on om ic l o t s i z e9   t c = a * c + s * a / n + k * n / 2   // t o t a l c os t i n Rs

10   printf ( ” \n T o ta l c o s t = Rs %0 . 2 f ”   , t c )11   / / ’ Answers v a ry due t o round o f f e r ro r ’

Scilab code Exa 23.6  Calculate economical order quantity

1   clc

2   a = 8000   // a nn ua l r e qu i re m en t o f p a r t s3   c = 6 0   // u ni t c o s t o f p a rt i n Rs

4   r = 150   // o r d e r i n g c o s t p e r l o t i n Rs5   i = 3 0   // a nn ua l c a r r yi n g c h ar g es o f a v e ra ge

i n v e n t o r y6   i = 3 0/ 10 0

7   k = i * c   // c a r r y i n g c o st p er u ni t p er y ea r8   n =   sqrt ( 2 * r * a / k )   // most e c on o mi c al o r d er q u a n ti t y9   printf ( ” \n Most e co n o mi c al o r d e r i n g q u a nt i t y = %d

u n i t s ”   , n )

Scilab code Exa 23.7   Calculate economic lot size

1   clc

2   a = 12 00 0   // a n nu a l r e q ui r e m en t

122

Page 124: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 124/126

3   c = 5   // u ni t c o s t o f p ar t

4   s = 6 0   // s e t up c o s t p e r l o t5   p = 18 75 0   // p r o d uc ti o n r a t e p er y ea r6   i = 2 0   // i n v e n to r y c a r r y i n g c o s t7   i = 2 0/ 10 0

8   k = i * c   // c a r r y i n g c o st p er u ni t p er y ea r9   n =   sqrt ( 2 * s / ( 1 / a - 1 / p ) * k )   // Most e co no mi c l o t s i z e

10   printf ( ” \n Most e co no mi c l o t s i z e = %d p a r t s ”   , n )

Scilab code Exa 23.8  Calculate inventory control terms

1   clc

2   a = 15 62 5   // a nn ua l r e qu i re m en t o f p a r t s3   c = 1 2   // u ni t c o s t o f p a rt i n Rs4   r = 6 0   // o r d e r i n g c o s t p e r l o t i n Rs5   k = 1.2   // i n v e n t o r y c a r r y i n g c o st p er u n i t6   n =   sqrt ( 2 * r * a / k )   // e c on o mi c al o r d er q u a n ti t y7   o c = r *a /n   // o r de r i n g c o st i n Rs8   c c = k *n /2   // c a r r y i n g c o st i n Rs9   tc = oc + cc   // t o t a l i nv en t o ry c o s t i n Rs

10   printf ( ” \n E co no mi ca l o r d er q u a n ti t y = %d u n i t s \no r d er c o s t = Rs %d\n c a r r y i n g c o s t = Rs %d\nT o ta l i n v e n t o r y c o s t = Rs %d”   , n , oc , cc , tc )

Scilab code Exa 23.9  Calculate discount offered

1   clc

2   / / c as e a

3   a = 5 0   // a nn ua l r e q ui r e me nt o f p a r t s i n t on ne s4   c = 500   // u ni t c o s t o f p ar t i n Rs5   r = 100   // o r de r i n g c o st p er o r d er i n Rs6   i = 2 0   // i n v e n to r y c a r r y i n g c o s t7   i = i / 1 0 0

123

Page 125: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 125/126

8   d = 2   // d i s c o u nt o f p ur ch as e c o st i n p e r ce nt

9   k = i * c   // i n v e n t o r y c a r r y i n g c o st p er u n i t10   n1 =   sqrt ( 2 * r * a / k )   // e c on o mi c al o r d er q u a nt i t y11   o c 1 = r * a/ n1   // o r de r i n g c o st i n Rs12   c c 1 = k * n1 / 2   // c a r r y i n g c o st i n Rs13   t c1 = oc1 + cc1   // t o t a l i nv en t o r y c o s t i n Rs14   / / c as e b15   n 2 = 25   // o rd er p e r l o t16   o c 2 = r * a/ n2   // o r de r i n g c o st i n Rs17   c c 2 = k * n2 / 2   // c a r r y i n g c o st i n Rs18   t c2 = oc2 + cc2   // t o t a l i nv en t o r y c o s t i n Rs19   i = tc2 - t c1   // i n c r e a s e i n c o s t i n Rs

20   d _ o = d * c *a / 10 0   // d i s c o u nt o f f e r e d21   printf ( ” \n I n c r e a s e i n i n ve n to r y c o s t = Rs %d\n

D i s c o u nt o f f e r e d = Rs%d” , i , d _ o )

22   disp ( ” o f f e r i s worth a c c ep t i n g ” )

Scilab code Exa 23.10  Calculate EOQ and reorder point

1   clc

2   a = 1 00 00 00   // a nn ua l r e qu i re m en t o f p a r t s3   r = 3 2   // o r d e r i n g c o s t p e r l o t i n Rs4   k = 4   // i n v e n t o r y c a r r y i n g c o st p e r u n i t5   d 1 = 250   // number o f w o rk i ng d a ys6   d 2 = 2   // da y s f o r s a f e t y s t o c k7   d 3 = 4   // l e ad t im e i n da ys8   e oq =   sqrt ( 2 * r * a / k )   // e co n om i ca l o r d er q u a nt i t y9   o c = r * a/ e oq    // o r de r i n g c o st i n Rs

10   c c = k * eo q /2   // c a r r y i n g c o st i n Rs11   tc = oc + cc   // t o t a l i nv en t o ry c o s t i n Rs

12   s s = a * d2 / d1   // s a f e t y s t o c k13   r o _p = s s + eo q * d3   // r e o r d e r p o in t14   printf ( ” \n E co no mi c o r d e r q u n a n t i t y = %d c om po ne nt s \

n Re−o r d e r p o i n t = %d c om po ne nt s ”   , e oq , r o_ p )

124

Page 126: A Textbook of Production Engineering_P. C. Sharma

7/25/2019 A Textbook of Production Engineering_P. C. Sharma

http://slidepdf.com/reader/full/a-textbook-of-production-engineeringp-c-sharma 126/126

Chapter 26

Plant layout

Scilab code Exa 26.1  Calculate number of machine required

1   clc

2   N = 1 00 00 0   // a nn ua l o ut pu t o f p a r ts3   s = 2   // e x pe c te d s c r ap4   t = 105   // e st im at ed t i m e p er p ar t i n s5   i ta = 80   // p r o d uc t i o n e f f i c i e n c y o f machi ne6   a = 2300   // number o f w o rk i ng h o u r s

7   o u t p u t = ( 3 60 0 * i t a ) /( t * 1 0 0 )   // p a rt s r e q u i r e d p erhour