summaryrefslogtreecommitdiff
path: root/416
diff options
context:
space:
mode:
Diffstat (limited to '416')
-rwxr-xr-x416/CH10/EX10.1/exp10_1cpp.sce58
-rwxr-xr-x416/CH10/EX10.1/exp10_1cpp.txt14
-rwxr-xr-x416/CH10/EX10.10/exp10_10.sce22
-rwxr-xr-x416/CH10/EX10.10/exp10_10.txt5
-rwxr-xr-x416/CH10/EX10.11/exp10_11.sce11
-rwxr-xr-x416/CH10/EX10.11/exp10_11.txt7
-rwxr-xr-x416/CH10/EX10.12/exp10_12pp.sce31
-rwxr-xr-x416/CH10/EX10.12/exp10_12pp.txt7
-rwxr-xr-x416/CH10/EX10.13/exp10_13.sce19
-rwxr-xr-x416/CH10/EX10.13/exp10_13.txt9
-rwxr-xr-x416/CH10/EX10.14/exp10_14pp.sce18
-rwxr-xr-x416/CH10/EX10.14/exp10_14pp.txt6
-rwxr-xr-x416/CH10/EX10.15/exp10_15pp.sce32
-rwxr-xr-x416/CH10/EX10.15/exp10_15pp.txt7
-rwxr-xr-x416/CH10/EX10.16/exp10_16.sce20
-rwxr-xr-x416/CH10/EX10.16/exp10_16.txt14
-rwxr-xr-x416/CH10/EX10.17/exp10_17pp.sce28
-rwxr-xr-x416/CH10/EX10.17/exp10_17pp.txt5
-rwxr-xr-x416/CH10/EX10.2/exp10_2.sce29
-rwxr-xr-x416/CH10/EX10.2/exp10_2.txt5
-rwxr-xr-x416/CH10/EX10.3/exp10_3.sce23
-rwxr-xr-x416/CH10/EX10.3/exp10_3.txt7
-rwxr-xr-x416/CH10/EX10.5/exp10_5.sce22
-rwxr-xr-x416/CH10/EX10.5/exp10_5.txt13
-rwxr-xr-x416/CH10/EX10.7/exp10_7pp.sce34
-rwxr-xr-x416/CH10/EX10.7/exp10_7pp.txt14
-rwxr-xr-x416/CH10/EX10.8/exp10_8pp.sce12
-rwxr-xr-x416/CH10/EX10.8/exp10_8pp.txt7
-rwxr-xr-x416/CH10/EX10.9/exp10_9.sce21
-rwxr-xr-x416/CH10/EX10.9/exp10_9.txt4
-rwxr-xr-x416/CH11/EX11.1/exp11_1.pngbin0 -> 9962 bytes
-rwxr-xr-x416/CH11/EX11.1/exp11_1pp.sce95
-rwxr-xr-x416/CH11/EX11.1/exp11_1pp.txt31
-rwxr-xr-x416/CH11/EX11.2/exp11_2pp.sce38
-rwxr-xr-x416/CH11/EX11.2/exp11_2pp.txt13
-rwxr-xr-x416/CH11/EX11.3/exp11_3.sce23
-rwxr-xr-x416/CH11/EX11.3/exp11_3.txt4
-rwxr-xr-x416/CH12/EX12.1/ans12_1pp.txt9
-rwxr-xr-x416/CH12/EX12.1/example12_1pp.sce19
-rwxr-xr-x416/CH12/EX12.2/ans12_2.txt4
-rwxr-xr-x416/CH12/EX12.2/example12_2.sce23
-rwxr-xr-x416/CH12/EX12.3/ans12_3pp.txt3
-rwxr-xr-x416/CH12/EX12.3/example12_3pp.sce10
-rwxr-xr-x416/CH12/EX12.4/ans12_4.txt6
-rwxr-xr-x416/CH12/EX12.4/example12_4.sce11
-rwxr-xr-x416/CH12/EX12.5/ans12_5.txt9
-rwxr-xr-x416/CH12/EX12.5/example12_5.sce24
-rwxr-xr-x416/CH12/EX12.6/ans12_6.txt4
-rwxr-xr-x416/CH12/EX12.6/example12_6.sce12
-rwxr-xr-x416/CH12/EX12.7/ans12_7cpp.txt10
-rwxr-xr-x416/CH12/EX12.7/example12_7cpp.sce22
-rwxr-xr-x416/CH13/EX13.1/example13_1.sce20
-rwxr-xr-x416/CH13/EX13.1/example13_1.txt12
-rwxr-xr-x416/CH13/EX13.10/example13_10c.sce20
-rwxr-xr-x416/CH13/EX13.10/example13_10c.txt7
-rwxr-xr-x416/CH13/EX13.11/example13_11.sce14
-rwxr-xr-x416/CH13/EX13.11/example13_11.txt12
-rwxr-xr-x416/CH13/EX13.2/example13_2.sce23
-rwxr-xr-x416/CH13/EX13.2/example13_2.txt11
-rwxr-xr-x416/CH13/EX13.3/example13_3.sce23
-rwxr-xr-x416/CH13/EX13.3/example13_3.txt4
-rwxr-xr-x416/CH13/EX13.4/example13_4cpp.sce8
-rwxr-xr-x416/CH13/EX13.4/example13_4cpp.txt4
-rwxr-xr-x416/CH13/EX13.5/example13_5nc.sce40
-rwxr-xr-x416/CH13/EX13.5/example13_5nc.txt4
-rwxr-xr-x416/CH13/EX13.6/example13_6c.sce15
-rwxr-xr-x416/CH13/EX13.6/example13_6c.txt8
-rwxr-xr-x416/CH13/EX13.7/example13_7pp.sce9
-rwxr-xr-x416/CH13/EX13.7/example13_7pp.txt5
-rwxr-xr-x416/CH13/EX13.8/example13_8c.sce17
-rwxr-xr-x416/CH13/EX13.8/example13_8c.txt9
-rwxr-xr-x416/CH13/EX13.9/example13_9pp.sce14
-rwxr-xr-x416/CH13/EX13.9/example13_9pp.txt7
-rwxr-xr-x416/CH14/EX14.1/ans14_1.txt4
-rwxr-xr-x416/CH14/EX14.1/example14_1.sce10
-rwxr-xr-x416/CH14/EX14.10/ans14_10.txt11
-rwxr-xr-x416/CH14/EX14.10/example14_10.sce33
-rwxr-xr-x416/CH14/EX14.11/ans14_11.txt4
-rwxr-xr-x416/CH14/EX14.11/example14_11.sce21
-rwxr-xr-x416/CH14/EX14.12/ans14_12pp.txt11
-rwxr-xr-x416/CH14/EX14.12/example14_12pp.sce35
-rwxr-xr-x416/CH14/EX14.13/ans14_13.txt7
-rwxr-xr-x416/CH14/EX14.13/example14_13.sce19
-rwxr-xr-x416/CH14/EX14.14/ans14_14.txt7
-rwxr-xr-x416/CH14/EX14.14/example14_14.sce27
-rwxr-xr-x416/CH14/EX14.15/ans14_15.txt3
-rwxr-xr-x416/CH14/EX14.15/example14_15.sce15
-rwxr-xr-x416/CH14/EX14.16/ans14_16pp.txt13
-rwxr-xr-x416/CH14/EX14.16/example14_16pp.sce28
-rwxr-xr-x416/CH14/EX14.17/ans14_17.txt5
-rwxr-xr-x416/CH14/EX14.17/example14_17.sce16
-rwxr-xr-x416/CH14/EX14.18/ans14_18pp.txt5
-rwxr-xr-x416/CH14/EX14.18/example14_18pp.sce10
-rwxr-xr-x416/CH14/EX14.19/ans14_19pp.txt9
-rwxr-xr-x416/CH14/EX14.19/example14_19pp.sce32
-rwxr-xr-x416/CH14/EX14.2/ans14_2.txt4
-rwxr-xr-x416/CH14/EX14.2/example14_2.sce13
-rwxr-xr-x416/CH14/EX14.3/ans14_3pp.txt4
-rwxr-xr-x416/CH14/EX14.3/example14_3pp.sce15
-rwxr-xr-x416/CH14/EX14.4/ans14_4.txt4
-rwxr-xr-x416/CH14/EX14.4/example14_4.sce15
-rwxr-xr-x416/CH14/EX14.5/ans14_5.txt5
-rwxr-xr-x416/CH14/EX14.5/example14_5.sce14
-rwxr-xr-x416/CH14/EX14.6/ans14_6pp.txt4
-rwxr-xr-x416/CH14/EX14.6/example14_6pp.sce17
-rwxr-xr-x416/CH14/EX14.7/ans14_7pp.txt6
-rwxr-xr-x416/CH14/EX14.7/example14_7pp.sce14
-rwxr-xr-x416/CH14/EX14.8/ans14_8pp.txt4
-rwxr-xr-x416/CH14/EX14.8/example14_8pp.sce21
-rwxr-xr-x416/CH14/EX14.9/ans14_9pp.txt4
-rwxr-xr-x416/CH14/EX14.9/example14_9pp.sce18
-rwxr-xr-x416/CH15/EX15.1/exp15_1pp.sce12
-rwxr-xr-x416/CH15/EX15.1/exp15_1pp.txt5
-rwxr-xr-x416/CH15/EX15.10/exp15_10pp.sce23
-rwxr-xr-x416/CH15/EX15.10/exp15_10pp.txt6
-rwxr-xr-x416/CH15/EX15.2/exp15_2pp.sce13
-rwxr-xr-x416/CH15/EX15.2/exp15_2pp.txt6
-rwxr-xr-x416/CH15/EX15.3/exp15_3pp.sce30
-rwxr-xr-x416/CH15/EX15.3/exp15_3pp.txt13
-rwxr-xr-x416/CH15/EX15.4/exp15_4pp.sce18
-rwxr-xr-x416/CH15/EX15.4/exp15_4pp.txt10
-rwxr-xr-x416/CH15/EX15.5/exp15_5pp.sce14
-rwxr-xr-x416/CH15/EX15.5/exp15_5pp.txt6
-rwxr-xr-x416/CH15/EX15.6/exp15_6pp.sce26
-rwxr-xr-x416/CH15/EX15.6/exp15_6pp.txt12
-rwxr-xr-x416/CH15/EX15.7/exp15_7pp.sce14
-rwxr-xr-x416/CH15/EX15.7/exp15_7pp.txt6
-rwxr-xr-x416/CH15/EX15.8/exp15_8.sce11
-rwxr-xr-x416/CH15/EX15.8/exp15_8.txt5
-rwxr-xr-x416/CH15/EX15.9/exp15_9pp.sce24
-rwxr-xr-x416/CH15/EX15.9/exp15_9pp.txt6
-rwxr-xr-x416/CH17/EX17.1/exp17_1PP.sce15
-rwxr-xr-x416/CH17/EX17.1/exp17_1PP.txt6
-rwxr-xr-x416/CH17/EX17.2/exp17_2PP.sce38
-rwxr-xr-x416/CH17/EX17.2/exp17_2PP.txt16
-rwxr-xr-x416/CH17/EX17.3/exp17_3.jpgbin0 -> 20677 bytes
-rwxr-xr-x416/CH17/EX17.3/exp17_3PP.sce31
-rwxr-xr-x416/CH17/EX17.3/exp17_3PP.txt15
-rwxr-xr-x416/CH17/EX17.4/exp17_4.jpgbin0 -> 23455 bytes
-rwxr-xr-x416/CH17/EX17.4/exp17_4PP.sce34
-rwxr-xr-x416/CH17/EX17.4/exp17_4PP.txt17
-rwxr-xr-x416/CH2/EX2.1/exp2_1cpp.sce33
-rwxr-xr-x416/CH2/EX2.1/exp2_1cpp.txt33
-rwxr-xr-x416/CH2/EX2.10/exp2_10cpp.sce7
-rwxr-xr-x416/CH2/EX2.10/exp2_10cpp.txt7
-rwxr-xr-x416/CH2/EX2.11/exp2_11c.sce12
-rwxr-xr-x416/CH2/EX2.11/exp2_11c.txt7
-rwxr-xr-x416/CH2/EX2.12/exp2_12.pngbin0 -> 3828 bytes
-rwxr-xr-x416/CH2/EX2.12/exp2_12c.sce43
-rwxr-xr-x416/CH2/EX2.12/exp2_12c.txt19
-rwxr-xr-x416/CH2/EX2.13/exp2_13.sce6
-rwxr-xr-x416/CH2/EX2.13/exp2_13.txt3
-rwxr-xr-x416/CH2/EX2.14/exp2_14.sce12
-rwxr-xr-x416/CH2/EX2.14/exp2_14.txt9
-rwxr-xr-x416/CH2/EX2.2/exp2_2.pngbin0 -> 8377 bytes
-rwxr-xr-x416/CH2/EX2.2/exp2_2pp.sce38
-rwxr-xr-x416/CH2/EX2.2/exp2_2pp.txt26
-rwxr-xr-x416/CH2/EX2.3/exp2_3pp.sce23
-rwxr-xr-x416/CH2/EX2.3/exp2_3pp.txt10
-rwxr-xr-x416/CH2/EX2.4/exp2_4.pngbin0 -> 6845 bytes
-rwxr-xr-x416/CH2/EX2.4/exp2_4pp.sce22
-rwxr-xr-x416/CH2/EX2.4/exp2_4pp.txt8
-rwxr-xr-x416/CH2/EX2.5/exp2_5.txt4
-rwxr-xr-x416/CH2/EX2.5/exp2_5q.sce6
-rwxr-xr-x416/CH2/EX2.6/exp2_6.pngbin0 -> 8724 bytes
-rwxr-xr-x416/CH2/EX2.6/exp2_6pp.sce52
-rwxr-xr-x416/CH2/EX2.6/exp2_6pp.txt13
-rwxr-xr-x416/CH2/EX2.7/exp2_7c.sce15
-rwxr-xr-x416/CH2/EX2.7/exp2_7c.txt11
-rwxr-xr-x416/CH2/EX2.8/exp2_8c.pngbin0 -> 6119 bytes
-rwxr-xr-x416/CH2/EX2.8/exp2_8cpp.sce14
-rwxr-xr-x416/CH2/EX2.8/exp2_8cpp.txt8
-rwxr-xr-x416/CH2/EX2.9/exp2_9.pngbin0 -> 8875 bytes
-rwxr-xr-x416/CH2/EX2.9/exp2_9c.sce32
-rwxr-xr-x416/CH2/EX2.9/exp2_9c.txt15
-rwxr-xr-x416/CH20/EX20.1/ans20_1.txt16
-rwxr-xr-x416/CH20/EX20.1/example20_1.sce31
-rwxr-xr-x416/CH20/EX20.2/ans20_2.txt14
-rwxr-xr-x416/CH20/EX20.2/example20_2.sce30
-rwxr-xr-x416/CH23/EX23.1/ans23_1pp.txt14
-rwxr-xr-x416/CH23/EX23.1/exp23_1pp.sce28
-rwxr-xr-x416/CH23/EX23.11.2/sample23_11_2pp.sce18
-rwxr-xr-x416/CH23/EX23.11.2/samplepp.txt6
-rwxr-xr-x416/CH23/EX23.2/ans23_2.txt10
-rwxr-xr-x416/CH23/EX23.2/exp23_2.sce19
-rwxr-xr-x416/CH3/EX3.1/exp3_1c.sce21
-rwxr-xr-x416/CH3/EX3.1/exp3_1c.txt29
-rwxr-xr-x416/CH3/EX3.16/data3_16pp.sce29
-rwxr-xr-x416/CH3/EX3.16/data3_16pp.txt14
-rwxr-xr-x416/CH3/EX3.17/data3_17c.sce16
-rwxr-xr-x416/CH3/EX3.17/data3_17c.txt6
-rwxr-xr-x416/CH3/EX3.2/exp3_2c.sce14
-rwxr-xr-x416/CH3/EX3.2/exp3_2c.txt10
-rwxr-xr-x416/CH3/EX3.3/exp3_3pp.sce11
-rwxr-xr-x416/CH3/EX3.3/exp3_3pp.txt5
-rwxr-xr-x416/CH3/EX3.4/exp3_4.pngbin0 -> 4669 bytes
-rwxr-xr-x416/CH3/EX3.4/exp3_4pp.sce33
-rwxr-xr-x416/CH3/EX3.4/exp3_4pp.txt29
-rwxr-xr-x416/CH3/EX3.5/exp3_5c.sce24
-rwxr-xr-x416/CH3/EX3.5/exp3_5c.txt10
-rwxr-xr-x416/CH3/EX3.6/exp3_6cpp.sce24
-rwxr-xr-x416/CH3/EX3.6/exp3_6cpp.txt17
-rwxr-xr-x416/CH3/EX3.7/exp3_7pp.sce17
-rwxr-xr-x416/CH3/EX3.7/exp3_7pp.txt8
-rwxr-xr-x416/CH4/EX4.1/ans4_1.txt5
-rwxr-xr-x416/CH4/EX4.1/example4_1.sce18
-rwxr-xr-x416/CH4/EX4.10/exp4_10cpp.sce22
-rwxr-xr-x416/CH4/EX4.10/exp4_10cpp.txt12
-rwxr-xr-x416/CH4/EX4.11/exp4_11cpp.sce28
-rwxr-xr-x416/CH4/EX4.11/exp4_11cpp.txt12
-rwxr-xr-x416/CH4/EX4.12/ans4_12.txt20
-rwxr-xr-x416/CH4/EX4.12/example4_12.sce27
-rwxr-xr-x416/CH4/EX4.13/exp4_13cpp.sce22
-rwxr-xr-x416/CH4/EX4.13/exp4_13cpp.txt12
-rwxr-xr-x416/CH4/EX4.14/exp4_14pp.sce25
-rwxr-xr-x416/CH4/EX4.14/exp4_14pp.txt14
-rwxr-xr-x416/CH4/EX4.15/exp4_15c.sce15
-rwxr-xr-x416/CH4/EX4.15/exp4_15c.txt6
-rwxr-xr-x416/CH4/EX4.16/exp4_16pp.sce34
-rwxr-xr-x416/CH4/EX4.16/exp4_16pp.txt18
-rwxr-xr-x416/CH4/EX4.17/exp4_17c.sce10
-rwxr-xr-x416/CH4/EX4.17/exp4_17c.txt6
-rwxr-xr-x416/CH4/EX4.18/exp4_18cpp.sce18
-rwxr-xr-x416/CH4/EX4.18/exp4_18cpp.txt8
-rwxr-xr-x416/CH4/EX4.19/exp4_19c.sce15
-rwxr-xr-x416/CH4/EX4.19/exp4_19c.txt4
-rwxr-xr-x416/CH4/EX4.2/exp4_2c.sce12
-rwxr-xr-x416/CH4/EX4.2/exp4_2c.txt4
-rwxr-xr-x416/CH4/EX4.20/ans4_20.txt4
-rwxr-xr-x416/CH4/EX4.20/example4_20.sce10
-rwxr-xr-x416/CH4/EX4.21/ans4_21.txt12
-rwxr-xr-x416/CH4/EX4.21/example4_21.sce20
-rwxr-xr-x416/CH4/EX4.22/exp4_22cpp.sce30
-rwxr-xr-x416/CH4/EX4.22/exp4_22cpp.txt16
-rwxr-xr-x416/CH4/EX4.3/exp4_3pp.sce40
-rwxr-xr-x416/CH4/EX4.3/exp4_3pp.txt33
-rwxr-xr-x416/CH4/EX4.4/ans4_4.txt8
-rwxr-xr-x416/CH4/EX4.4/example4_4.sce12
-rwxr-xr-x416/CH4/EX4.5/exp4_5c.sce7
-rwxr-xr-x416/CH4/EX4.5/exp4_5c.txt5
-rwxr-xr-x416/CH4/EX4.6/exp4_6c.sce24
-rwxr-xr-x416/CH4/EX4.6/exp4_6c.txt16
-rwxr-xr-x416/CH4/EX4.7/exp4_7c.sce29
-rwxr-xr-x416/CH4/EX4.7/exp4_7c.txt16
-rwxr-xr-x416/CH4/EX4.8/exp4_8c.sce14
-rwxr-xr-x416/CH4/EX4.8/exp4_8c.txt4
-rwxr-xr-x416/CH4/EX4.9/exp4_9cpp.sce16
-rwxr-xr-x416/CH4/EX4.9/exp4_9cpp.txt16
-rwxr-xr-x416/CH5/EX5.1/5_1anspp.txt8
-rwxr-xr-x416/CH5/EX5.1/exp5_1pp.sce44
-rwxr-xr-x416/CH5/EX5.2/5_2anspp.txt33
-rwxr-xr-x416/CH5/EX5.2/exp5_2pp.sce47
-rwxr-xr-x416/CH5/EX5.3/5_3ans.txt9
-rwxr-xr-x416/CH5/EX5.3/exp5_3.sce41
-rwxr-xr-x416/CH5/EX5.4/5_4anspp.txt24
-rwxr-xr-x416/CH5/EX5.4/exp5_4pp.sce81
-rwxr-xr-x416/CH7/EX7.1/7_1ans.txt6
-rwxr-xr-x416/CH7/EX7.1/exp7_1.sce16
-rwxr-xr-x416/CH8/EX8.1/exp8_1c.sce8
-rwxr-xr-x416/CH8/EX8.1/exp8_1c.txt4
-rwxr-xr-x416/CH8/EX8.2/exp8_2.pngbin0 -> 5695 bytes
-rwxr-xr-x416/CH8/EX8.2/exp8_2.sce27
-rwxr-xr-x416/CH8/EX8.2/exp8_2.txt8
-rwxr-xr-x416/CH8/EX8.3/exp8_3.pngbin0 -> 6254 bytes
-rwxr-xr-x416/CH8/EX8.3/exp8_3.sce36
-rwxr-xr-x416/CH8/EX8.3/exp8_3.txt3
-rwxr-xr-x416/CH8/EX8.4/exp8_4ff.jpgbin0 -> 36290 bytes
-rwxr-xr-x416/CH8/EX8.4/exp8_4ff.sce41
-rwxr-xr-x416/CH8/EX8.4/exp8_4ff.txt3
-rwxr-xr-x416/CH8/EX8.5/exp8_5.pngbin0 -> 7861 bytes
-rwxr-xr-x416/CH8/EX8.5/exp8_5.sce34
-rwxr-xr-x416/CH8/EX8.5/exp8_5.txt11
-rwxr-xr-x416/CH8/EX8.6/exp8_6c.sce24
-rwxr-xr-x416/CH8/EX8.6/exp8_6c.txt11
-rwxr-xr-x416/CH9/EX9.1/9_1ans.txt3
-rwxr-xr-x416/CH9/EX9.1/exp9_1.sce8
-rwxr-xr-x416/CH9/EX9.2/9_2ans.txt4
-rwxr-xr-x416/CH9/EX9.2/exp9_2.sce9
-rwxr-xr-x416/CH9/EX9.3/9_3ans.txt14
-rwxr-xr-x416/CH9/EX9.3/exp9_3.sce18
-rwxr-xr-x416/CH9/EX9.4/9_4ans.txt5
-rwxr-xr-x416/CH9/EX9.4/exp9_4.sce11
-rwxr-xr-x416/CH9/EX9.5/9_5ans.txt4
-rwxr-xr-x416/CH9/EX9.5/exap9_5.sce10
-rwxr-xr-x416/CH9/EX9.6/9_6ans.txt5
-rwxr-xr-x416/CH9/EX9.6/exp9_6.sce13
-rwxr-xr-x416/CH9/EX9.7/9_7ans.txt5
-rwxr-xr-x416/CH9/EX9.7/exp9_7.sce13
288 files changed, 4410 insertions, 0 deletions
diff --git a/416/CH10/EX10.1/exp10_1cpp.sce b/416/CH10/EX10.1/exp10_1cpp.sce
new file mode 100755
index 000000000..99f6e450a
--- /dev/null
+++ b/416/CH10/EX10.1/exp10_1cpp.sce
@@ -0,0 +1,58 @@
+clear
+clc
+disp("example 10.1")
+mp=250 //maximum power
+function [ic]=unit1(p1) //ic equation of unit 1
+ ic=0.2*p1+30
+endfunction
+function [ic]=unit2(p2)//ic equation of unit 2
+ ic=0.15*p2+40
+endfunction
+mil=20//minimum load
+disp("minimum load ic is")
+ic=[unit1(mil),unit2(mil)]
+[m,n]=max(ic)
+if m==unit2(mil) then
+ for x=20:100
+ if m==unit1(x) then
+ break
+ end
+ end
+ printf("ic of unit1 =ic of unit2 when unit2=%dMW and unit1=%dMW",mil,x)
+end
+function [p1,p2]=un(ic)
+ p1=(ic-30)/0.2
+ p2=(ic-40)/0.15
+endfunction
+printf("load division \n")
+me=ceil(unit2(mil)/10)
+for x=me*10:5:100
+ ii=0
+ [m,n]=un(x)
+ if m>=mp|n>=mp then
+ if n>mp then
+ p=2
+ end
+ if m>mp then
+ p=1
+ end
+ for y=x-5:0.5:x
+ [c,v]=un(y)
+ m1=[c,v]
+ if mp==m1(p) then
+ ii=1
+ break
+ end
+ end
+ [pp qq]=un(y)
+ printf("\n for plant ic %3.1fMW \tthen p1=%dMW\t p2 =%dMW",unit1(pp),pp,qq)
+ ii=1
+ break
+ end
+ if ii==0 then
+ l=m+n
+ printf("\n for plant ic %dMW \tthen p1 is %dMW\t plant2 is %dMW and total is %dMW ",x,m,n,l)
+ end
+end
+a=unit1(mp);b=unit2(mp)
+printf("\n for plant ic %dMW \tthen p1 is %dMW\t plant2 is %dMW and total is %dMW ",a,mp,mp,2*mp)
diff --git a/416/CH10/EX10.1/exp10_1cpp.txt b/416/CH10/EX10.1/exp10_1cpp.txt
new file mode 100755
index 000000000..2d99e78d7
--- /dev/null
+++ b/416/CH10/EX10.1/exp10_1cpp.txt
@@ -0,0 +1,14 @@
+
+ example 10.1
+
+ minimum load ic is
+ic of unit1 =ic of unit2 when unit2=20MW and unit1=65MWload division
+
+ for plant ic 50MW then p1 is 100MW plant2 is 66MW and total is 166MW
+ for plant ic 55MW then p1 is 125MW plant2 is 100MW and total is 225MW
+ for plant ic 60MW then p1 is 150MW plant2 is 133MW and total is 283MW
+ for plant ic 65MW then p1 is 175MW plant2 is 166MW and total is 341MW
+ for plant ic 70MW then p1 is 200MW plant2 is 200MW and total is 400MW
+ for plant ic 75MW then p1 is 225MW plant2 is 233MW and total is 458MW
+ for plant ic 77.5MW then p1=237MW p2 =250MW
+ for plant ic 80MW then p1 is 250MW plant2 is 250MW and total is 500MW \ No newline at end of file
diff --git a/416/CH10/EX10.10/exp10_10.sce b/416/CH10/EX10.10/exp10_10.sce
new file mode 100755
index 000000000..c15575934
--- /dev/null
+++ b/416/CH10/EX10.10/exp10_10.sce
@@ -0,0 +1,22 @@
+clear
+clc
+disp("example 10.10")
+b11=0.001
+b12=-0.0005
+b22=0.0024
+q1=0.08
+r1=16
+q2=0.08
+r2=12
+lamda=20
+
+p2=0
+for x=1:4
+ p1=(1-(r1/lamda)-(2*p2*b12))/((q1/lamda)+2*b11)
+
+p2=(1-(r2/lamda)-(2*p1*b12))/((q2/lamda)+2*b22)
+
+end
+pl=b11*p1^2+2*b12*p1*p2+b22*p2^2
+pr=p1+p2-pl
+printf("thus \t p1=%2.1fMW,p2=%2.1fMW\n pl=%1.1fMW\npower resevied %2.1fMW",p1,p2,pl,pr)
diff --git a/416/CH10/EX10.10/exp10_10.txt b/416/CH10/EX10.10/exp10_10.txt
new file mode 100755
index 000000000..261e23482
--- /dev/null
+++ b/416/CH10/EX10.10/exp10_10.txt
@@ -0,0 +1,5 @@
+
+ example 10.10
+thus p1=41.7MW,p2=50.2MW
+ pl=5.7MW
+power resevied 86.2MW \ No newline at end of file
diff --git a/416/CH10/EX10.11/exp10_11.sce b/416/CH10/EX10.11/exp10_11.sce
new file mode 100755
index 000000000..aaab6863b
--- /dev/null
+++ b/416/CH10/EX10.11/exp10_11.sce
@@ -0,0 +1,11 @@
+clear
+clc
+disp("example 10.11")
+a1=561;b1=7.92;c1=0.001562
+a2=310;b2=7.85;c2=0.00194
+ce=c1*c2/(c1+c2)
+printf("\nce=%e",ce)
+be=((b1/c1)+(b2/c2))*ce
+printf("\nbe=%1.4f",be)
+ae=a1-((b1^2)/4*c1)+a2-((b2^2)/4*c2)+((be^2)/4*ce)
+printf("ae=%3.3f \n cost characteristics of composite unit for demand pt is \n ct=%3.3f+%1.4f*p1+%ep1^2",ae,ae,be,ce) \ No newline at end of file
diff --git a/416/CH10/EX10.11/exp10_11.txt b/416/CH10/EX10.11/exp10_11.txt
new file mode 100755
index 000000000..d21b4cf5b
--- /dev/null
+++ b/416/CH10/EX10.11/exp10_11.txt
@@ -0,0 +1,7 @@
+
+ example 10.11
+
+ce=8.652998e-004
+be=7.8888ae=870.959
+ cost characteristics of composite unit for demand pt is
+ ct=870.959+7.8888*p1+8.652998e-004p1^2 \ No newline at end of file
diff --git a/416/CH10/EX10.12/exp10_12pp.sce b/416/CH10/EX10.12/exp10_12pp.sce
new file mode 100755
index 000000000..42eac3a5d
--- /dev/null
+++ b/416/CH10/EX10.12/exp10_12pp.sce
@@ -0,0 +1,31 @@
+clear
+clc
+disp("example 10.12")
+a1=7700;b1=52.8;c1=5.5*10^-3
+a2=2500;b2=15;c2=0.05//given eqution
+plo=200;pup=800
+ct=1000
+l=[500,900,1200,500];t=[6 16 20 24]//from given graph
+function [p1,p2]=cost(y)
+ p1=(2*c2*y-(b1-b2))/(2*(c1+c2))
+ p2=y-p1
+endfunction
+ma=max(l)
+mi=min(l)
+for x=1:3
+ [e g]=cost(l(x))
+ if e<plo|g<plo|e>pup|g>pup then
+ if e<plo|g<plo then
+ [v,u]=min(e,g)
+ if u==1 then
+ e=plo
+ g=l(x)-e
+ else
+ g=plo
+ e=l(x)-g
+ end
+ end
+
+end
+printf("\np1=%3.2fMW\tp2=%3.2fMW",e,g)
+end
diff --git a/416/CH10/EX10.12/exp10_12pp.txt b/416/CH10/EX10.12/exp10_12pp.txt
new file mode 100755
index 000000000..243f3d2b4
--- /dev/null
+++ b/416/CH10/EX10.12/exp10_12pp.txt
@@ -0,0 +1,7 @@
+
+
+ example 10.12
+
+p1=200.00MW p2=300.00MW
+p1=470.27MW p2=429.73MW
+p1=740.54MW p2=459.46MW \ No newline at end of file
diff --git a/416/CH10/EX10.13/exp10_13.sce b/416/CH10/EX10.13/exp10_13.sce
new file mode 100755
index 000000000..ef629e246
--- /dev/null
+++ b/416/CH10/EX10.13/exp10_13.sce
@@ -0,0 +1,19 @@
+clc
+clear
+disp("example 10 13")
+a1=2000;b1=20;c1=0.05;p1=350;p2=550
+a2=2750;b2=26;c2=0.03091
+function [co]=cost(a,b,c,p)
+ co=a+b*p+c*p^2
+endfunction
+disp("(a)")
+toco=cost(a1,b1,c1,p1)+cost(a2,b2,c2,p2)
+printf("total cost when each system supplies its own load Rs%.3f per hour",toco)
+l=p1+p2
+p11=(b2-b1+2*c2*l)/(2*(c1+c2))
+p22=l-p11
+totco=cost(a1,b1,c1,p11)+cost(a2,b2,c2,p22)
+sav=toco-totco
+tilo=p11-p1
+disp("(b)")
+printf("\n total cost when load is supplied in economic load dispatch method Rs%d per hour \n saving %.3f \n tie line load %.3f MW",totco,sav,tilo)
diff --git a/416/CH10/EX10.13/exp10_13.txt b/416/CH10/EX10.13/exp10_13.txt
new file mode 100755
index 000000000..84a986c96
--- /dev/null
+++ b/416/CH10/EX10.13/exp10_13.txt
@@ -0,0 +1,9 @@
+example 10 13
+
+ (a)
+total cost when each system supplies its own load Rs41525.275 per hour
+ (b)
+
+ total cost when load is supplied in economic load dispatch method Rs41447 per hour
+ saving 77.277
+ tie line load 30.905 MW \ No newline at end of file
diff --git a/416/CH10/EX10.14/exp10_14pp.sce b/416/CH10/EX10.14/exp10_14pp.sce
new file mode 100755
index 000000000..b67f88b2c
--- /dev/null
+++ b/416/CH10/EX10.14/exp10_14pp.sce
@@ -0,0 +1,18 @@
+clear
+clc
+disp("example10.14")
+a1=5000;b1=450;c1=0.5;//for system 1
+e1=0.02;e2=-0.02//error
+a1c=a1*(1-e1);b1c=b1*(1-e1);c1c=c1*(1-e1)
+a2c=a1*(1-e2);b2c=b1*(1-e2);c2c=c1*(1-e2)
+tl=200
+function [co]=cost(a,b,c,p)
+ co=a+b*p+c*p^2
+endfunction
+p11=(b2c-b1c+2*c2c*tl)/(2*(c1c+c2c))
+p22=tl-p11
+totco=cost(a1c,b1c,c1c,p11)+cost(a2c,b2c,c2c,p22)
+printf("\npower at station 1 is %dMW \t power at station 2 is %dMW \n total cost on economic critieria method Rs%d per hour",p11,p22,totco)
+tocoe=cost(a1c,b1c,c1c,tl/2)+cost(a2c,b2c,c2c,tl/2)
+eop=tocoe-totco
+printf("\nextra operating cost due to erroneous scheduling Rs.%d per hour",eop) \ No newline at end of file
diff --git a/416/CH10/EX10.14/exp10_14pp.txt b/416/CH10/EX10.14/exp10_14pp.txt
new file mode 100755
index 000000000..81379c45b
--- /dev/null
+++ b/416/CH10/EX10.14/exp10_14pp.txt
@@ -0,0 +1,6 @@
+
+ example10.14
+
+power at station 1 is 111MW power at station 2 is 89MW
+ total cost on economic critieria method Rs109879 per hour
+extra operating cost due to erroneous scheduling Rs.121 per hour \ No newline at end of file
diff --git a/416/CH10/EX10.15/exp10_15pp.sce b/416/CH10/EX10.15/exp10_15pp.sce
new file mode 100755
index 000000000..add8435c7
--- /dev/null
+++ b/416/CH10/EX10.15/exp10_15pp.sce
@@ -0,0 +1,32 @@
+clc
+clear
+disp("example 10_15")
+c1=0.002;b1=0.86;a1=20
+c2=0.004;b2=1.08;a2=20
+c3=0.0028;b3=0.64;a3=36
+fc=500
+maxl=120
+minl=36
+tl=200
+d=[1 1 1;2*fc*c1 -fc*2*c2 0;0 -fc*2*c2 fc*2*c3]
+p=[tl;fc*(b2-b1);fc*(b2-b3)]
+pp=inv(d)*p //matrix inversion method
+printf("\nloads on generaating station by economic creatirian method is %dMW,%dMW,%dMW",pp(1),pp(2),pp(3))
+for i=1:3
+ if pp(i)<minl then
+ pp(i)=minl
+ printf("\nload on generating station %d is less then minimum value %dMW \n so it is made equal to minimum value %dMW",i,minl,minl)
+ e=[1 1;d(2,1) -d(3,3)]
+ q=[(tl-pp(i));-p(i)]
+ qq=inv(e)*q //matrix inversion method
+printf("\nloads on generaating station by economic creatirian method is %.3fMW,%.3fMW",qq(1),qq(2))
+ end
+ if pp(i)>maxl then
+ pp(i)=maxl
+ printf("\nload on generating station %d is greater than maximum value %dMW \n so it is made equal to mmaximum value %dMW",i,maxl,maxl)
+ e=[1 1;d(2,1) -d(3,3)]
+ q=[(tl-pp(i));-p(i)]
+ qq=inv(e)*q //matrix inversion method
+printf("\nloads on generaating station by economic creatirian method is %.2fMW,%.2fMW",qq(1),qq(2))
+ end
+end
diff --git a/416/CH10/EX10.15/exp10_15pp.txt b/416/CH10/EX10.15/exp10_15pp.txt
new file mode 100755
index 000000000..81afc0dc6
--- /dev/null
+++ b/416/CH10/EX10.15/exp10_15pp.txt
@@ -0,0 +1,7 @@
+
+ example 10_15
+
+loads on generaating station by economic creatirian method is 85MW,14MW,100MW
+load on generating station 2 is less then minimum value 36MW
+ so it is made equal to minimum value 36MW
+loads on generaating station by economic creatirian method is 72.750MW,91.250MW \ No newline at end of file
diff --git a/416/CH10/EX10.16/exp10_16.sce b/416/CH10/EX10.16/exp10_16.sce
new file mode 100755
index 000000000..50bda3bb4
--- /dev/null
+++ b/416/CH10/EX10.16/exp10_16.sce
@@ -0,0 +1,20 @@
+clc
+clear
+disp("example 10.16")
+//given
+ia=32;ib=32;ic=1.68;f=10^5
+wt=18;rt=24-wt
+p=30
+function [in]=inpu(a,b,c,f,t,p)
+ in=(a+b*p+c*p^2)*f*t
+endfunction
+hi1=inpu(ia,ib,ic,f,wt,p);hi2=inpu(ia,ib,ic,f,rt,p/2)
+disp("(a)")
+printf("for full load condition for %d hours is %ekj \n for half load condition for%d s %ekj \n total load %ekj",wt,hi1,rt,hi2,hi1+hi2)
+disp("(b)")
+te=p*wt+(p/2)*rt
+ul=te/24
+hin=inpu(ia,ib,ic,f,24,ul)
+sav=hi1+hi2-hin
+savp=sav/(te*1000)
+printf("\n total energy produced\t%dMW \n unifor load\t%dMW \n heat input under uniform load condition %ekj \n saving in heat energy %ekj \n saving in heat energy per kWh %dkj/kWh",te,ul,hin,sav,savp) \ No newline at end of file
diff --git a/416/CH10/EX10.16/exp10_16.txt b/416/CH10/EX10.16/exp10_16.txt
new file mode 100755
index 000000000..d7cb61585
--- /dev/null
+++ b/416/CH10/EX10.16/exp10_16.txt
@@ -0,0 +1,14 @@
+
+ example 10.16
+
+ (a)
+for full load condition for 18 hours is 4.507200e+009kj
+ for half load condition for6 s 5.340000e+008kj
+ total load 5.041200e+009kj
+ (b)
+
+ total energy produced 630MW
+ unifor load 26MW
+ heat input under uniform load condition 4.871100e+009kj
+ saving in heat energy 1.701000e+008kj
+ saving in heat energy per kWh 270kj/kWh \ No newline at end of file
diff --git a/416/CH10/EX10.17/exp10_17pp.sce b/416/CH10/EX10.17/exp10_17pp.sce
new file mode 100755
index 000000000..b594f1c25
--- /dev/null
+++ b/416/CH10/EX10.17/exp10_17pp.sce
@@ -0,0 +1,28 @@
+clc
+clear
+disp("example 10.17")
+//given
+a1=450;b1=6.5;c1=0.0013
+a2=300;b2=7.8;c2=0.0019
+a3=80;b3=8.1;c3=0.005
+tl=800//total load
+ma(1)=600
+mi(1)=100
+ma(2)=400
+mi(2)=50
+ma(3)=200
+mi(3)=50
+d=[1 1 1;2*c1 -2*c2 0;0 -2*c2 2*c3]
+p=[tl;(b2-b1);(b2-b3)]
+pp=inv(d)*p //matrix inversion method
+printf("\nloads on generaating station by economic creatirian method isp1=%fMW,p2=%fMW,p3=%fMW",pp(1),pp(2),pp(3))
+for i=1:3
+ if pp(i)<mi(i) then
+ pp(i)=mi(i)
+ end
+ if pp(i)>ma(i) then
+ pp(i)=ma(i)
+ end
+end
+pp(2)=tl-pp(1)-pp(3)
+printf("\nloads on generating station under critical conditions p1=%dMW p2=%dMW p3=%dMW",pp(1),pp(2),pp(3)) \ No newline at end of file
diff --git a/416/CH10/EX10.17/exp10_17pp.txt b/416/CH10/EX10.17/exp10_17pp.txt
new file mode 100755
index 000000000..790e90a96
--- /dev/null
+++ b/416/CH10/EX10.17/exp10_17pp.txt
@@ -0,0 +1,5 @@
+
+ example 10.17
+
+loads on generaating station by economic creatirian method isp1=669.734705MW,p2=116.134272MW,p3=14.131023MW
+loads on generating station under critical conditions p1=600MW p2=150MW p3=50MW \ No newline at end of file
diff --git a/416/CH10/EX10.2/exp10_2.sce b/416/CH10/EX10.2/exp10_2.sce
new file mode 100755
index 000000000..ac488ea37
--- /dev/null
+++ b/416/CH10/EX10.2/exp10_2.sce
@@ -0,0 +1,29 @@
+clear
+clc
+disp("example 10.2")
+mp=250 //from example 10.1
+function [ic]=unit1(p1)
+ ic=0.2*p1+30
+endfunction
+function [ic]=unit2(p2)
+ ic=0.15*p2+40
+endfunction
+mil=20
+ttt=225
+function [p1,p2]=un(ic)
+ p1=(ic-30)/0.2
+ p2=(ic-40)/0.15
+endfunction
+for x=40:5:60
+ [e,r]=un(x)
+ if ttt==e+r then
+ printf("for the same incremental costs unit1 should supply %dMW and unit 2 shold supply %dMW,for equal sharing each unit should supply %3.1fMW",e,r,ttt/2)
+ break
+ end
+end
+opo=ttt/2
+u1=integrate('unit1','p1',opo,e)
+u2=integrate('unit2','p2',r,opo)
+uuu=(u1+u2)*8760
+printf("\nyearly extra cost is (%3.2f-%3.2f)8760 =%dper year",u1,u2,uuu)
+printf("\nthis if the load is equally shared by the two units an extra cost of Rs.%d will be incurred.in other words economic loading would result in saving of Rs.%dper year",uuu,uuu) \ No newline at end of file
diff --git a/416/CH10/EX10.2/exp10_2.txt b/416/CH10/EX10.2/exp10_2.txt
new file mode 100755
index 000000000..e97193833
--- /dev/null
+++ b/416/CH10/EX10.2/exp10_2.txt
@@ -0,0 +1,5 @@
+
+ example 10.2
+for the same incremental costs unit1 should supply 125MW and unit 2 shold supply 100MW,for equal sharing each unit should supply 112.5MW
+yearly extra cost is (671.88-699.22)8760 =12010781per year
+this if the load is equally shared by the two units an extra cost of Rs.12010781 will be incurred.in other words economic loading would result in saving of Rs.12010781per year \ No newline at end of file
diff --git a/416/CH10/EX10.3/exp10_3.sce b/416/CH10/EX10.3/exp10_3.sce
new file mode 100755
index 000000000..bac1dc081
--- /dev/null
+++ b/416/CH10/EX10.3/exp10_3.sce
@@ -0,0 +1,23 @@
+clear
+clc
+disp("example 10.3")
+function [ic]=unit1(p1)
+ ic=0.2*p1+30
+endfunction
+function [ic]=unit2(p2)
+ ic=0.15*p2+40
+endfunction
+tol=400
+pd=50
+u1c=5
+u2c=1/0.15//from example10_1
+p1pd=u1c/(u1c+u2c)
+p2pd=u2c/(u1c+u2c)
+pi=p1pd*pd
+pt=p2pd*pd
+printf("p1=%1.5fMW\n p2=%1.5fMW",pi,pt)
+p11=pi+tol/2
+p22=pt+tol/2
+up1=unit1(p11)
+up2=unit2(p22)
+ printf("\nthe total load on 2 units would be %3.2fMW and %3.2fMW respectevily. it is easy to check that incremental cost will be same for two units at these loading.\n incremental cost of unit1 is %3.2fRs.MW,\n incremantal cost of unit 2 is %3.2fRs./MW",p11,p22,up1,up2)
diff --git a/416/CH10/EX10.3/exp10_3.txt b/416/CH10/EX10.3/exp10_3.txt
new file mode 100755
index 000000000..268d93b18
--- /dev/null
+++ b/416/CH10/EX10.3/exp10_3.txt
@@ -0,0 +1,7 @@
+
+ example 10.3
+p1=21.42857MW
+ p2=28.57143MW
+the total load on 2 units would be 221.43MW and 228.57MW respectevily. it is easy to check that incremental cost will be same for two units at these loading.
+ incremental cost of unit1 is 74.29Rs.MW,
+ incremantal cost of unit 2 is 74.29Rs./MW \ No newline at end of file
diff --git a/416/CH10/EX10.5/exp10_5.sce b/416/CH10/EX10.5/exp10_5.sce
new file mode 100755
index 000000000..f73eb1431
--- /dev/null
+++ b/416/CH10/EX10.5/exp10_5.sce
@@ -0,0 +1,22 @@
+clear
+clc
+disp("example10.5")
+i1=0.8
+i2=1.0
+l1=complex(0.04,0.12)
+l2=complex(0.03,0.1)
+l3=complex(0.03,0.12)
+vl=1
+
+i3=i1+i2
+v1=vl+i3*(l1)+i1*(l2)
+v2=vl+i3*(l1)+i2*(l3)
+p1=real(i1*v1)
+p2=real(i2*v2)
+cos1=real(v1)/abs(v1)
+cos2=real(v2)/abs(v2)
+b11=abs((real(l1)+real(l2))/(v1^2*cos1^2))
+b22=abs((real(l1)+real(l3))/(v2^2*cos2^2))
+b12=abs((real(l1))/(v1*v2*cos1*cos2))
+pl=(p1^2)*b11+(p2^2)*b22+2*p1*p2*b12
+printf("i1+i3=%dpu\nv1=%1.3f+%1.3fp.u\nv2=%1.3f+%1.3fp.u\np1=%1.3fp.u\np2=%1.3fp.u\ncos(ph1)=%1.3f\ncos(ph2)=%1.3f\nb11=%1.5fp.u\nb22=%1.5fp.u\nb12=%1.5fp.u\npl=%1.6fp.u",i3,v1,imag(v1),v2,imag(v2),p1,p2,cos1,cos2,b11,b22,b12,pl) \ No newline at end of file
diff --git a/416/CH10/EX10.5/exp10_5.txt b/416/CH10/EX10.5/exp10_5.txt
new file mode 100755
index 000000000..4be9a21fd
--- /dev/null
+++ b/416/CH10/EX10.5/exp10_5.txt
@@ -0,0 +1,13 @@
+
+ example10.5
+i1+i3=1pu
+v1=1.096+0.296p.u
+v2=1.102+0.336p.u
+p1=0.877p.u
+p2=1.102p.u
+cos(ph1)=0.965
+cos(ph2)=0.957
+b11=0.05827p.u
+b22=0.05764p.u
+b12=0.03312p.u
+pl=0.178800p.u \ No newline at end of file
diff --git a/416/CH10/EX10.7/exp10_7pp.sce b/416/CH10/EX10.7/exp10_7pp.sce
new file mode 100755
index 000000000..10e590283
--- /dev/null
+++ b/416/CH10/EX10.7/exp10_7pp.sce
@@ -0,0 +1,34 @@
+clear
+clc
+disp("example10.7")
+za=complex(0.03,0.09)
+zb=complex(0.1,0.3)
+zc=complex(0.03,0.09)
+zd=complex(0.04,0.12)
+ze=complex(0.04,0.12)
+ia=complex(1.5,-0.4)
+ib=complex(0.5,-0.2)
+ic=complex(1,-0.1)
+id=complex(1,-0.2)
+ie=complex(1.5,-0.3)
+il1=.4
+il2=.6
+na1=1;nb1=0.6;nc1=0;nd1=.4;ne1=.6
+na2=0;nb2=-0.4;nc2=1;nd2=.4;ne2=.6
+vl=1
+//some thing is messed
+v1=vl+za*ia
+v2=vl-zb*ib+zc*ic
+a1=atan(imag(ia)/real(ia))
+a2=atan(imag(ic)/real(ic))
+cosa=cos(a1-a2)
+cosph1=cos(atan(imag(v1)/real(v1))-a1)
+cosph2=cos(atan(imag(v2)/real(v2))-a2)
+b11=(na1^2*real(za)+nb1^2*real(zb)+nc1^2*real(zc)+nd1^2*real(zd)+ne1^2*real(ze))/(abs(v1)^2*cosph1)
+b22=(na2^2*real(za)+nb2^2*real(zb)+nc2^2*real(zc)+nd2^2*real(zd)+ne2^2*real(ze))/((abs(v2)^2)*cosph2)
+bb12=(abs(v1)*abs(v2)*cosph1*cosph2)
+ab12=(na2*na1*real(za)+nb2*nb1*real(zb)+nc1*nc2*real(zc)+nd2*nd1*real(zd)+ne2*ne1*0.03)
+b12=cosa*ab12/bb12
+printf("bus voltages at 2 buses are \nv1=%1.3f+i%1.3f,\nv2=%1.3f+i%1.3f",real(v1),imag(v1),real(v2),imag(v2))
+printf("\nloss coffecients are \nb11=%1.5fp.u\nb22=%1.5fp.u\nb12=%1.5fp.u \n",b11,b22,b12)
+printf("loss coffecients in actual values is \nb11=%eM(W)-1\nb22=%eM(W)-1\nb12=%eM(W)-1\n",b11/100,b22/100,b12/100) \ No newline at end of file
diff --git a/416/CH10/EX10.7/exp10_7pp.txt b/416/CH10/EX10.7/exp10_7pp.txt
new file mode 100755
index 000000000..1a609cd01
--- /dev/null
+++ b/416/CH10/EX10.7/exp10_7pp.txt
@@ -0,0 +1,14 @@
+
+ example10.7
+bus voltages at 2 buses are
+v1=1.081+i0.123,
+v2=0.929+i-0.043
+loss coffecients are
+b11=0.07877p.u
+b22=0.07735p.u
+b12=-0.00714p.u
+loss coffecients in actual values is
+b11=7.877236e-004M(W)-1
+b22=7.734557e-004M(W)-1
+b12=-7.136298e-005M(W)-1
+ \ No newline at end of file
diff --git a/416/CH10/EX10.8/exp10_8pp.sce b/416/CH10/EX10.8/exp10_8pp.sce
new file mode 100755
index 000000000..a67242ad4
--- /dev/null
+++ b/416/CH10/EX10.8/exp10_8pp.sce
@@ -0,0 +1,12 @@
+clear
+clc
+disp("example 10.8")
+r1=22;r2=30;q1=0.2;q2=0.15
+b22=0;b12=0;p1=100;pl=15//transmission losses are 0
+b11=pl/(p1)^2
+function [p1,p2]=power(x) //mathematical computation
+ p1=(x-r1)/(q1+2*b11*x)
+ p2=(x-r2)/q2
+endfunction
+[a,b]=power(60)
+printf("l1=1/(1-%.3f*p1)\nl2=[1/(1-0)]=1\ngiven lamda=60\nsince ic1*l1=lamda ;ic2*l2=lamda\ntotal load=%dMW",b11*2,a+b-(b11*a^2))
diff --git a/416/CH10/EX10.8/exp10_8pp.txt b/416/CH10/EX10.8/exp10_8pp.txt
new file mode 100755
index 000000000..833754f8d
--- /dev/null
+++ b/416/CH10/EX10.8/exp10_8pp.txt
@@ -0,0 +1,7 @@
+
+ example 10.8
+l1=1/(1-0.003*p1)
+l2=[1/(1-0)]=1
+given lamda=60
+since ic1*l1=lamda ;ic2*l2=lamda
+total load=285MW \ No newline at end of file
diff --git a/416/CH10/EX10.9/exp10_9.sce b/416/CH10/EX10.9/exp10_9.sce
new file mode 100755
index 000000000..98bb4a08e
--- /dev/null
+++ b/416/CH10/EX10.9/exp10_9.sce
@@ -0,0 +1,21 @@
+clear
+clc
+disp("example 10.9")
+r1=22;r2=30;q1=0.2;q2=0.15
+b22=0;b12=0;p1=100;pl=15//transmission losses are 0
+b11=pl/(p1)^2
+function [p1,p2]=power(x) //mathematical computation
+ p1=(x-r1)/(q1+2*b11*x)
+ p2=(x-r2)/q2
+endfunction
+[a,b]=power(60)
+pt=a+b-(b11*a^2)
+
+
+
+
+z=integrate('q1*u+r1','u',a,161.80)
+y=integrate('q2*v+r2','v',b,162.5)
+m=z+y
+printf("net change in cost =Rs.%dper hour",m)
+printf("\nthus scheduling the generation by taking transmission losses into account would mean a saving of Rs.%dper hour in fuel cost",m) \ No newline at end of file
diff --git a/416/CH10/EX10.9/exp10_9.txt b/416/CH10/EX10.9/exp10_9.txt
new file mode 100755
index 000000000..d0e92f2a0
--- /dev/null
+++ b/416/CH10/EX10.9/exp10_9.txt
@@ -0,0 +1,4 @@
+
+ example 10.9
+net change in cost =Rs.832per hour
+thus scheduling the generation by taking transmission losses into account would mean a saving of Rs.832per hour in fuel cost \ No newline at end of file
diff --git a/416/CH11/EX11.1/exp11_1.png b/416/CH11/EX11.1/exp11_1.png
new file mode 100755
index 000000000..9aa8ddfd6
--- /dev/null
+++ b/416/CH11/EX11.1/exp11_1.png
Binary files differ
diff --git a/416/CH11/EX11.1/exp11_1pp.sce b/416/CH11/EX11.1/exp11_1pp.sce
new file mode 100755
index 000000000..ca1f515fa
--- /dev/null
+++ b/416/CH11/EX11.1/exp11_1pp.sce
@@ -0,0 +1,95 @@
+clc
+clear
+disp("example 11 1")
+wd=[0 5 8 12 13 17 21 24] //given week days
+wlld=[100 150 250 100 250 350 150] //given load in week days
+wld=[wlld 0]
+we=[0 5 17 21 24]//given week ends
+wed=[100 150 200 150]//given load in week ends
+wed=[wed 0]
+h=90//head
+f=50 //flow
+et=0.97//is available for 97 persent
+eff=0.9 //efficiency
+tl=0.05 //transmission loss
+pa=735.5*f*h*eff/75 //power available
+nap=pa*(1-tl) //net available power
+he=nap*24/1000 //hydro energy for 24 in MW
+he1=round(he/100)*100
+[m,n]=size(wd)
+[x,y]=min(wlld)
+[q,r]=max(wlld)
+for i=1:n-1
+ fl(i)=wd(i+1)-wd(i)
+end
+[o,p]=size(we)
+for i=1:p-1
+ fll(i)=we(i+1)-we(i)
+end
+for j=x:10:q
+ pp=wlld-j
+ for l=1:n-1
+ if pp(l)<0 then
+ pp(l)=0
+ end
+ end
+ heq=pp*fl
+ heq=round(heq/100)*100
+ if heq==he1 then
+ break
+ end
+end//rearrangeing for plot
+subplot(211)
+plot2d2(wd,wld)
+xtitle("chronological load curve for week day for example 11.1","hour of day","load MW")
+subplot(212)
+plot2d2(we,wed)
+xtitle("chronological load curve for weekend day for example 11.1","hour of day","load MW")
+
+printf("power available from the hydro plant for %dMW of the time is %.2fMW",et*100,pa/1000)
+printf("\nnet available hydra power after taking transmission loss into account %.2fMW",nap/100)
+printf("\nhydro energy available during 24 hours %.2fMW",he)
+printf("\nthe magnitude of hydro power is %dMW \ntotal capacity of hydro plant required on week days %dMW ",q-j,(q-j)/(1-tl))
+printf("capacity of thermal plant on week days %dMW",q)
+printf("\nthe schedule for hydro plant is on week days")
+for i=1:n
+ if wd(i)>12 then
+ wd(i)=wd(i)-12
+ end
+end
+disp(wd)
+disp(round(pp/(1-tl)))
+disp("the schedule for thermal plant is on week days")
+disp(wd)
+disp(wlld-pp)
+[m,n]=size(we)
+[x,y]=min(wed)
+[q,r]=max(wed)
+for j=x:10:q
+ pp=wed-j
+ for l=1:n-1
+ if pp(l)<0 then
+ pp(l)=0
+ end
+end
+pp(n)=[]
+ heq=pp*fll
+ heq=floor(heq/100)*100
+ if heq==he1 then
+ break
+ end
+end
+printf("\nthe magnitude of hydro power is %dMW \ntotal capacity of hydro plant required on week ends %dMW ",q-j,(q-j)/(1-tl))
+printf("capacity of thermal plant on week ends %dMW",q)
+printf("\nthe schedule for hydro plant is on week ends")
+for i=1:n
+ if we(i)>12 then
+ we(i)=we(i)-12
+ end
+end
+disp(we)
+disp(round(pp/(1-tl)))
+disp("the schedule for thermal plant is on week days")
+disp(we)
+pp(n)=0
+disp(wed-pp)
diff --git a/416/CH11/EX11.1/exp11_1pp.txt b/416/CH11/EX11.1/exp11_1pp.txt
new file mode 100755
index 000000000..e9344f81f
--- /dev/null
+++ b/416/CH11/EX11.1/exp11_1pp.txt
@@ -0,0 +1,31 @@
+
+ example 11 1
+power available from the hydro plant for 97MW of the time is 39.72MW
+net available hydra power after taking transmission loss into account 377.31MW
+hydro energy available during 24 hours 905.55MW
+the magnitude of hydro power is 140MW
+total capacity of hydro plant required on week days 147MW capacity of thermal plant on week days 350MW
+the schedule for hydro plant is on week days
+ 0. 5. 8. 12. 1. 5. 9. 12.
+
+ 0. 0. 42. 0. 42. 147. 0.
+
+ the schedule for thermal plant is on week days
+
+ 0. 5. 8. 12. 1. 5. 9. 12.
+
+ 100. 150. 210. 100. 210. 210. 150.
+
+the magnitude of hydro power is 90MW
+total capacity of hydro plant required on week ends 94MW capacity of thermal plant on week ends 200MW
+the schedule for hydro plant is on week ends
+ 0. 5. 5. 9. 12.
+
+ 0. 42. 95. 42.
+
+ the schedule for thermal plant is on week days
+
+ 0. 5. 5. 9. 12.
+
+ 100. 110. 110. 110. 0.
+ \ No newline at end of file
diff --git a/416/CH11/EX11.2/exp11_2pp.sce b/416/CH11/EX11.2/exp11_2pp.sce
new file mode 100755
index 000000000..1bb5de4f7
--- /dev/null
+++ b/416/CH11/EX11.2/exp11_2pp.sce
@@ -0,0 +1,38 @@
+clc
+clear
+disp("example 11.2")
+//given
+l1=700;t1=14;l2=500;t2=10
+ac=24;bc=0.02//variables of cost equation
+aw=6;bw=0.0025 //variables of watere quantity equation
+b22=0.0005 //loss coefficient
+r2=2.5
+lam=1:0.001:40
+gg=1;q=1
+for lam=25:0.001:40
+ a=[2*bc 0;0 r2*bw*2+2*b22*lam]
+ b=[lam-ac;lam-aw*r2]
+ p=inv(a)*b
+ g=round(p(1)+p(2))
+ l=round(l1+b22*p(2)^2)
+ lq=round(l2+b22*p(2)^2)
+ if g>=l then
+ printf("\nfor load condition %dMW \n then, \n \t lamda %f \t p1=%fMW \n \t p2=%fMW \t pl=%fMW",l1,lam,p(1),p(2),2*b22*p(2))
+ break
+ end
+end
+for lam=25:0.001:40
+ a=[2*bc 0;0 r2*bw*2+2*b22*lam]
+ b=[lam-ac;lam-aw*r2]
+ pq=inv(a)*b
+ g=round(pq(1)+pq(2))
+ lq=round(l2+b22*pq(2)^2)
+
+ if g>=lq then
+ printf("\nfor load condition %dMW \n then, \n \t lamda %f \t p1=%fMW \n \t p2=%fMW \t pl=%fMW",l2,lam,pq(1),pq(2),2*b22*pq(2))
+ break
+ end
+end
+dwu=[(aw+bw*p(2))*p(2)*t1+t2*(aw+bw*pq(2))*pq(2)]*3600
+doc=[(ac+bc*p(1))*p(1)*t1+(ac+bc*pq(1))*pq(1)*t2]
+printf("\ndaily water used %fm^3 \ndaily operating cost of thermal plant Rs%f",dwu,doc)
diff --git a/416/CH11/EX11.2/exp11_2pp.txt b/416/CH11/EX11.2/exp11_2pp.txt
new file mode 100755
index 000000000..342f0be48
--- /dev/null
+++ b/416/CH11/EX11.2/exp11_2pp.txt
@@ -0,0 +1,13 @@
+
+ example 11.2
+
+for load condition 700MW
+ then,
+ lamda 37.918000 p1=347.950000MW
+ p2=454.559879MW pl=0.454560MW
+for load condition 500MW
+ then,
+ lamda 31.705000 p1=192.625000MW
+ p2=377.898428MW pl=0.377898MW
+daily water used 257972328.067993m^3
+daily operating cost of thermal plant Rs204461.454825 \ No newline at end of file
diff --git a/416/CH11/EX11.3/exp11_3.sce b/416/CH11/EX11.3/exp11_3.sce
new file mode 100755
index 000000000..c01c08849
--- /dev/null
+++ b/416/CH11/EX11.3/exp11_3.sce
@@ -0,0 +1,23 @@
+clc
+clear
+disp("example 11.3")
+//given
+p=250//load
+rt=14 //run time
+t=24//total time
+ac=5;bc=8;cc=0.05 //variables of cost equation
+bw=30;cw=0.05 //variables of water per power
+qw=500//quantity of water
+lam=bc+cc*2*p //lambda
+a=-qw*(10^6)/(3600*rt)
+inn=sqrt(bw^2-4*cw*a)
+phh1=(-bw+inn)/(2*cw)//solution of quadratic equation
+phh2=(-bw-inn)/(2*cw)
+if phh1>0 then
+ r=lam/(bw+cw*phh1)
+ printf(" hydro plant power is %fMW \n the cost of water is %fRs.per hour/m^3/sec",phh1,r)
+end
+if phh2>0 then
+ r=lam/(bw+cw*phh2)
+ printf(" hydro plant power is %fMW \n the cost of water is %fRs.per hour/m^3/sec",phh2,r)
+end \ No newline at end of file
diff --git a/416/CH11/EX11.3/exp11_3.txt b/416/CH11/EX11.3/exp11_3.txt
new file mode 100755
index 000000000..062eb7061
--- /dev/null
+++ b/416/CH11/EX11.3/exp11_3.txt
@@ -0,0 +1,4 @@
+
+ example 11.3
+ hydro plant power is 237.040686MW
+ the cost of water is 0.788492Rs.per hour/m^3/sec \ No newline at end of file
diff --git a/416/CH12/EX12.1/ans12_1pp.txt b/416/CH12/EX12.1/ans12_1pp.txt
new file mode 100755
index 000000000..40c2182e0
--- /dev/null
+++ b/416/CH12/EX12.1/ans12_1pp.txt
@@ -0,0 +1,9 @@
+
+ example 12 1
+
+ a
+ load on 1 alternator 2666.67kW
+ load on 2 alternator 3333.33kW
+ b
+ load supplied by machine 1 with full load on machine2 3200kW
+ total load is 2666kW \ No newline at end of file
diff --git a/416/CH12/EX12.1/example12_1pp.sce b/416/CH12/EX12.1/example12_1pp.sce
new file mode 100755
index 000000000..4eae44f79
--- /dev/null
+++ b/416/CH12/EX12.1/example12_1pp.sce
@@ -0,0 +1,19 @@
+clc
+clear
+disp('example 12 1')
+p=4000 //given kva of alternator
+fnl1=50 //frequency on no load
+fl1=47.5 //frequency on load
+fnl2=50 //frequency on no load on second alternator
+fl2=48 //frequency on load on second alternator
+l=6000 //load given two to alternator
+df1=fnl1-fl1 //change in 1 alternator frequency
+df2=fnl2-fl2 //change in 2 alternator frequency
+l1=df2*(l)/(df2+df1) //load on 1 alternator
+disp('a')
+l2=l-l1
+printf(" load on 1 alternator %.2fkW \n load on 2 alternator %.2fkW",l1,l2)
+ml1=df2*p/df1 //load on 1 machine when machine 2 on full load
+ll=ml1+p
+disp('b')
+printf(" load supplied by machine 1 with full load on machine2 %dkW \n total load is %dkW",ml1,l1) \ No newline at end of file
diff --git a/416/CH12/EX12.2/ans12_2.txt b/416/CH12/EX12.2/ans12_2.txt
new file mode 100755
index 000000000..0f9c27da7
--- /dev/null
+++ b/416/CH12/EX12.2/ans12_2.txt
@@ -0,0 +1,4 @@
+
+ example12_2
+induced emf of a machine a 5.35+1.52i =5.565708kV per phase
+induced emf of a machine b 4.60+1.28i =4.776461kV per phase \ No newline at end of file
diff --git a/416/CH12/EX12.2/example12_2.sce b/416/CH12/EX12.2/example12_2.sce
new file mode 100755
index 000000000..db0b68747
--- /dev/null
+++ b/416/CH12/EX12.2/example12_2.sce
@@ -0,0 +1,23 @@
+clc
+clear
+disp('example12_2')
+l1=3000 //load on 1 machine
+pf1=0.8 //pf on 1 machine
+i2=150 //current on 2 machine
+z1=0.4+12*%i //synchronour impedence
+z2=0.5+10*%i
+vt=6.6 //terminal voltage
+al=l1/2 //active load on each machine
+cosdb=al/(vt*i2*sqrt(3)) //cos db
+db=acosd(cosdb) //angle in digree
+ib=i2*complex(cosdb,-sind(db)) //current in complex number
+it=l1/(vt*pf1*sqrt(3)) //total current
+itc=complex(it*pf1,-it*sind(acosd(pf1))) //total current in complex
+ia=itc-ib
+pfa=atan(imag(ia)/real(ia)) //pf of current a
+ea=(vt/sqrt(3))+ia*(z1)/1000 //voltage a
+pha=atand(imag(ea)/real(ea)) //phase angle of unit a
+printf("induced emf of a machine a %.2f+%.2fi =%fkV per phase",real(ea),imag(ea),abs(ea))
+eb=(vt/sqrt(3))+ib*(z2)/1000 //voltage b
+phb=atand(imag(eb)/real(eb)) //phase angle of unit b
+printf("\ninduced emf of a machine b %.2f+%.2fi =%fkV per phase",real(eb),imag(eb),abs(eb))
diff --git a/416/CH12/EX12.3/ans12_3pp.txt b/416/CH12/EX12.3/ans12_3pp.txt
new file mode 100755
index 000000000..5ecd431dc
--- /dev/null
+++ b/416/CH12/EX12.3/ans12_3pp.txt
@@ -0,0 +1,3 @@
+
+ example12_3
+current is 10.37-4.56iA =11.33A \ No newline at end of file
diff --git a/416/CH12/EX12.3/example12_3pp.sce b/416/CH12/EX12.3/example12_3pp.sce
new file mode 100755
index 000000000..47921e31f
--- /dev/null
+++ b/416/CH12/EX12.3/example12_3pp.sce
@@ -0,0 +1,10 @@
+clc
+clear
+disp('example12_3')
+e1=3000;ph1=20;e2=2900;ph2=0;//given induced emf of two machines
+z1=2+20*%i;z2=2.5+30*%i //impedence of two synchronous machine
+zl=10+4*%i //load impedence
+e11=e1*(cosd(ph1)+sind(ph1)*%i)
+e22=e2*(cosd(ph2)+sind(ph2)*%i)
+is=(e11-e22)*zl/(z1*z2+(z1+z2)*zl)
+printf("current is %.2f%.2fiA =%.2fA",real(is),imag(is),abs(is)) \ No newline at end of file
diff --git a/416/CH12/EX12.4/ans12_4.txt b/416/CH12/EX12.4/ans12_4.txt
new file mode 100755
index 000000000..1ef3a6928
--- /dev/null
+++ b/416/CH12/EX12.4/ans12_4.txt
@@ -0,0 +1,6 @@
+
+ example 12 4
+terminal voltage 239.68V
+current supplied by each 10.72A
+power factor of each 0.894 lagging
+power delivered by each 2297.7941KW \ No newline at end of file
diff --git a/416/CH12/EX12.4/example12_4.sce b/416/CH12/EX12.4/example12_4.sce
new file mode 100755
index 000000000..7a7e0bef1
--- /dev/null
+++ b/416/CH12/EX12.4/example12_4.sce
@@ -0,0 +1,11 @@
+clc
+clear
+disp('example 12 4')
+z=10+5*%i //load
+e1=250;e2=250 //emf of generator
+z1=2*%i;z2=2*%i //synchronous impedence
+v=(e1*z2+z1*e2)/((z1*z2/z)+z1+z2);vph=atand(imag(v)/real(v)) //substitution the value in equation 12.10
+i1=(z2*e1+(e1-e2)*z)/(z1*z2+(z1+z2)*z);iph=atand(imag(i1)/real(i1)) //substitution the value in equation 12.7
+pf1=cosd(vph-iph)
+pd=v*i1*pf1
+printf("terminal voltage %.2fV \ncurrent supplied by each %.2fA \npower factor of each %.3f lagging \npower delivered by each %.4fKW",abs(v),abs(i1),abs(pf1),abs(pd))
diff --git a/416/CH12/EX12.5/ans12_5.txt b/416/CH12/EX12.5/ans12_5.txt
new file mode 100755
index 000000000..ed203f1df
--- /dev/null
+++ b/416/CH12/EX12.5/ans12_5.txt
@@ -0,0 +1,9 @@
+
+ example 12 5
+
+ (a)
+ synchronous power 872kW
+ synchronous torque for 0.5 displacement 2777N-M
+ (b) full load
+ synchronous power 977kW
+ synchronous torque for 0.5 displacement 3111N-M \ No newline at end of file
diff --git a/416/CH12/EX12.5/example12_5.sce b/416/CH12/EX12.5/example12_5.sce
new file mode 100755
index 000000000..1c4d5df5a
--- /dev/null
+++ b/416/CH12/EX12.5/example12_5.sce
@@ -0,0 +1,24 @@
+clc
+clear
+disp('example 12 5')
+po=5 //mva rating
+v=10 //voltage in kv
+n=1500;ns=n/60 //speed
+f=50 //freaquency
+pfb=0.8//power factor in b
+x=0.2*%i //reactance of machine
+md=0.5 //machanical displacement
+//no load
+v=1;e=1;
+p=4
+spu=v*e/abs(x);sp=spu*po*1000;mt=(%pi*p)/(180*2)
+spm=sp*mt //synchronous power in per mech.deree
+st=spm*md*1000/(2*ns*%pi)
+disp('(a)')
+printf(" synchronous power %dkW \n synchronous torque for %.1f displacement %dN-M",spm,md,st)
+disp('(b) full load')
+ee=e+x*(pfb-sind(acosd(pfb))*%i)
+spb=v*abs(ee)*cosd(atand(imag(ee)/real(ee)))/abs(x) //synchronous power
+sppm=spb*po*1000*mt //synchronous power per mech.degree
+stp=sppm*md*1000/(2*%pi*ns)//synchrounous torque under load
+printf(" synchronous power %dkW \n synchronous torque for %.1f displacement %dN-M",sppm,md,stp)
diff --git a/416/CH12/EX12.6/ans12_6.txt b/416/CH12/EX12.6/ans12_6.txt
new file mode 100755
index 000000000..667e404d7
--- /dev/null
+++ b/416/CH12/EX12.6/ans12_6.txt
@@ -0,0 +1,4 @@
+
+ example 12 6
+ synchronous power 502.7kW per mech.degree
+ synchrounous torque 6400N-m \ No newline at end of file
diff --git a/416/CH12/EX12.6/example12_6.sce b/416/CH12/EX12.6/example12_6.sce
new file mode 100755
index 000000000..e236fff3a
--- /dev/null
+++ b/416/CH12/EX12.6/example12_6.sce
@@ -0,0 +1,12 @@
+clc
+clear
+disp('example 12 6')
+po=2*10^6;p=8;n=750;v=6000;x=6*%i;pf=0.8;//given
+i=po/(v*sqrt(3))
+e=(v/sqrt(3))+i*x*(pf-sind(acosd(pf))*%i)
+mt=p*%pi/(2*180)
+cs=cosd(atand(imag(e)/real(e)))
+ps=abs(e)*v*sqrt(3)*cs*mt/(1000*abs(x))
+ns=n/60
+ts=ps*1000/(2*%pi*ns)
+printf(" synchronous power %.1fkW per mech.degree \n synchrounous torque %dN-m",ps,ts) \ No newline at end of file
diff --git a/416/CH12/EX12.7/ans12_7cpp.txt b/416/CH12/EX12.7/ans12_7cpp.txt
new file mode 100755
index 000000000..6efc7ce4c
--- /dev/null
+++ b/416/CH12/EX12.7/ans12_7cpp.txt
@@ -0,0 +1,10 @@
+
+ example 12 7
+
+ a
+ open circuit emf 6598volts per phase and -2.78 degree
+ b.
+ current 365.6A
+ power factor 0.998
+ c.
+current 456.25A \ No newline at end of file
diff --git a/416/CH12/EX12.7/example12_7cpp.sce b/416/CH12/EX12.7/example12_7cpp.sce
new file mode 100755
index 000000000..e620c2a5f
--- /dev/null
+++ b/416/CH12/EX12.7/example12_7cpp.sce
@@ -0,0 +1,22 @@
+clc
+clear
+disp('example 12 7')
+i=100;pf=-0.8;v=11*1000;x=4*%i;ds=10;pfc=-0.8 //given,currents,power factor,voltage,reactance,delta w.r.t steem supply,pf of alternator
+e=(v/sqrt(3))+(i*x*(pf-sind(acosd(pf))*%i))
+disp('a')
+ph=atand(imag(e)/real(e))
+printf(" open circuit emf %dvolts per phase and %.2f degree",abs(e),ph)
+d=ds-ph
+eee=round(abs(e)/100)*100
+ic=round(abs(eee)*sind(d)/abs(x))
+iis=(eee^2-(abs(x)*ic)^2)^(0.5)
+is=(iis-v/sqrt(3))/abs(x)
+tad=is/ic
+d=atand(tad)
+ii=ic/cosd(d)
+pff=cosd(d)
+disp('b.')
+printf(" current %.1fA \n power factor %.3f",ii,pff)
+disp('c.')
+ia=ii*pff/abs(pfc)
+printf("current %.2fA",ia) \ No newline at end of file
diff --git a/416/CH13/EX13.1/example13_1.sce b/416/CH13/EX13.1/example13_1.sce
new file mode 100755
index 000000000..c9d7f1eac
--- /dev/null
+++ b/416/CH13/EX13.1/example13_1.sce
@@ -0,0 +1,20 @@
+clc
+clear
+disp('example 13.1')
+pg=3000 //kva rating of generators single phase
+xg=0.1 //10%reactanse of generator
+vg=11 //voltage at the terminals of generator
+xbf=5 //reactanse of feeder fron bus to fault
+pb=pg;vb=vg;ib=pg/vg //let power and voltage of as respective base then current base
+zb=(vb*10^3)/ib //base impedence
+xpu=xbf/zb //per unit reactance of feeder
+tx=(xg/2)+(xpu) //total reactance
+sckva=pg/tx //short circuit kva is ratio ofpower to total reactance
+sci=sckva/vg //short circuit current
+disp('a')
+printf(" p.u.feeder reactor %.3fp.u \n total reactance is %.3fp.u \n short circuit kVA %dkVA \n short circuit current %.1fA",xpu,tx,sckva,sci)
+gz=zb*xg //generator impedence
+tz=(gz/2)+xbf //total impedence
+scc=(vg*10^3)/tz //short circuit current in ampears
+disp('b')
+printf(" generator impedence %.3fohm \n total impedence %.3f ohm \n short circuit current %.1fA",gz,tz,scc)
diff --git a/416/CH13/EX13.1/example13_1.txt b/416/CH13/EX13.1/example13_1.txt
new file mode 100755
index 000000000..71193ce4a
--- /dev/null
+++ b/416/CH13/EX13.1/example13_1.txt
@@ -0,0 +1,12 @@
+
+ example 13.1
+
+ a
+ p.u.feeder reactor 0.124p.u
+ total reactance is 0.174p.u
+ short circuit kVA 17244kVA
+ short circuit current 1567.7A
+ b
+ generator impedence 4.033ohm
+ total impedence 7.017 ohm
+ short circuit current 1567.7A \ No newline at end of file
diff --git a/416/CH13/EX13.10/example13_10c.sce b/416/CH13/EX13.10/example13_10c.sce
new file mode 100755
index 000000000..0cf56eec8
--- /dev/null
+++ b/416/CH13/EX13.10/example13_10c.sce
@@ -0,0 +1,20 @@
+clc
+clear
+disp('example 13 10') //given //p=power/v=voltage/f=frequency/x=reactance/iff=feeder reactance take off
+pa=20;va=11;f=50;xa=0.2;pb=30;xb=0.2;pf=10;xf=0.06;iff=0.5
+pba=20;vba=11
+xap=xa*pba/pb
+xfp=xf*pba/pf
+nx=xfp+(xa/2)*(xa/2+xap)/(xa+xap)
+fcp=nx^(-1)
+bc=pba*1000/(va*sqrt(3))
+fc=fcp*bc
+disp('a')
+printf("fault current %.2fohm",fc)
+ic=iff*fcp
+xtx=ic^(-1)
+xn=xtx-nx
+zb=va^2/pba
+xnn=xn*zb
+disp('b')
+printf("reactance required %.4fohm",xnn) \ No newline at end of file
diff --git a/416/CH13/EX13.10/example13_10c.txt b/416/CH13/EX13.10/example13_10c.txt
new file mode 100755
index 000000000..223576d8e
--- /dev/null
+++ b/416/CH13/EX13.10/example13_10c.txt
@@ -0,0 +1,7 @@
+
+ example 13 10
+
+ a
+fault current 5524.88ohm
+ b
+reactance required 1.1495ohm \ No newline at end of file
diff --git a/416/CH13/EX13.11/example13_11.sce b/416/CH13/EX13.11/example13_11.sce
new file mode 100755
index 000000000..cfb1e2fdd
--- /dev/null
+++ b/416/CH13/EX13.11/example13_11.sce
@@ -0,0 +1,14 @@
+clc
+clear
+disp('example 13 11')
+n1=5;x=0.4;d=0.1;g=20 //given
+mva=(g/x)+(g*(n1-1)/(x+n1*d))
+n2=10 //given
+mva2=(g/x)+(g*(n2-1)/(x+n2*d))
+disp('a')
+printf("fault MVA =(g/x)+(g*(n-1)/(x+nd)) \n fault level is to equal to fault MVA if n=infinity")
+disp('b')
+printf(" MVA=%.2fMVA if n=%d \n MVA=%.2fMVA if n=%d",mva,n1,mva2,n2)
+fl=g*((1/x)+(1/d))
+disp('c')
+printf("\nfault level %dMVA",fl)
diff --git a/416/CH13/EX13.11/example13_11.txt b/416/CH13/EX13.11/example13_11.txt
new file mode 100755
index 000000000..47f3f8f80
--- /dev/null
+++ b/416/CH13/EX13.11/example13_11.txt
@@ -0,0 +1,12 @@
+
+ example 13 11
+
+ a
+fault MVA =(g/x)+(g*(n-1)/(x+nd))
+ fault level is to equal to fault MVA if n=infinity
+ b
+ MVA=138.89MVA if n=5
+ MVA=178.57MVA if n=10
+ c
+
+fault level 250MVA \ No newline at end of file
diff --git a/416/CH13/EX13.2/example13_2.sce b/416/CH13/EX13.2/example13_2.sce
new file mode 100755
index 000000000..358cca267
--- /dev/null
+++ b/416/CH13/EX13.2/example13_2.sce
@@ -0,0 +1,23 @@
+clc
+clear
+disp('example 13.2')
+pa1=20000 ;pa2=30000 //kva in in 3 ph power
+va1=11 ;va2=11 //voltage in kilo volts
+pt1=20000 ;pt2=30000//kva of 3 ph transformer
+vpt1=11 ;vpt2=11//voltage of primery of transformer
+vst1=132 ;vst2=132//voltage of secondary of transformer
+xg1=0.5 ;xg2=0.65 //reactance of generator
+xt1=0.05 ;xt2=0.05 //reactance of transformer with their own kva
+pb=pa2;vbg=va2;vbt=vpt2;//assumeing base quantoties
+xtn1=xt1*pb/pa1 ;xtn2=xt2*pb/pa2 //transformer reactance with new base
+xgn1=xg1*pb/pa1;xgn2=xg2*pb/pa2
+xn1=xtn1+xgn1;xn2=xtn2+xgn2 //reactancee up to fault from each generator
+xn=(xn1*xn2)/(xn1+xn2) //equalent reactance between generator and fault
+sckva=pb/xn ; //short circuit KVA
+disp('(a)')
+printf(" equivalent reactance is %.4f p.u \n short circuit KVA %dKVA",xn,sckva)
+disp('(b)')
+sccb=sckva/(vst1*sqrt(3))
+sccg1=sccb*(xn2/(xn1+xn2))*vst1/vpt1
+sccg2=sccb*(xn1/(xn1+xn2))*vst2/vpt2
+printf(" short circuit current on bus bar side %.1fA \n short circuit current of generator 1 is %.1fA \n short circuit current of generator 2 is %.1fA \n",sccb,sccg1,sccg2)
diff --git a/416/CH13/EX13.2/example13_2.txt b/416/CH13/EX13.2/example13_2.txt
new file mode 100755
index 000000000..d2c6a5a5a
--- /dev/null
+++ b/416/CH13/EX13.2/example13_2.txt
@@ -0,0 +1,11 @@
+
+ example 13.2
+
+ (a)
+ equivalent reactance is 0.3787 p.u
+ short circuit KVA 79220KVA
+ (b)
+ short circuit current on bus bar side 346.5A
+ short circuit current of generator 1 is 1908.6A
+ short circuit current of generator 2 is 2249.4A
+ \ No newline at end of file
diff --git a/416/CH13/EX13.3/example13_3.sce b/416/CH13/EX13.3/example13_3.sce
new file mode 100755
index 000000000..454a2f6cd
--- /dev/null
+++ b/416/CH13/EX13.3/example13_3.sce
@@ -0,0 +1,23 @@
+clc
+clear
+disp('example 13.3')
+pa1=20000 ;pa2=30000 //kva in in 3 ph power
+va1=11 ;va2=11 //voltage in kilo volts
+pt1=20000 ;pt2=30000//kva of 3 ph transformer
+vpt1=11 ;vpt2=11//voltage of primery of transformer
+vst1=132 ;vst2=132//voltage of secondary of transformer
+xg1=0.5 ;xg2=0.65 //reactance of generator
+xt1=0.05 ;xt2=0.05 //reactance of transformer with their own kva
+pb=pa2;vbg=va2;vbt=vpt2;//assumeing base quantoties
+xtn1=xt1*pb/pa1 ;xtn2=xt2*pb/pa2 //transformer reactance with new base
+xgn1=xg1*pb/pa1;xgn2=xg2*pb/pa2
+xn1=xtn1+xgn1;xn2=xtn2+xgn2 //reactancee up to fault from each generator
+xn=(xn1*xn2)/(xn1+xn2) //equalent reactance between generator and fault
+sckva=pb/xn ; //short circuit KVA
+pf=50000 //fault kva rating
+xf=pb/pf //reactance from fault
+xx=xf*xn1/(xn1-xf)
+x=xx-xn2 //reactance to be added
+bi=(vst1^2)*1000/(pb)
+xo=x*bi
+printf(" reactance to be added in circuit of generator 2 have %.1f p.u. \n reactance in ohms %.1f",x,xo) \ No newline at end of file
diff --git a/416/CH13/EX13.3/example13_3.txt b/416/CH13/EX13.3/example13_3.txt
new file mode 100755
index 000000000..df936f279
--- /dev/null
+++ b/416/CH13/EX13.3/example13_3.txt
@@ -0,0 +1,4 @@
+
+ example 13.3
+ reactance to be added in circuit of generator 2 have 1.5 p.u.
+ reactance in ohms 871.2 \ No newline at end of file
diff --git a/416/CH13/EX13.4/example13_4cpp.sce b/416/CH13/EX13.4/example13_4cpp.sce
new file mode 100755
index 000000000..e7179fe77
--- /dev/null
+++ b/416/CH13/EX13.4/example13_4cpp.sce
@@ -0,0 +1,8 @@
+clc
+clear
+disp('example 13.4')
+pa=50;xgb=0.5;xb=0.1;//given power,reactance of generator
+x1=xgb+xb;
+x=x1*x1*xgb/(x1*x1+x1*xgb+x1*xgb)
+f=pa/x
+printf(" total reactance %.4f.p.u \n fault MVA %.1fMVA",x,f) \ No newline at end of file
diff --git a/416/CH13/EX13.4/example13_4cpp.txt b/416/CH13/EX13.4/example13_4cpp.txt
new file mode 100755
index 000000000..aa70645b8
--- /dev/null
+++ b/416/CH13/EX13.4/example13_4cpp.txt
@@ -0,0 +1,4 @@
+
+ example 13.4
+ total reactance 0.1875.p.u
+ fault MVA 266.7MVA \ No newline at end of file
diff --git a/416/CH13/EX13.5/example13_5nc.sce b/416/CH13/EX13.5/example13_5nc.sce
new file mode 100755
index 000000000..70a7bf79f
--- /dev/null
+++ b/416/CH13/EX13.5/example13_5nc.sce
@@ -0,0 +1,40 @@
+clc
+clear
+disp('example13_5')
+vb=33
+pb=20;zb=vb^2/pb //base voltage and base power
+pa1=10;pa2=10;xa1=0.08;xa2=0.08; //given power and reactance for different branches
+pbb=20;xb=0.06;pc=15;xc=0.12;pd=20;xd=0.08;
+xab=2.17;xbc=3.26;xcd=1.63;xda=4.35;
+xap1=xa1*pb/pa1;
+xap2=xa2*pb/pa2;xap=xap1*xap2/(xap1+xap2)
+xbp=xb*pb/pbb;
+xcp=xc*pb/pc;
+xdp=xd*pb/pd; //generators reactance in per unit
+xabp=round(xab*100/zb)/100;
+xbcp=round(xbc*100/zb)/100;
+xcdp=round(xcd*100/zb)/100;
+xdap=round(xda*100/zb)/100 //reactance in per unit between bus
+function [s1,s2,s3]=del2star(d12,d23,d31)
+ dsum=d12+d23+d31
+ s1=d12*d31/(dsum)
+ s2=d12*d23/(dsum)
+ s3=d31*d23/dsum
+endfunction
+function [d12,d31,d23]=star2del(s1,s2,s3)
+ d12=s1+s2+(s1*s2)/s3
+ d23=s2+s3+(s2*s3)/s1
+ d31=s3+s1+(s3*s1)/s2
+endfunction
+[xac,xrc,xra]=star2del(xcdp,xdap,xdp)
+rc=xrc*xcp/(xrc+xcp)
+ra=xra*xap/(xra+xap)
+[xpr,xpc,xpa]=del2star(xac,rc,ra)
+xf1=xbcp+xpc
+xf2=xpr+xabp
+xf=xf1*xf2/(xf1+xf2)
+xfr=xf+xpa
+xx=xfr*xbp/(xfr+xbp)
+netr=xx //net reactance
+fkva=pb*1000/xx
+printf("the rating of circuit breaker should be %d KVA, or %d MVA",fkva,fkva/1000)
diff --git a/416/CH13/EX13.5/example13_5nc.txt b/416/CH13/EX13.5/example13_5nc.txt
new file mode 100755
index 000000000..050535bc3
--- /dev/null
+++ b/416/CH13/EX13.5/example13_5nc.txt
@@ -0,0 +1,4 @@
+
+ example13_5
+the rating of circuit breaker should be 671200 KVA, or 671 MVA
+ \ No newline at end of file
diff --git a/416/CH13/EX13.6/example13_6c.sce b/416/CH13/EX13.6/example13_6c.sce
new file mode 100755
index 000000000..c819f75df
--- /dev/null
+++ b/416/CH13/EX13.6/example13_6c.sce
@@ -0,0 +1,15 @@
+clc
+clear
+disp('example 13_6')
+p=150 //given ,power
+v=11 //given voltage
+xg=0.12 //reactance of generator
+xb=0.08 //reactance of line
+scca=1/xg
+ms=scca^2
+sccb=1/(xg+xb)
+ms1=sccb^2
+disp('a')
+printf("short circuit current is %.3fp.u \n ratio of mechanical stress on short circuit to aech. stresses on full load %.2f",scca,ms)
+disp('b')
+printf("short circuit current is with reactor %.3fp.u \n ratio of mechanical stress on short circuit to aech. stresses on full load with reactor %.f",sccb,ms1) \ No newline at end of file
diff --git a/416/CH13/EX13.6/example13_6c.txt b/416/CH13/EX13.6/example13_6c.txt
new file mode 100755
index 000000000..7b1681a68
--- /dev/null
+++ b/416/CH13/EX13.6/example13_6c.txt
@@ -0,0 +1,8 @@
+example 13_6
+
+ a
+short circuit current is 8.333p.u
+ ratio of mechanical stress on short circuit to aech. stresses on full load 69.44
+ b
+short circuit current is with reactor 5.000p.u
+ ratio of mechanical stress on short circuit to aech. stresses on full load with reactor 25 \ No newline at end of file
diff --git a/416/CH13/EX13.7/example13_7pp.sce b/416/CH13/EX13.7/example13_7pp.sce
new file mode 100755
index 000000000..9766ed60e
--- /dev/null
+++ b/416/CH13/EX13.7/example13_7pp.sce
@@ -0,0 +1,9 @@
+clc
+clear
+disp('example13_7')
+xf=complex(0,0.04)
+pf=0.8;ph=acosd(pf)
+v=1;i=1;//let v and i
+vb=v+i*xf*(complex(cosd(ph),-sind(ph)))
+iv=vb-abs(v);
+printf("bus bar voltage %.4f.p.u at angle %.1f\n increase in voltage %.4f =%.4fpersent",abs(vb),atand(imag(vb)/real(vb)),iv,iv*100) \ No newline at end of file
diff --git a/416/CH13/EX13.7/example13_7pp.txt b/416/CH13/EX13.7/example13_7pp.txt
new file mode 100755
index 000000000..12f1a1d6a
--- /dev/null
+++ b/416/CH13/EX13.7/example13_7pp.txt
@@ -0,0 +1,5 @@
+
+
+ example13_7
+bus bar voltage 1.0245.p.u at angle 1.8
+ increase in voltage 0.0240 =2.4000persent \ No newline at end of file
diff --git a/416/CH13/EX13.8/example13_8c.sce b/416/CH13/EX13.8/example13_8c.sce
new file mode 100755
index 000000000..4b93bdc37
--- /dev/null
+++ b/416/CH13/EX13.8/example13_8c.sce
@@ -0,0 +1,17 @@
+clc
+clear
+disp('example 13 8');
+p1=30;x1=0.3 //power and reactance of different sets
+p2=30;x2=0.3
+p3=20;x3=0.3
+l=10 ;xl=0.04
+pb=p1;xp3=x3*pb/p3
+tr=(xp3*x1*x2)/(xp3*x1+xp3*x2+x1*x2)
+sc=pb/tr
+disp('a')
+printf("total reactance %.4f p.u \n short circuit MVA on l.v.bus %.2fMVA",tr,sc)
+disp('b')
+xlp=xl*pb/l
+trr=tr+xlp
+scc=pb/trr
+printf("total reactance seen from h.v.side of transformer %.2fp.u \n short circuit MVA %.2fMVA",trr,scc)
diff --git a/416/CH13/EX13.8/example13_8c.txt b/416/CH13/EX13.8/example13_8c.txt
new file mode 100755
index 000000000..eafce43be
--- /dev/null
+++ b/416/CH13/EX13.8/example13_8c.txt
@@ -0,0 +1,9 @@
+
+ example 13 8
+
+ a
+total reactance 0.1125 p.u
+ short circuit MVA on l.v.bus 266.67MVA
+ b
+total reactance seen from h.v.side of transformer 0.23p.u
+ short circuit MVA 129.03MVA \ No newline at end of file
diff --git a/416/CH13/EX13.9/example13_9pp.sce b/416/CH13/EX13.9/example13_9pp.sce
new file mode 100755
index 000000000..700fac4f7
--- /dev/null
+++ b/416/CH13/EX13.9/example13_9pp.sce
@@ -0,0 +1,14 @@
+clc
+clear
+disp("example 13 9")
+p1=30;x1=0.15;p2=10;x2=0.125;
+pt=10;vs=3.3;pm=100
+pb=p1 //let base as power of unit 1
+x22=x2*pb/p2;x11=x1*pb/p1
+xx=1/((1/x22)+(1/x11)+(1/x11))
+xl=(pb/pm)-xx
+xt2=xl*pt/pb
+bi=vs^2/pt
+xtt=xt2*bi
+disp('a')
+printf("reactance of transformer is %.4f.p.u \n reactance of transformer on %dMVA base is %.5fp.u. \n reactance of transformer %.4fohm",xl,pt,xl,xtt) \ No newline at end of file
diff --git a/416/CH13/EX13.9/example13_9pp.txt b/416/CH13/EX13.9/example13_9pp.txt
new file mode 100755
index 000000000..df7f470b5
--- /dev/null
+++ b/416/CH13/EX13.9/example13_9pp.txt
@@ -0,0 +1,7 @@
+
+ example 13 9
+
+ a
+reactance of transformer is 0.2375.p.u
+ reactance of transformer on 10MVA base is 0.23750p.u.
+ reactance of transformer 0.0862ohm \ No newline at end of file
diff --git a/416/CH14/EX14.1/ans14_1.txt b/416/CH14/EX14.1/ans14_1.txt
new file mode 100755
index 000000000..05265b35e
--- /dev/null
+++ b/416/CH14/EX14.1/ans14_1.txt
@@ -0,0 +1,4 @@
+
+ example 14.1
+speed regulation of alternator is 0.02Hz/MW
+ change in power output 5MW \ No newline at end of file
diff --git a/416/CH14/EX14.1/example14_1.sce b/416/CH14/EX14.1/example14_1.sce
new file mode 100755
index 000000000..7bf3161ef
--- /dev/null
+++ b/416/CH14/EX14.1/example14_1.sce
@@ -0,0 +1,10 @@
+clc
+clear
+disp('example 14.1')
+p=100 //rating of alternater
+sd=0.04 //speed of alrternator drops
+df=-0.1 //change in frequency and drops so -ve
+f=50 //frequency is 50hz
+r=sd*f/p //r in hz/MW
+dp=-(df)/r
+printf("speed regulation of alternator is %.2fHz/MW \n change in power output %dMW",r,dp) \ No newline at end of file
diff --git a/416/CH14/EX14.10/ans14_10.txt b/416/CH14/EX14.10/ans14_10.txt
new file mode 100755
index 000000000..8b66d369a
--- /dev/null
+++ b/416/CH14/EX14.10/ans14_10.txt
@@ -0,0 +1,11 @@
+
+ example14.10
+
+transfer function of governor gr= 1/(1+0.2*s)
+ transfer function of turbine gt=1/(1+2*s)
+transfer function of power system
+ Gp=(50/(1+10*s)
+ Df=-gp/(1+(0.5*(gr*gt*gp)))
+the largest step in the load if the frequency change by more than 0.01 in steady state -18765MW
+the minu sign is becose of the that if frequency is to increase by 0.010000
+the change in load be negative. \ No newline at end of file
diff --git a/416/CH14/EX14.10/example14_10.sce b/416/CH14/EX14.10/example14_10.sce
new file mode 100755
index 000000000..e230b59af
--- /dev/null
+++ b/416/CH14/EX14.10/example14_10.sce
@@ -0,0 +1,33 @@
+clc
+clear
+disp('example14.10')
+tg=0.2 //time constent of steam turbine
+t=2 //time constant of turbine
+h=5 //inertia constent
+r=0.04 //given
+dl=0.01 //change in load
+df=0.01 //change in frequency
+c=1500 //capacity
+f=50 //frequency
+adl=0.01 //max allowable change in load
+printf("\ntransfer function of governor gr= 1/(1+%.1f*s) \n transfer function of turbine gt=1/(1+%d*s)",tg,t)
+rr=r*f
+d=(dl*c)/(df*f)
+dpu=(d/c)
+kp=(1/dpu)
+tp=(kp*(2*h)/(f))
+printf("\ntransfer function of power system \n Gp=(%d/(1+%d*s)\n Df=-gp/(1+(0.5*(gr*gt*gp)))",kp,tp)
+ddf=-(kp)/(1+kp/r)
+dff=df*f
+m=dff/(ddf)
+mm=m*c
+disp('(b)')
+printf("\nthe largest step in the load if the frequency change by more than %.2f in steady state %dMW",adl,mm)
+if mm<0
+ printf("\nthe minu sign is becose of the that if frequency is to increase by %f \nthe change in load be negative.",adl)
+else
+ printf("\nthe largest step in load if the frequency is to decrease by %f /n the change in load be positive",adl)
+end
+disp('(c)')
+
+disp('when integral controller is used,static frequency error is zero') \ No newline at end of file
diff --git a/416/CH14/EX14.11/ans14_11.txt b/416/CH14/EX14.11/ans14_11.txt
new file mode 100755
index 000000000..2158e82b3
--- /dev/null
+++ b/416/CH14/EX14.11/ans14_11.txt
@@ -0,0 +1,4 @@
+
+ example 14_11
+change in frequency is -0.01307Hz
+change in power -0.003333 p.u.MW \ No newline at end of file
diff --git a/416/CH14/EX14.11/example14_11.sce b/416/CH14/EX14.11/example14_11.sce
new file mode 100755
index 000000000..d4f502fa8
--- /dev/null
+++ b/416/CH14/EX14.11/example14_11.sce
@@ -0,0 +1,21 @@
+clc
+clear
+disp('example 14_11')
+pa=5000 //power of unit a
+pb=10000 //power of unit b
+r=2 //given speed regulation in p.uMW
+d=0.01 //d in p.u.MW/Hz
+dpa=0 //change in power in unit a
+dpb=-100 //change in power in unit b
+pbas=10000 //assume base as 10000
+ra=r*pbas/pa //speed regulation of the unit a
+da=d*pa/pbas //da of unit b
+rb=r*pbas/pb //speed regulation of unit b
+db=d*pb/pbas //db of unit b
+ba=da+(1/ra) //area frequency response of a
+bb=db+(1/rb) //area frequency response of b
+ma=dpa/pbas //change in power a in per unit in unit a
+mb=dpb/pbas //change in power a in per unit in unit b
+df=(ma+mb)/(ba+bb) //change in frequency
+dpab=(ba*mb-bb*ma)/(ba+bb) //change in power between ab
+printf("change in frequency is %.5fHz \nchange in power %.6f p.u.MW",df,dpab)
diff --git a/416/CH14/EX14.12/ans14_12pp.txt b/416/CH14/EX14.12/ans14_12pp.txt
new file mode 100755
index 000000000..7045b82c5
--- /dev/null
+++ b/416/CH14/EX14.12/ans14_12pp.txt
@@ -0,0 +1,11 @@
+
+ example 14.12
+
+ (a)
+change in frequency is -0.016Hz
+ change in power between ab -0.00832p.u.MW
+ -16.64MW
+ (b)
+change in frequency is -0.016Hz
+ change in power between ab 0.00168p.u.MW
+ change in power 3.360000MW \ No newline at end of file
diff --git a/416/CH14/EX14.12/example14_12pp.sce b/416/CH14/EX14.12/example14_12pp.sce
new file mode 100755
index 000000000..63991e714
--- /dev/null
+++ b/416/CH14/EX14.12/example14_12pp.sce
@@ -0,0 +1,35 @@
+clc
+clear
+disp('example 14.12')
+pa=500 //power of unit a
+pb=2000 //power of unit b
+ra=2.5 //speed regulation of a
+rb=2 //speed regulation of b
+dl=0.01 //change in load
+df=0.01 // change in frequency
+pt=20 //change in tie line power
+ptl=0 //let other power station has zero
+pbas=2000 //assume base as 2000MW
+f=50 //assume frequency
+da=(dl*pa)/(df*f) //change in power w.r.t frequency
+dapu=da/(pbas) // change in power w.r.t frequency in per unit
+db=(dl*pb)/(df*f) //change in power in unit b
+dbpu=db/pbas //change in power w.r.t frequency in per unit
+raa=ra*pbas/pa //speed regulation with pbase
+rbb=rb*pbas/pb //speed regulation with pbase
+ba=dapu+(1/raa) //area frequency response a
+bb=dbpu+(1/rbb) //area frequency response b
+ma=pt/pbas //assume change in power in unit a alone due to tie power
+mb=ptl/pbas //change in power in unit b
+df=-(ma+mb)/(ba+bb) //change in frequency
+dpp=(ba*mb-bb*ma)/(ba+bb) //change in power
+disp('(a)')
+printf("change in frequency is %.3fHz \n change in power between ab %.5fp.u.MW \n \t\t%.2fMW",df,dpp,dpp*pbas)
+ma2=ptl/pbas //assume change in power in unit a alone due to tie power
+mb2=pt/pbas //change in power in unit b
+df2=-(ma2+mb2)/(ba+bb) //change in frequency
+dpp2=(ba*mb2-bb*ma2)/(ba+bb) //change in power
+disp('(b)')
+dpba=dpp2*pbas
+printf("change in frequency is %.3fHz \n change in power between ab %.5fp.u.MW \n",df2,dpp2)
+printf(" change in power %fMW",dpba) \ No newline at end of file
diff --git a/416/CH14/EX14.13/ans14_13.txt b/416/CH14/EX14.13/ans14_13.txt
new file mode 100755
index 000000000..32dffaab6
--- /dev/null
+++ b/416/CH14/EX14.13/ans14_13.txt
@@ -0,0 +1,7 @@
+
+ example 14.13
+the damped angular frequency is 7.11radians/sec if speed govenor loop is closed
+ (b)
+since the two area are imilier ,each area will supply half of increase in load .this also evident besause ba=bb
+ change in power 50MW
+ speed regulation is infininydamped angular frequency if speed governor loop is open 2.687rad/sec \ No newline at end of file
diff --git a/416/CH14/EX14.13/example14_13.sce b/416/CH14/EX14.13/example14_13.sce
new file mode 100755
index 000000000..e35ef2f0e
--- /dev/null
+++ b/416/CH14/EX14.13/example14_13.sce
@@ -0,0 +1,19 @@
+clc
+clear
+disp('example 14.13')
+p=4000 //power area
+n=2 //number of units
+r=2 //speed regulation
+h=5
+pt=600 //given tie power
+pan=40 //power angle
+stp=100
+f=50
+t=(pt/p)*cosd(pan)
+wo=((2*%pi*f*t/h)^2-(f/(4*r*h))^2)^(0.5)
+printf("the damped angular frequency is %.2fradians/sec if speed govenor loop is closed",wo)
+disp('(b)')
+printf("since the two area are imilier ,each area will supply half of increase in load .this also evident besause ba=bb \n change in power %dMW \n speed regulation is infininy",stp/2)
+wo1=(2*%pi*f*t/h)^(0.5) //if govenor loop is open alpha is zero
+printf("damped angular frequency if speed governor loop is open %.3frad/sec ",wo1)
+
diff --git a/416/CH14/EX14.14/ans14_14.txt b/416/CH14/EX14.14/ans14_14.txt
new file mode 100755
index 000000000..465296732
--- /dev/null
+++ b/416/CH14/EX14.14/ans14_14.txt
@@ -0,0 +1,7 @@
+
+ example14.14
+the reactive power supply and reseving power is 132kV
+reactive power -15.91Mvar
+the required compensator network neeeded 45.91Mvar
+ (b)
+thus under no load condition the line delivers 3.33Mvar at receiving end.the reactive power must be absorbed by shunt reactor at receving end. thus the capacity of shunt reactor, for no load condition is 3.33Mvar. \ No newline at end of file
diff --git a/416/CH14/EX14.14/example14_14.sce b/416/CH14/EX14.14/example14_14.sce
new file mode 100755
index 000000000..a170fe4a5
--- /dev/null
+++ b/416/CH14/EX14.14/example14_14.sce
@@ -0,0 +1,27 @@
+clc
+clear
+disp('example14.14')
+Aa=0.98;Ap=3 //magnitude and angle of constant A
+Ba=110;Bp=75 //magnitude and angle of constant B
+p=50 //given power 50
+pf=0.8 //given power factor is 0.8
+vr=132 //voltage at reseving station
+vs=132 //voltage at source station to be maintained
+vsr1=p*pf+(Aa*(vr^2)/Ba)*cosd(Bp-Ap)
+ph=vsr1*Ba/(vs*vr)
+phh=acosd(ph)
+del=Bp-phh
+qrr=((vs*vr/Ba)*sind(phh))-((Aa*(vr)^(2)/Ba)*sind(Bp-Ap)) //reactive power to maintain voltage equal
+qrre=p*sind(acosd(pf)) //reactive power for the load
+qrc=qrre-qrr
+printf("the reactive power supply and reseving power is %dkV \nreactive power %.2fMvar",vs,qrr)
+printf("\nthe required compensator network neeeded %.2fMvar",qrc)
+disp('(b)')
+cosb=(Aa*cosd(Bp-Ap)*(vr)^(2)/Ba)*(Ba/(vs*vr)) //under no oad condition
+phb=acosd(cosb)
+qrb=(vs*vr*sind(phb)/Ba)-(Aa*vr*vr*sind(Bp-Ap)/Ba)
+if qrb>0 then
+ printf("thus under no load condition the line delivers %.2fMvar at receiving end.the reactive power must be absorbed by shunt reactor at receving end. thus the capacity of shunt reactor, for no load condition is %.2fMvar. ",qrb,qrb)
+else
+ printf("thus under no load condition the line absorbs %.2fMvar at receiving end.the reactive power must be delivered by shunt reactor at receving end. or reactive must suppiled by the source thus the capacity of shunt reactor, for no load condition is %.2fMvar. ",qrb,qrb)
+end
diff --git a/416/CH14/EX14.15/ans14_15.txt b/416/CH14/EX14.15/ans14_15.txt
new file mode 100755
index 000000000..f9ae30f60
--- /dev/null
+++ b/416/CH14/EX14.15/ans14_15.txt
@@ -0,0 +1,3 @@
+example 14.15
+ tapping ratio at the source 1.058
+ tapping ratio at the receving end 0.94 \ No newline at end of file
diff --git a/416/CH14/EX14.15/example14_15.sce b/416/CH14/EX14.15/example14_15.sce
new file mode 100755
index 000000000..a7def9a21
--- /dev/null
+++ b/416/CH14/EX14.15/example14_15.sce
@@ -0,0 +1,15 @@
+clc
+clear
+disp('example 14.15')
+v=220 //line voltage
+ps=11 ;ss=220;pr=220;sr=11 //primer and secondary end terminal voltages of tapping transformer
+zr=20;zi=60 //impedence of line in real ndimagenary parts
+p=100 //power at recieving end is 100MVA
+pf=0.8 //power factor at recievin end
+t=1 //prodect of 2 off terminal tap setting is 1
+vt=11 //tap setting for 11 kv voltage bus
+P=(p*pf*10^6)/3 //real power
+Q=(p*sind(acosd(pf))*10^6)/3 //reactance power
+v1=v*(10^3)/sqrt(3)
+ts=(1/(1-(zr*P+zi*Q)/(v1^2)))^(0.5)
+printf(" tapping ratio at the source %.3f \n tapping ratio at the receving end %.2f",ts,1/ts) \ No newline at end of file
diff --git a/416/CH14/EX14.16/ans14_16pp.txt b/416/CH14/EX14.16/ans14_16pp.txt
new file mode 100755
index 000000000..c3926bb62
--- /dev/null
+++ b/416/CH14/EX14.16/ans14_16pp.txt
@@ -0,0 +1,13 @@
+
+ example 14.16
+
+ (a)
+vn=0.853.p.u
+ vn=112.628kV
+ (b)
+vn=1.021.p.u
+ vn=134.772kV
+ transformation ratio under load condition 3.413
+ transformation ratio under no load condition 4.084
+ the actual ratio can be taken as mean of the above value i.e.3.748percent
+ varying by (+/-)0.336percent \ No newline at end of file
diff --git a/416/CH14/EX14.16/example14_16pp.sce b/416/CH14/EX14.16/example14_16pp.sce
new file mode 100755
index 000000000..cd9e6750e
--- /dev/null
+++ b/416/CH14/EX14.16/example14_16pp.sce
@@ -0,0 +1,28 @@
+clc
+clear
+disp('example 14.16')
+vp=132;vs=33;vt=11 //voltage at primary ,secondary ,teritiory
+pp=75;ps=50;pt=25 //MVA rating at prinary ,secondary,teritiory
+rpr=0.12;rv=132;rp=75 //reactance power of primary under rv and rp as voltage and power base
+poa=60;rea=50 //load real and reactive power a
+pva=125;svaa=33 //primary and secondary voltage a
+svsb=25;pvb=140;svbb=33 //primary and secondary voltage at no load
+disp('(a)')
+vbas=132 ;mvabas=75 //assume voltage and MVA base
+v1pu=pva/vbas //voltage in per unit
+v1apu=round(v1pu*1000)/1000 //rounding off
+qre=rea/mvabas //reactive power in per unit
+vn1a=(v1apu+sqrt(v1apu^2-4*rpr*qre))/2 //voltage using quadratic equation formulae
+vn2a=(v1apu-sqrt(v1apu^2-4*rpr*qre))/2
+vnaa=vn1a*vbas
+v12=pvb/vbas
+q=svsb/mvabas
+vn1b=(v12+sqrt(v12^2-4*rpr*q))/2 //voltage using quadratic equation formulae
+vn1b=round(vn1b*1000)/1000
+vnbb=vn1b*vbas //vn in no load condition
+printf("vn=%.3f.p.u \n vn=%.3fkV",vn1a,vnaa)
+disp('(b)')
+printf("vn=%.3f.p.u \n vn=%.3fkV",vn1b,vnbb)
+z=vnaa/svaa;x=vnbb/svbb;
+printf("\n transformation ratio under load condition %.3f \n transformation ratio under no load condition %.3f \n the actual ratio can be taken as mean of the above value i.e.%.3fpercent\n varying by (+/-)%.3fpercent",z,x,(z+x)/2,x-(z+x)/2)
+
diff --git a/416/CH14/EX14.17/ans14_17.txt b/416/CH14/EX14.17/ans14_17.txt
new file mode 100755
index 000000000..aaeafcfb6
--- /dev/null
+++ b/416/CH14/EX14.17/ans14_17.txt
@@ -0,0 +1,5 @@
+
+ example 14.7
+ generation at the plant a is 160MW and
+ generation at the plant b is 40MW
+ transfer power from plant a to b is 60MW \ No newline at end of file
diff --git a/416/CH14/EX14.17/example14_17.sce b/416/CH14/EX14.17/example14_17.sce
new file mode 100755
index 000000000..d42566e11
--- /dev/null
+++ b/416/CH14/EX14.17/example14_17.sce
@@ -0,0 +1,16 @@
+clc
+clear
+disp('example 14.7')
+ca=200 //capacity of unit a
+cb=100 //capacity of unit b
+ra=1.5 //speed regulation of unit a
+rb=3 //speed regulation of unit b
+f=50 //frequency
+pla=100 //load on each bus
+plb=100
+raa=ra*f/(pla*ca)
+rbb=rb*f/(plb*cb)
+pa=rbb*(pla+plb)/(raa+rbb)
+pb=pla+plb-pa
+tp=pa-pla
+printf(" generation at the plant a is %dMW and \n generation at the plant b is %dMW \n transfer power from plant a to b is %dMW",pa,pb,tp) \ No newline at end of file
diff --git a/416/CH14/EX14.18/ans14_18pp.txt b/416/CH14/EX14.18/ans14_18pp.txt
new file mode 100755
index 000000000..014c2c1db
--- /dev/null
+++ b/416/CH14/EX14.18/ans14_18pp.txt
@@ -0,0 +1,5 @@
+
+ example 14.18
+the current transfer is 1312.2A at an angle -36.87
+voltage drop in the interconnector is 3542.83+j1443.38V
+ so voltage boost needed is 3542.83+j1443.38V \ No newline at end of file
diff --git a/416/CH14/EX14.18/example14_18pp.sce b/416/CH14/EX14.18/example14_18pp.sce
new file mode 100755
index 000000000..5035fd9fe
--- /dev/null
+++ b/416/CH14/EX14.18/example14_18pp.sce
@@ -0,0 +1,10 @@
+clc
+clear
+disp('example 14.18')
+za=1.5;zb=2.5;//impedence between two lines
+v=11 //plant operatio\ng voltage
+l=20 ; pf=0.8 ;//load at 20 MW at 0.8 pf
+i=l*10^3/(v*pf*sqrt(3));ph=-acosd(pf) //current and phase angle of transfrming current
+vd=complex(za,zb)*complex(i*cosd(ph),i*sind(ph)) //voltage drop due to loss
+printf("the current transfer is %.1fA at an angle %.2f",i,ph)
+printf("\nvoltage drop in the interconnector is %.2f+j%.2fV \n so voltage boost needed is %.2f+j%.2fV ",real(vd),imag(vd),real(vd),imag(vd))
diff --git a/416/CH14/EX14.19/ans14_19pp.txt b/416/CH14/EX14.19/ans14_19pp.txt
new file mode 100755
index 000000000..cda5bdeac
--- /dev/null
+++ b/416/CH14/EX14.19/ans14_19pp.txt
@@ -0,0 +1,9 @@
+
+ example 14.19
+load angle is 1.00
+real power is 0.933p.u
+reactive power 0.361p.u leading
+ (b)
+load angle is 1.00
+real power is 0.981p.u
+reactive power 0.192p.u lagging \ No newline at end of file
diff --git a/416/CH14/EX14.19/example14_19pp.sce b/416/CH14/EX14.19/example14_19pp.sce
new file mode 100755
index 000000000..3da9821a8
--- /dev/null
+++ b/416/CH14/EX14.19/example14_19pp.sce
@@ -0,0 +1,32 @@
+clc
+clear
+disp('example 14.19')
+zaa=3;zbb=9 //impedence given between line
+ pas=1 //power at two units are equal to 1p.u
+par=1
+pbs=1.05 //power at sending end is 1.05 and power at receiving end is 1p.u
+pbr=1
+i=1 //assume current is 1p.u
+los=i*complex(zaa/100,zbb/100)
+csd=((abs(los)^2)-pas^2-par^2)/(2*pas*par) //load angle between two stations
+csa=(pas^2+abs(los)^2-par^2)/(2*pas*abs(los)) //angle between source and loss
+ta=180-atand(zbb/zaa)-acosd(csa) //transfering power factor angle
+printf("load angle is %.2f\n",cosd(csd))
+if sind(ta)<0 then
+ printf("real power is %.3fp.u \nreactive power %.3fp.u lagging",cosd(ta),abs(sind(ta)))
+ else
+ printf("real power is %.3fp.u \nreactive power %.3fp.u leading",cosd(ta),sind(ta))
+
+end
+csd2=(abs(los)^2-pbs^2-pbr^2)/(2*pbs*pbr) //load angle between two stations
+csa2=(pbr^2-pbs^2+abs(los)^2)/(2*pbr*abs(los)) //angle between source and loss
+ f=180-atand(zbb/zaa)-acosd(csa2) //transfering power factor angle
+disp('(b)')
+
+printf("load angle is %.2f\n",cosd(csd2))
+if sind(f)<0 then
+ printf("real power is %.3fp.u \nreactive power %.3fp.u lagging",cosd(f),abs(sind(f)))
+ else
+ printf("real power is %.3fp.u \nreactive power %.3fp.u leading",cosd(f),sind(f))
+
+end
diff --git a/416/CH14/EX14.2/ans14_2.txt b/416/CH14/EX14.2/ans14_2.txt
new file mode 100755
index 000000000..37eb9be08
--- /dev/null
+++ b/416/CH14/EX14.2/ans14_2.txt
@@ -0,0 +1,4 @@
+
+ example 14.3
+speed regulation of alternator is 0.02Hz/MW
+ change in power output 5MW \ No newline at end of file
diff --git a/416/CH14/EX14.2/example14_2.sce b/416/CH14/EX14.2/example14_2.sce
new file mode 100755
index 000000000..3a9c5920d
--- /dev/null
+++ b/416/CH14/EX14.2/example14_2.sce
@@ -0,0 +1,13 @@
+clc
+clear
+disp('example14.2')
+p=100 //power of alternator
+f=50 //frequency
+h=5 //h constant of machine kW-sec kVA
+inl=50 //load suddenly increase by
+de=0.5 //time delay
+ke=h*p*10^3 //kinetic energy
+lke=inl*10^3*de //loss in kinetic energy
+nf=((1-(lke/ke))^(de))*f //now frequency
+fd=(1-nf/f)*100 //frequency deviation
+printf("kinetic energy stored at rated speed %.1e kW-sec \nloss in kinetic energy due to increase in load %.1e kW-sec \n new frequency %.3fHz \nfrequency deviation %.3f",ke,lke,nf,fd) \ No newline at end of file
diff --git a/416/CH14/EX14.3/ans14_3pp.txt b/416/CH14/EX14.3/ans14_3pp.txt
new file mode 100755
index 000000000..a4ece835a
--- /dev/null
+++ b/416/CH14/EX14.3/ans14_3pp.txt
@@ -0,0 +1,4 @@
+
+ example 14_3
+ R1=0.005ohm
+ R2=0.0125ohm \ No newline at end of file
diff --git a/416/CH14/EX14.3/example14_3pp.sce b/416/CH14/EX14.3/example14_3pp.sce
new file mode 100755
index 000000000..45a44467c
--- /dev/null
+++ b/416/CH14/EX14.3/example14_3pp.sce
@@ -0,0 +1,15 @@
+clc
+clear
+disp('example 14_3')
+ar1=500 //alternator rating1
+pl=0.5 //each alternator is operating at half load
+ar2=200 //alternator rating2
+f=50 //frequency
+il=140 //load increase by 140 MW
+fd=49.5 //frequency drops
+fdd=-f+fd //frequency deviation
+dp1=(ar1*pl)-il //change in load alternator 1
+dp2=-(ar2*pl)+il //change in load of alternator 2
+r1=-fdd/dp1
+r2=-fdd/dp2
+printf(" R1=%.3fohm \n R2=%.4fohm",r1,r2) \ No newline at end of file
diff --git a/416/CH14/EX14.4/ans14_4.txt b/416/CH14/EX14.4/ans14_4.txt
new file mode 100755
index 000000000..be9f0d3fe
--- /dev/null
+++ b/416/CH14/EX14.4/ans14_4.txt
@@ -0,0 +1,4 @@
+
+ example14.4
+static frequency drop -0.019608Hz
+frequency drop -1Hz \ No newline at end of file
diff --git a/416/CH14/EX14.4/example14_4.sce b/416/CH14/EX14.4/example14_4.sce
new file mode 100755
index 000000000..6973d9745
--- /dev/null
+++ b/416/CH14/EX14.4/example14_4.sce
@@ -0,0 +1,15 @@
+clc
+clear
+disp('example14.4')
+rc=10000 //rated capacity
+r=2 //regulation in all units
+li=0.02 //load increase
+f=50 //frequency
+d=rc/(2*f) //d=partial derevative with respect to frequency
+d=d/rc
+b=d+1/r
+m=li*rc/2
+mpu=m/rc
+df=-mpu/b
+dff=-mpu/d
+printf("static frequency drop %fHz \nfrequency drop %dHz",df,dff)
diff --git a/416/CH14/EX14.5/ans14_5.txt b/416/CH14/EX14.5/ans14_5.txt
new file mode 100755
index 000000000..4858e9c46
--- /dev/null
+++ b/416/CH14/EX14.5/ans14_5.txt
@@ -0,0 +1,5 @@
+
+ example 14.5
+d=0.01p.u.MW/hz,
+kp=100hz/p.u.MW
+ tp=20second \ No newline at end of file
diff --git a/416/CH14/EX14.5/example14_5.sce b/416/CH14/EX14.5/example14_5.sce
new file mode 100755
index 000000000..85118acb1
--- /dev/null
+++ b/416/CH14/EX14.5/example14_5.sce
@@ -0,0 +1,14 @@
+clc
+clear
+disp('example 14.5')
+cac=10000 //control area capacity
+nol=5000 //normal operating
+h=5 //inertial constent
+r=3 //regulation
+cf=1 //1%change in corresponds to 1% change in load
+f=50 //frequency
+d=cac/(2*f)
+dpu=d/(cac)
+kp=1/dpu
+tp=2*h/(f*dpu)
+printf("d=%.2fp.u.MW/hz, \nkp=%dhz/p.u.MW \n tp=%dsecond",dpu,kp,tp) \ No newline at end of file
diff --git a/416/CH14/EX14.6/ans14_6pp.txt b/416/CH14/EX14.6/ans14_6pp.txt
new file mode 100755
index 000000000..ad2c03671
--- /dev/null
+++ b/416/CH14/EX14.6/ans14_6pp.txt
@@ -0,0 +1,4 @@
+
+ example 14.6
+the contribution of frequency drop to meet increase in load 1.961MW
+increase in generation cost Rs98.04 \ No newline at end of file
diff --git a/416/CH14/EX14.6/example14_6pp.sce b/416/CH14/EX14.6/example14_6pp.sce
new file mode 100755
index 000000000..a37d0b65d
--- /dev/null
+++ b/416/CH14/EX14.6/example14_6pp.sce
@@ -0,0 +1,17 @@
+clc
+clear
+disp('example 14.6')
+rc=10000 //rated capacity
+r=2 //regulation in all units
+li=0.02 //load increase
+f=50 //frequency
+d=rc/(2*f) //d=partial derevative with respect to frequency
+dd=d/rc
+b=dd+1/r
+m=li*rc/2
+mpu=m/rc
+df=-mpu/b
+dff=-mpu/dd
+cf=abs(df*d)
+inc=-(df/r)*10^4
+printf("the contribution of frequency drop to meet increase in load %.3fMW \nincrease in generation cost Rs%.2f",cf,inc) \ No newline at end of file
diff --git a/416/CH14/EX14.7/ans14_7pp.txt b/416/CH14/EX14.7/ans14_7pp.txt
new file mode 100755
index 000000000..f48febd52
--- /dev/null
+++ b/416/CH14/EX14.7/ans14_7pp.txt
@@ -0,0 +1,6 @@
+
+ example 14.7
+ke at no load 450MW-sec
+ loss in k.e due to load 12.5MW-sec
+new frequency 49.3Hz
+frequency deviation 1.4percent \ No newline at end of file
diff --git a/416/CH14/EX14.7/example14_7pp.sce b/416/CH14/EX14.7/example14_7pp.sce
new file mode 100755
index 000000000..8159dc242
--- /dev/null
+++ b/416/CH14/EX14.7/example14_7pp.sce
@@ -0,0 +1,14 @@
+clc
+clear
+disp('example 14.7')
+p=100 //MVA of generated
+f=50 //frequency
+rpm=3000 //no load rpm
+lad=25 //load applied to the machiene
+t=0.5 //time delay
+h=4.5 //inertia constent
+ke=h*p //kinetic energy is product of h*p
+lke=lad*t //loss of ke
+nf=(((ke-lke)/ke)^t)*f //new frequency ((1-lke/ke)^t)*f
+fd=(1-(nf/f))*100 //frequency deviation
+printf("ke at no load %dMW-sec \n loss in k.e due to load %.1fMW-sec \nnew frequency %.1fHz \nfrequency deviation %.1fpercent",ke,lke,nf,fd)
diff --git a/416/CH14/EX14.8/ans14_8pp.txt b/416/CH14/EX14.8/ans14_8pp.txt
new file mode 100755
index 000000000..ffc7c06b7
--- /dev/null
+++ b/416/CH14/EX14.8/ans14_8pp.txt
@@ -0,0 +1,4 @@
+
+ example 14.8
+largest chang in load is 0.105p.u.MW=420MW
+df=(dff)(1-e^2.625000*t) \ No newline at end of file
diff --git a/416/CH14/EX14.8/example14_8pp.sce b/416/CH14/EX14.8/example14_8pp.sce
new file mode 100755
index 000000000..8ff3c9952
--- /dev/null
+++ b/416/CH14/EX14.8/example14_8pp.sce
@@ -0,0 +1,21 @@
+clc
+clear
+disp('example 14.8')
+c=4000//capacity
+f=50 //frequency
+ol=2500 //operating load
+r=2 //speed regulation
+h=5 //inertial constant
+dl=0.02 //change in load
+df=0.01 //change in frequency
+dff=-0.2 //change in steady state frequency
+d=(dl*ol)/(df*f) //
+dpu=d/c //din pu
+b=dpu+(1/r)
+m=-dff*b
+printf("largest chang in load is %.3fp.u.MW=%dMW",m,m*c)
+kp=(1/dpu)
+tp=(kp)*2*h/f
+tt=(r+kp)/(r*tp) //time constant
+printf("\ndf=(dff)(1-e^%f*t)",tt)
+
diff --git a/416/CH14/EX14.9/ans14_9pp.txt b/416/CH14/EX14.9/ans14_9pp.txt
new file mode 100755
index 000000000..b7ee2c749
--- /dev/null
+++ b/416/CH14/EX14.9/ans14_9pp.txt
@@ -0,0 +1,4 @@
+
+ example14.9
+df=-0.02439(1-e^(-4.1))
+ ki=2002.0005p.u.MW/Hz \ No newline at end of file
diff --git a/416/CH14/EX14.9/example14_9pp.sce b/416/CH14/EX14.9/example14_9pp.sce
new file mode 100755
index 000000000..6b3b5bbfd
--- /dev/null
+++ b/416/CH14/EX14.9/example14_9pp.sce
@@ -0,0 +1,18 @@
+clc
+clear
+disp('example14.9')
+c=4000 //capacity of system
+f=50 //frequency //operatingload=rated area capacity
+h=5 //time constent
+r=0.025 //
+dl=0.01 //change in load
+df=0.01 //change in frequency
+rr=r*f //
+d=(dl*c)/(df*f)
+dpu=d/c
+kp=1/dpu
+tp=(kp)*(2*h/f)
+tt=(rr+kp)/(rr*tp)
+sfe=(kp*rr*dpu)/(rr+kp)
+ki=(1+(kp/r))^2/(4*tp*kp)
+printf("df=-%.5f(1-e^(-%.1f)) \n ki=%.4fp.u.MW/Hz",sfe,tt,ki)
diff --git a/416/CH15/EX15.1/exp15_1pp.sce b/416/CH15/EX15.1/exp15_1pp.sce
new file mode 100755
index 000000000..e77d7dc45
--- /dev/null
+++ b/416/CH15/EX15.1/exp15_1pp.sce
@@ -0,0 +1,12 @@
+clc
+clear
+disp('example 15.1')
+a=0.1 //plate area
+b=3 //flux density
+d=0.5 //distence between plates
+v=1000 //average gas velosity
+c=10 //condectivity
+e=b*v*d
+ir=d/(c*a) //internal resistence
+mapo=e^2/(4*ir) //maximum power output
+printf("E=%dV \ninternal resistence %.1fohm \nmaximum power output %dW =%.3fMW",e,ir,mapo,mapo/10^6) \ No newline at end of file
diff --git a/416/CH15/EX15.1/exp15_1pp.txt b/416/CH15/EX15.1/exp15_1pp.txt
new file mode 100755
index 000000000..6f95df2a1
--- /dev/null
+++ b/416/CH15/EX15.1/exp15_1pp.txt
@@ -0,0 +1,5 @@
+
+ example 15.1
+E=1500V
+internal resistence 0.5ohm
+maximum power output 1125000W =1.125MW \ No newline at end of file
diff --git a/416/CH15/EX15.10/exp15_10pp.sce b/416/CH15/EX15.10/exp15_10pp.sce
new file mode 100755
index 000000000..9f0ce2482
--- /dev/null
+++ b/416/CH15/EX15.10/exp15_10pp.sce
@@ -0,0 +1,23 @@
+clc
+clear
+disp('example 15.10')
+tc=2100 //total capacity of plant
+n=60 //number of generaed
+p=35 //power of generated by each generator
+h=10 //head of water
+d=12 //duration of generation
+cee=2.1 //cost of electrical energy per kWh
+efft=0.85 //efficiency of turbine
+effg=0.9 //efficiency of generator
+g=9.81 //gravity
+ro=1025 //density
+acc=0.7 //assuming coal conumotion
+pi=p/(efft*effg) //power input
+q=pi*10^6/(h*g*ro) //quantity of water
+tqr=q*n*d*3600/2 //total quantity of water in reservoir
+avp=tc/2 //average output during 12h
+toe=avp*d //total energy in 12 hours
+eg=toe*365 //energy generated for totel year
+coe=eg*cee*10^3 //cost of electrical energy generated
+sc=eg*10^3*acc //saving cost
+printf("total quantity of water in reservoir %em^3 \nenergy generated per year %eMW \ncost of electrical energy Rs%e \nsaving in cost Rs.%e ",tqr,eg,coe,sc)
diff --git a/416/CH15/EX15.10/exp15_10pp.txt b/416/CH15/EX15.10/exp15_10pp.txt
new file mode 100755
index 000000000..5f97b63f7
--- /dev/null
+++ b/416/CH15/EX15.10/exp15_10pp.txt
@@ -0,0 +1,6 @@
+
+ example 15.10
+total quantity of water in reservoir 5.896832e+008m^3
+energy generated per year 4.599000e+006MW
+cost of electrical energy Rs9.657900e+009
+saving in cost Rs.3.219300e+009 \ No newline at end of file
diff --git a/416/CH15/EX15.2/exp15_2pp.sce b/416/CH15/EX15.2/exp15_2pp.sce
new file mode 100755
index 000000000..6620e54d9
--- /dev/null
+++ b/416/CH15/EX15.2/exp15_2pp.sce
@@ -0,0 +1,13 @@
+clc
+clear
+disp('example 15.2')
+b=4.2 //flux density
+v=600 //gas velocity
+d=0.6 //dimension of plate
+k=0.65 //constent
+e=b*v*d //open circuit voltage
+vg=e/d //voltage gradient
+v=k*e //voltage across load
+vgg=v/d //voltage gradient due to load voltage
+printf("voltage E=%dV \n voltage gradient %dV/m \n voltage across load %.1fV \n voltage gradient due to load voltage %dv",e,vg,v,vgg)
+
diff --git a/416/CH15/EX15.2/exp15_2pp.txt b/416/CH15/EX15.2/exp15_2pp.txt
new file mode 100755
index 000000000..7fe817479
--- /dev/null
+++ b/416/CH15/EX15.2/exp15_2pp.txt
@@ -0,0 +1,6 @@
+
+ example 15.2
+voltage E=1512V
+ voltage gradient 2520V/m
+ voltage across load 982.8V
+ voltage gradient due to load voltage 1638v \ No newline at end of file
diff --git a/416/CH15/EX15.3/exp15_3pp.sce b/416/CH15/EX15.3/exp15_3pp.sce
new file mode 100755
index 000000000..652bfe18e
--- /dev/null
+++ b/416/CH15/EX15.3/exp15_3pp.sce
@@ -0,0 +1,30 @@
+clc
+clear
+disp("example 15.3")
+b=4.2 //flux density
+v=600 //gas velocity
+d=0.6 //dimension of plate
+k=0.65 //constent
+sl=0.6 //length given
+sb=0.35 //breath given
+sh=1.7 //height given
+c=60 //given condectivity
+e=b*v*d //open circuit voltage
+vg=e/d //voltage gradient
+v=k*e //voltage across load
+vgg=v/d //voltage gradient due to load voltage
+rg=d/(c*sb*sh)
+vd=e-v //voltage drop in duct
+i=vd/rg //current due to voltage drop in duct
+j=i/(sb*sh) //current density
+si=e/(rg) //short circuit current
+sj=si/(sb*sh) //short circuit current density
+pd=j*vg //power density
+p=pd*sl*sh*sb //power
+pp=e*i //also power
+pde=v*i //power delevered is V*i
+los=p-pde //loss
+eff=pde/p //efficiency
+maxp=e^2/(4*rg)
+printf("resistence of duct %fohms \n voltage drop in duct %.1fV \n current %.1fA \ncurrent density %fA/m^2 \nshort circuit current %.1fA \nshort current density %fA/m^2 \n power %fMW \npower delivered to load %fW \n loss in duct %fW \nefficiency is %f \nmaximum power delivered to load %dMW",rg,vd,i,j,si,sj,p/10^6,pde/10^6,los/10^6,eff,maxp/10^6)
+
diff --git a/416/CH15/EX15.3/exp15_3pp.txt b/416/CH15/EX15.3/exp15_3pp.txt
new file mode 100755
index 000000000..3f73f8efa
--- /dev/null
+++ b/416/CH15/EX15.3/exp15_3pp.txt
@@ -0,0 +1,13 @@
+
+ example 15.3
+resistence of duct 0.016807ohms
+ voltage drop in duct 529.2V
+ current 31487.4A
+current density 52920.000000A/m^2
+short circuit current 89964.0A
+short current density 151200.000000A/m^2
+ power 47.608949MW
+power delivered to load 30.945817W
+ loss in duct 16.663132W
+efficiency is 0.650000
+maximum power delivered to load 34MW \ No newline at end of file
diff --git a/416/CH15/EX15.4/exp15_4pp.sce b/416/CH15/EX15.4/exp15_4pp.sce
new file mode 100755
index 000000000..26ce238ac
--- /dev/null
+++ b/416/CH15/EX15.4/exp15_4pp.sce
@@ -0,0 +1,18 @@
+clc
+clear
+disp("example 15.4")
+c=50 //conduntance
+a=0.2 //area
+d=0.24 //distence between electrodes
+v=1800 //gas velosity
+b=1 //flux density
+k=0.7
+ov=k*b*v*d
+tp=c*d*a*b^2*v^2*(1-k)
+eff=k
+op=eff*tp
+e=b*v*d
+rg=d/(c*a)
+si=e/rg
+maxp=e^2/(4*rg)
+printf("output voltage %.1fV \ntotal power %.4fMW \n efficiency %.1f \n output power %fMW \n open circuit voltage %dV \n internal resistence %.3fohm \n short circuit current %dA \n maximum power output is %.3fMW",ov,tp/10^6,eff,op/10^6,e,rg,si,maxp/10^6) \ No newline at end of file
diff --git a/416/CH15/EX15.4/exp15_4pp.txt b/416/CH15/EX15.4/exp15_4pp.txt
new file mode 100755
index 000000000..442eb76c8
--- /dev/null
+++ b/416/CH15/EX15.4/exp15_4pp.txt
@@ -0,0 +1,10 @@
+
+ example 15.4
+output voltage 302.4V
+total power 2.3328MW
+ efficiency 0.7
+ output power 1.632960MW
+ open circuit voltage 432V
+ internal resistence 0.024ohm
+ short circuit current 18000A
+ maximum power output is 1.944MW \ No newline at end of file
diff --git a/416/CH15/EX15.5/exp15_5pp.sce b/416/CH15/EX15.5/exp15_5pp.sce
new file mode 100755
index 000000000..dff5748f3
--- /dev/null
+++ b/416/CH15/EX15.5/exp15_5pp.sce
@@ -0,0 +1,14 @@
+clc
+clear
+disp('example 15.5')
+a=100 //area
+spd=0.7 //sun light power density
+m=1000 //weight of water collector
+tp=30 //temperature of water
+th2=60 //angle of incidence
+cp=4186 //specific heat of water
+sp=spd*cosd(th2)*a //solar power collected by collector
+ei=sp*3600*10^3 //energy input in 1 hour
+temp=ei/(cp*10^3)
+tw=tp+temp
+printf("solar power collected by collector %dkW \nenergy input in one hour %e J \n rise in temperature is %.1f`C \n temperature of water %.1f`c",sp,ei,temp,tw)
diff --git a/416/CH15/EX15.5/exp15_5pp.txt b/416/CH15/EX15.5/exp15_5pp.txt
new file mode 100755
index 000000000..7bd80bc1f
--- /dev/null
+++ b/416/CH15/EX15.5/exp15_5pp.txt
@@ -0,0 +1,6 @@
+
+ example 15.5
+solar power collected by collector 34kW
+energy input in one hour 1.260000e+008 J
+ rise in temperature is 30.1`C
+ temperature of water 60.1`c \ No newline at end of file
diff --git a/416/CH15/EX15.6/exp15_6pp.sce b/416/CH15/EX15.6/exp15_6pp.sce
new file mode 100755
index 000000000..91b8d064f
--- /dev/null
+++ b/416/CH15/EX15.6/exp15_6pp.sce
@@ -0,0 +1,26 @@
+clc
+clear
+disp('example 15.6')
+vo=100 //motor rated voltage
+efm=0.4 //efficiency of motor pump
+efi=0.85 //efficiency of inverter
+h=50 //head of water
+v=25 //volume of water per day
+ov=18 //pv pannel output module
+pr=40 //power rating
+ao=2000 //annual output of array
+dw=1000 //density of water
+en=v*dw*h*9.81 //energy needed to pump water every day
+enkw=en/(3.6*10^6) //energy in kilo watt hour
+oe=efm*efi //overall efficiency
+epv=round(enkw/oe) //energy out of pv system
+de=ao/365 //daily energy output
+pw=epv*10^3/de //peak wattage of pv array
+rv=vo*(%pi)/sqrt(2) //rms voltage
+nm=rv/ov //number of modules in series
+nm=ceil(nm)
+rpp=nm*pr //rated peak power output
+np=pw/rpp //number of strings in parallel
+np=round(np)
+printf(" energy needed o pump water every day %fkWh/day \n overall efficiency %.2f \n energy output of pv system %dkWh/day ",enkw,oe,epv)
+printf("\n annual energy out of array %dWh/Wp \ndaily energy output of array %.3fWh/Wp \n peak wattage of pv array %.2fWp \n rms output voltage %.2fV\nnumber of modules in series %d \n rated peak power output of each string %.2fW \n number of strings in parallel %d",epv,de,pw,rv,nm,rpp,np)
diff --git a/416/CH15/EX15.6/exp15_6pp.txt b/416/CH15/EX15.6/exp15_6pp.txt
new file mode 100755
index 000000000..9de2d4d5b
--- /dev/null
+++ b/416/CH15/EX15.6/exp15_6pp.txt
@@ -0,0 +1,12 @@
+
+ example 15.6
+ energy needed o pump water every day 3.406250kWh/day
+ overall efficiency 0.34
+ energy output of pv system 10kWh/day
+ annual energy out of array 10Wh/Wp
+daily energy output of array 5.479Wh/Wp
+ peak wattage of pv array 1825.00Wp
+ rms output voltage 222.14V
+number of modules in series 13
+ rated peak power output of each string 520.00W
+ number of strings in parallel 4 \ No newline at end of file
diff --git a/416/CH15/EX15.7/exp15_7pp.sce b/416/CH15/EX15.7/exp15_7pp.sce
new file mode 100755
index 000000000..eacd4cdfd
--- /dev/null
+++ b/416/CH15/EX15.7/exp15_7pp.sce
@@ -0,0 +1,14 @@
+clc
+clear
+disp("example 15.7")
+ws=20 //wind speed
+rd=10 //rotor diameter
+ros=30 //rotor speed
+ad=1.293 //air density
+mc=0.593 //maximum value of power coefficient
+p1=0.5*ad*(%pi)*(rd^2)*(ws^3)/4 //power
+p=p1/10^3
+pd=p/((%pi)*(rd/2)^2) //power density
+pm=p*(mc) //maximum power
+mt=(pm*10^3)/((%pi)*rd*(ros/60))
+printf("power %.fkW \n power density %.3fkW/m^3 \nmaximum power %fkW \n maximum torque %.1fN-m",p,pd,pm,mt) \ No newline at end of file
diff --git a/416/CH15/EX15.7/exp15_7pp.txt b/416/CH15/EX15.7/exp15_7pp.txt
new file mode 100755
index 000000000..6af0e7c45
--- /dev/null
+++ b/416/CH15/EX15.7/exp15_7pp.txt
@@ -0,0 +1,6 @@
+
+ example 15.7
+power 406kW
+ power density 5.172kW/m^3
+maximum power 240.881303kW
+ maximum torque 15335.0N-m \ No newline at end of file
diff --git a/416/CH15/EX15.8/exp15_8.sce b/416/CH15/EX15.8/exp15_8.sce
new file mode 100755
index 000000000..13415a95c
--- /dev/null
+++ b/416/CH15/EX15.8/exp15_8.sce
@@ -0,0 +1,11 @@
+clc
+clear
+disp("example 15.8")
+cp=0.593
+d=1.293
+s=15
+a=2/3
+dp=2*d*(s^2)*a*(1-a)
+dlp=760*dp/(101.3*10^3) //760 mmhg=101.3*10^3pascal then pressure in mm of hg
+dpa=dlp/760 //pressure in atmosphere
+printf("pressure in pascal %.1fpascal \npressure in height of mercury %.2fmm-hg \npressure in atmosphere %.5fatm",dp,dlp,dpa)
diff --git a/416/CH15/EX15.8/exp15_8.txt b/416/CH15/EX15.8/exp15_8.txt
new file mode 100755
index 000000000..baa76d1eb
--- /dev/null
+++ b/416/CH15/EX15.8/exp15_8.txt
@@ -0,0 +1,5 @@
+
+ example 15.8
+pressure in pascal 129.3pascal
+pressure in height of mercury 0.97mm-hg
+pressure in atmosphere 0.00128atm \ No newline at end of file
diff --git a/416/CH15/EX15.9/exp15_9pp.sce b/416/CH15/EX15.9/exp15_9pp.sce
new file mode 100755
index 000000000..07991efcd
--- /dev/null
+++ b/416/CH15/EX15.9/exp15_9pp.sce
@@ -0,0 +1,24 @@
+clc
+clear
+disp("example 15.9")
+ng=50 //number of generator
+r=30 //rated power
+mah=10 //maximum head
+mih=1 //minimum head
+tg=12 //duration of generation
+efg=0.9 //efficiency of generated
+g=9.81 //gravity
+le=5 //lenght of embankment
+ro=1025 //density
+ti=r/(0.9)^2
+q=ti*10^(6)/(ro*g*mah) //maximum input
+q=floor(q*10^2)/10^2
+qw=q*ng //total quantity of water
+tcr=qw*tg*3600/2 //total capacity of resevoir
+sa=tcr/mah //surface area
+wbe=sa/(le*10^6) //wash behind embankment
+avg=r/2
+te=avg*tg*365*ng //total energy output
+printf("quantity of water for maximum output %fm^3-sec ",q)
+printf("\nsurface area of reservoir %fkm^3 ",sa/10^6)
+printf("\nwash behind embankment %fkm \ntotal energy output %eMWh",wbe,te) \ No newline at end of file
diff --git a/416/CH15/EX15.9/exp15_9pp.txt b/416/CH15/EX15.9/exp15_9pp.txt
new file mode 100755
index 000000000..4a57a8ff0
--- /dev/null
+++ b/416/CH15/EX15.9/exp15_9pp.txt
@@ -0,0 +1,6 @@
+
+ example 15.9
+quantity of water for maximum output 368.330000m^3-sec
+surface area of reservoir 39.779640km^3
+wash behind embankment 7.955928km
+total energy output 3.285000e+006MWh \ No newline at end of file
diff --git a/416/CH17/EX17.1/exp17_1PP.sce b/416/CH17/EX17.1/exp17_1PP.sce
new file mode 100755
index 000000000..c8940faf5
--- /dev/null
+++ b/416/CH17/EX17.1/exp17_1PP.sce
@@ -0,0 +1,15 @@
+clc
+clear
+disp("example 17.1")
+//given
+n=2 //number of generating station
+f=0.03 //F.O.R
+a=1-f
+p=40 //generation station power
+function [y]=comb(m,r)
+y=factorial(m)/(factorial(m-r)*factorial(r))
+endfunction
+for i=0:n
+ pg(i+1)=comb(n,i)*((f)^i)*((a)^(n-i))
+ printf("\nnumber of units out %d ,capacity out %dMW ,capacity available %dMW ,probability %4f ",i,p*i,p*(n-i),pg(i+1))
+end
diff --git a/416/CH17/EX17.1/exp17_1PP.txt b/416/CH17/EX17.1/exp17_1PP.txt
new file mode 100755
index 000000000..2340f124f
--- /dev/null
+++ b/416/CH17/EX17.1/exp17_1PP.txt
@@ -0,0 +1,6 @@
+
+ example 17.1
+
+number of units out 0 ,capacity out 0MW ,capacity available 80MW ,probability 0.940900
+number of units out 1 ,capacity out 40MW ,capacity available 40MW ,probability 0.058200
+number of units out 2 ,capacity out 80MW ,capacity available 0MW ,probability 0.000900 \ No newline at end of file
diff --git a/416/CH17/EX17.2/exp17_2PP.sce b/416/CH17/EX17.2/exp17_2PP.sce
new file mode 100755
index 000000000..d07980936
--- /dev/null
+++ b/416/CH17/EX17.2/exp17_2PP.sce
@@ -0,0 +1,38 @@
+clc
+clear
+disp("example 17 2")
+//given
+n1=2 //number of generating station
+f1=0.03 //F.O.R
+a1=1-f1
+p1=40 //genetaion station power
+n2=1 //number of genreting station
+f2=0.03 //F.O.R for second set
+a2=1-f2
+p2=30 //generating station power in second set
+function [y]=comb(m,r)
+y=factorial(m)/(factorial(m-r)*factorial(r))
+endfunction
+for i=0:n2
+ pg2(i+1)=comb(n2,i)*((f2)^i)*((a2)^(n2-i))
+ co2(i+1)=p2*i;ca2(i+1)=p2*(n2-i)
+ printf("\nnumber of units out %d ,capacity out %dMW ,capacity available %dMW ,probability %4f ",i,co2(i+1),ca2(i+1),pg2(i+1))
+end
+printf("\nfor exp 17 1 ")
+for i=0:n1
+ pg1(i+1)=comb(n1,i)*((f1)^i)*((a1)^(n1-i))
+ co1(i+1)=p1*i;ca1(i+1)=p1*(n1-i)
+ printf("\nnumber of units out %d ,capacity out %dMW ,capacity available %dMW ,probability %4f ",i,co1(i+1),ca1(i+1),pg1(i+1))
+end
+printf("\ncombination of 2 set of stations")
+tp=1
+pocg=0
+for i=0:n1
+ for j=0:n2
+ og=co1(i+1)+co2(j+1) //now total system capacity out
+ cg=ca1(i+1)+ca2(j+1) //now total system capacity available
+ tp=tp-pocg
+ pocg=pg1(i+1)*pg2(j+1) //individual stste probability
+ printf("\ncapacity out %dMW ,capacity available %dMW ,individual state probability %.6f ,cumulative probability %.6f",og,cg,pocg,tp)
+ end
+end \ No newline at end of file
diff --git a/416/CH17/EX17.2/exp17_2PP.txt b/416/CH17/EX17.2/exp17_2PP.txt
new file mode 100755
index 000000000..003c6878b
--- /dev/null
+++ b/416/CH17/EX17.2/exp17_2PP.txt
@@ -0,0 +1,16 @@
+
+ example 17 2
+
+number of units out 0 ,capacity out 0MW ,capacity available 30MW ,probability 0.970000
+number of units out 1 ,capacity out 30MW ,capacity available 0MW ,probability 0.030000
+for exp 17 1
+number of units out 0 ,capacity out 0MW ,capacity available 80MW ,probability 0.940900
+number of units out 1 ,capacity out 40MW ,capacity available 40MW ,probability 0.058200
+number of units out 2 ,capacity out 80MW ,capacity available 0MW ,probability 0.000900
+combination of 2 set of stations
+capacity out 0MW ,capacity available 110MW ,individual state probability 0.912673 ,cumulative probability 1.000000
+capacity out 30MW ,capacity available 80MW ,individual state probability 0.028227 ,cumulative probability 0.087327
+capacity out 40MW ,capacity available 70MW ,individual state probability 0.056454 ,cumulative probability 0.059100
+capacity out 70MW ,capacity available 40MW ,individual state probability 0.001746 ,cumulative probability 0.002646
+capacity out 80MW ,capacity available 30MW ,individual state probability 0.000873 ,cumulative probability 0.000900
+capacity out 110MW ,capacity available 0MW ,individual state probability 0.000027 ,cumulative probability 0.000027 \ No newline at end of file
diff --git a/416/CH17/EX17.3/exp17_3.jpg b/416/CH17/EX17.3/exp17_3.jpg
new file mode 100755
index 000000000..32e9b017a
--- /dev/null
+++ b/416/CH17/EX17.3/exp17_3.jpg
Binary files differ
diff --git a/416/CH17/EX17.3/exp17_3PP.sce b/416/CH17/EX17.3/exp17_3PP.sce
new file mode 100755
index 000000000..ab917f249
--- /dev/null
+++ b/416/CH17/EX17.3/exp17_3PP.sce
@@ -0,0 +1,31 @@
+clc
+clear
+disp("example 17 3")
+//given
+n=4 //number of generating station
+f=0.05 //F.O.R
+a=1-f
+p=50 //generation station power
+mp=150 //maximum alowable power
+lf=50 //load factor in persentage
+function [y]=comb(m,r)
+y=factorial(m)/(factorial(m-r)*factorial(r))
+endfunction
+for i=0:n
+ pg(i+1)=comb(n,i)*((f)^i)*((a)^(n-i))
+ co(i+1)=p*i;ca(i+1)=p*(n-i)
+ printf("\nnumber of units out %d ,capacity out %dMW ,capacity available %dMW ,probability %4f ",i,co(i+1),ca(i+1),pg(i+1))
+end
+ld=mp:-lf:0
+[m n]=size(ld)
+plot(ld)
+tg(n-1)=round(10000/(n-1))/100
+tg(n)=tg(n-1)*2
+tg(n+1)=100
+tg(2)=0;tg(1)=0 //maximum load limit
+for i=0:n
+ el(i+1)=pg(i+1)*tg(i+1)
+ printf("\nnumber of units out %d ,capacity out %dMW ,capacity available %dMW ,probability %4f ,tg in persentage %.2f ,expected load %.6fMW",i,co(i+1),ca(i+1),pg(i+1),tg(i+1),el(i+1))
+end
+lt=sum(el)
+printf("\n\nexpected loss of load is %.6fMW percent of time. assuming 365 days in a year, then expected loss of load is %.3fMW days per year",lt,lt*365/100) \ No newline at end of file
diff --git a/416/CH17/EX17.3/exp17_3PP.txt b/416/CH17/EX17.3/exp17_3PP.txt
new file mode 100755
index 000000000..9708c03c9
--- /dev/null
+++ b/416/CH17/EX17.3/exp17_3PP.txt
@@ -0,0 +1,15 @@
+
+ example 17 3
+
+number of units out 0 ,capacity out 0MW ,capacity available 200MW ,probability 0.814506
+number of units out 1 ,capacity out 50MW ,capacity available 150MW ,probability 0.171475
+number of units out 2 ,capacity out 100MW ,capacity available 100MW ,probability 0.013538
+number of units out 3 ,capacity out 150MW ,capacity available 50MW ,probability 0.000475
+number of units out 4 ,capacity out 200MW ,capacity available 0MW ,probability 0.000006
+number of units out 0 ,capacity out 0MW ,capacity available 200MW ,probability 0.814506 ,tg in persentage 0.00 ,expected load 0.000000MW
+number of units out 1 ,capacity out 50MW ,capacity available 150MW ,probability 0.171475 ,tg in persentage 0.00 ,expected load 0.000000MW
+number of units out 2 ,capacity out 100MW ,capacity available 100MW ,probability 0.013538 ,tg in persentage 33.33 ,expected load 0.451205MW
+number of units out 3 ,capacity out 150MW ,capacity available 50MW ,probability 0.000475 ,tg in persentage 66.66 ,expected load 0.031664MW
+number of units out 4 ,capacity out 200MW ,capacity available 0MW ,probability 0.000006 ,tg in persentage 100.00 ,expected load 0.000625MW
+
+expected loss of load is 0.483493MW percent of time. assuming 365 days in a year, then expected loss of load is 1.765MW days per year \ No newline at end of file
diff --git a/416/CH17/EX17.4/exp17_4.jpg b/416/CH17/EX17.4/exp17_4.jpg
new file mode 100755
index 000000000..98afe1019
--- /dev/null
+++ b/416/CH17/EX17.4/exp17_4.jpg
Binary files differ
diff --git a/416/CH17/EX17.4/exp17_4PP.sce b/416/CH17/EX17.4/exp17_4PP.sce
new file mode 100755
index 000000000..3f5416516
--- /dev/null
+++ b/416/CH17/EX17.4/exp17_4PP.sce
@@ -0,0 +1,34 @@
+clc
+clear
+disp("example 17 4")
+//given
+n=4 //number of generating station
+f=0.02 //F.O.R
+a=1-f
+p=50 //generation station power
+mp=150 //maximum alowable power
+minp=30 //minimum power
+lf=60 //load factor in persentage
+function [y]=comb(m,r)
+y=factorial(m)/(factorial(m-r)*factorial(r))
+endfunction
+for i=0:n
+ pg(i+1)=comb(n,i)*((f)^i)*((a)^(n-i))
+ co(i+1)=p*i;ca(i+1)=p*(n-i)
+ printf("\nnumber of units out %d ,capacity out %dMW ,capacity available %dMW ,probability %.7f ",i,co(i+1),ca(i+1),pg(i+1))
+end
+ld=mp:-lf:minp
+[m n1]=size(ld)
+[mm m]=max(co)
+plot(ld)
+tg(1)=0
+for i=2:n+1
+ tg(i)=(mp-ca(i))*100/(2*lf) //percentage time
+end
+disp("")
+for i=1:n+1
+ el(i)=pg(i)*tg(i)
+ printf("\nnumber of units out %d ,capacity out %dMW ,capacity available %dMW ,probability %4f ,tg in persentage %.2f ,expected load %.6fMW",i-1,co(i),ca(i),pg(i),tg(i),el(i))
+end
+lt=sum(el)
+printf("\n\nexpected loss of load is %.6fMW percent of time. assuming 365 days in a year, then expected loss of load is %.3fMW days per year ,some times the loss of load is also expressed as reciprocal of this figure and then the units are years per day this result is %.4fMW years per day.",lt,lt*365/100,100/(lt*365)) \ No newline at end of file
diff --git a/416/CH17/EX17.4/exp17_4PP.txt b/416/CH17/EX17.4/exp17_4PP.txt
new file mode 100755
index 000000000..6121c721b
--- /dev/null
+++ b/416/CH17/EX17.4/exp17_4PP.txt
@@ -0,0 +1,17 @@
+
+ example 17 4
+
+number of units out 0 ,capacity out 0MW ,capacity available 200MW ,probability 0.9223682
+number of units out 1 ,capacity out 50MW ,capacity available 150MW ,probability 0.0752954
+number of units out 2 ,capacity out 100MW ,capacity available 100MW ,probability 0.0023050
+number of units out 3 ,capacity out 150MW ,capacity available 50MW ,probability 0.0000314
+number of units out 4 ,capacity out 200MW ,capacity available 0MW ,probability 0.0000002
+
+
+number of units out 0 ,capacity out 0MW ,capacity available 200MW ,probability 0.922368 ,tg in persentage 0.00 ,expected load 0.000000MW
+number of units out 1 ,capacity out 50MW ,capacity available 150MW ,probability 0.075295 ,tg in persentage 0.00 ,expected load 0.000000MW
+number of units out 2 ,capacity out 100MW ,capacity available 100MW ,probability 0.002305 ,tg in persentage 41.67 ,expected load 0.096040MW
+number of units out 3 ,capacity out 150MW ,capacity available 50MW ,probability 0.000031 ,tg in persentage 83.33 ,expected load 0.002613MW
+number of units out 4 ,capacity out 200MW ,capacity available 0MW ,probability 0.000000 ,tg in persentage 125.00 ,expected load 0.000020MW
+
+expected loss of load is 0.098673MW percent of time. assuming 365 days in a year, then expected loss of load is 0.360MW days per year ,some times the loss of load is also expressed as reciprocal of this figure and then the units are years per day this result is 2.7766MW years per day. \ No newline at end of file
diff --git a/416/CH2/EX2.1/exp2_1cpp.sce b/416/CH2/EX2.1/exp2_1cpp.sce
new file mode 100755
index 000000000..b9ae7ebc3
--- /dev/null
+++ b/416/CH2/EX2.1/exp2_1cpp.sce
@@ -0,0 +1,33 @@
+clc
+disp("example =2.1")
+printf("\n")
+disp("solution for (a)")
+nb=8;nf=2;nl=2 //given number of equipments is 8 bulbs 2 fans 2plugs
+lb=100;lf=60;ll=100 //corresponding wattages
+cl=nb*lb+nf*lf+nl*ll; //total connected load
+printf("connected load = 8X100W+2X60W+2X100W=%dW\n",cl);
+disp("solution for (b)")
+disp("total wattage at different times is")
+t1=5;t2=2;t3=2;t4=9;t5=6;
+fr=[0 1 0] //12 to 5am period of duration 5h
+s=[0 2 1] //5am to 7am period of duration 2h
+t=[0 0 0] //7am to 9am period of duration 2h
+fo=[0 2 0] //9am to 6pm period of duration 9h
+fi=[4 2 0] //6pm to 12pm period of duration 6h
+w=[fr;s;t;fo;fi]
+wt=[100*w(:,1),60*w(:,2),100*w(:,3)]
+wtt=[sum(wt(1,:));sum(wt(2,:));sum(wt(3,:));sum(wt(4,:));sum(wt(5,:))]
+printf("\t%dW\n\t%dW\n\t%dW\n\t%dW\n\t%dW",wtt(1),wtt(2),wtt(3),wtt(4),wtt(5))
+printf("\nthe maximum demand is %dW\n",max(wtt))
+m=max(wtt)
+disp("solution for (c)")
+printf("\ndemand factor =%3f\n",m/cl)
+disp("solution for (d)")//energy consumed is power multiply by corresponding time
+energy=[wtt(1,1)*t1;wtt(2,1)*t2;wtt(3,1)*t3;wtt(4,1)*t4;wtt(5,1)*t5]
+printf("\t%dWh\n\t%dWh\n\t%dWh\n\t%dWh\n\t%dWh",energy(1),energy(2),energy(3),energy(4),energy(5))
+e=sum(energy)
+printf("\ntotal energy consumed during 24 hours =%dWh+%dWh+%dWh+%dWh+%dWh=%dWh\n",energy(1),energy(2),energy(3),energy(4),energy(5),e)
+disp("solution for (e)");
+ec=cl*24;
+printf("\nif all devices are used throughout the day the energy consumed in Wh is %dWh \n\t\t%.2fkWh",ec,ec/1000)
+//for 24 hours of max. load \ No newline at end of file
diff --git a/416/CH2/EX2.1/exp2_1cpp.txt b/416/CH2/EX2.1/exp2_1cpp.txt
new file mode 100755
index 000000000..f0eb15ff3
--- /dev/null
+++ b/416/CH2/EX2.1/exp2_1cpp.txt
@@ -0,0 +1,33 @@
+
+ example =2.1
+
+
+ solution for (a)
+connected load = 8X100W+2X60W+2X100W=1120W
+
+ solution for (b)
+
+ total wattage at different times is
+ 60W
+ 220W
+ 0W
+ 120W
+ 520W
+the maximum demand is 520W
+
+ solution for (c)
+
+demand factor =0.464286
+
+ solution for (d)
+ 300Wh
+ 440Wh
+ 0Wh
+ 1080Wh
+ 3120Wh
+total energy consumed during 24 hours =300Wh+440Wh+0Wh+1080Wh+3120Wh=4940Wh
+
+ solution for (e)
+
+if all devices are used throughout the day the energy consumed in Wh is 26880Wh
+ 26.88kWh \ No newline at end of file
diff --git a/416/CH2/EX2.10/exp2_10cpp.sce b/416/CH2/EX2.10/exp2_10cpp.sce
new file mode 100755
index 000000000..cd62416cb
--- /dev/null
+++ b/416/CH2/EX2.10/exp2_10cpp.sce
@@ -0,0 +1,7 @@
+clc
+disp("example 2.10")
+egd1=438*10^4;plp=0.2;pcf=0.15;//annual load duration ;annual load factor;plant capacity factor
+pml=egd1/(plp*8760)
+pc=(pml*plp)/pcf
+printf("annual load factor =energy generated during 1 year/(max. load)x8760=%.1f \n maximum load =%dkW",plp,pml)
+printf("\ncapacity factor =(max.load/plant capacity)x(load factor)\n plant capacity =max.load/0.75 =%fMW \n reserve capacity =3.333-2.5=%fMW",pc,pc-pml)
diff --git a/416/CH2/EX2.10/exp2_10cpp.txt b/416/CH2/EX2.10/exp2_10cpp.txt
new file mode 100755
index 000000000..dbb2b7b11
--- /dev/null
+++ b/416/CH2/EX2.10/exp2_10cpp.txt
@@ -0,0 +1,7 @@
+
+ example 2.10
+annual load factor =energy generated during 1 year/(max. load)x8760=0.2
+ maximum load =2500kW
+capacity factor =(max.load/plant capacity)x(load factor)
+ plant capacity =max.load/0.75 =3333.333333MW
+ reserve capacity =3.333-2.5=833.333333MW \ No newline at end of file
diff --git a/416/CH2/EX2.11/exp2_11c.sce b/416/CH2/EX2.11/exp2_11c.sce
new file mode 100755
index 000000000..719962812
--- /dev/null
+++ b/416/CH2/EX2.11/exp2_11c.sce
@@ -0,0 +1,12 @@
+clc
+disp("example 2.11")
+p1=10;p2=6;p3=8;p4=7 //peak demands of 4 areas
+df=1.5;lf=0.65;imdp=0.6;//diversity factor ;annual load factor ;ratio of maximum demand
+p=p1+p2+p3+p4
+md=p/df
+ae=md*lf*8760
+imd=imdp*md
+ic=md+imd
+printf(" sum of maximum=%dMW",p)
+printf("\n maximum demand = sum of max.demands/diversity factor =%d/%f = %fMW",p,df,md)
+printf("\n annual energy =%fMWh \n increase in maximum demand =%fMW \n installed capacity =%fMW",ae,imd,ic)
diff --git a/416/CH2/EX2.11/exp2_11c.txt b/416/CH2/EX2.11/exp2_11c.txt
new file mode 100755
index 000000000..67d731a9a
--- /dev/null
+++ b/416/CH2/EX2.11/exp2_11c.txt
@@ -0,0 +1,7 @@
+
+ example 2.11
+ sum of maximum=31MW
+ maximum demand = sum of max.demands/diversity factor =31/1.500000 = 20.666667MW
+ annual energy =117676.000000MWh
+ increase in maximum demand =12.400000MW
+ installed capacity =33.066667MW \ No newline at end of file
diff --git a/416/CH2/EX2.12/exp2_12.png b/416/CH2/EX2.12/exp2_12.png
new file mode 100755
index 000000000..3be5ad7e8
--- /dev/null
+++ b/416/CH2/EX2.12/exp2_12.png
Binary files differ
diff --git a/416/CH2/EX2.12/exp2_12c.sce b/416/CH2/EX2.12/exp2_12c.sce
new file mode 100755
index 000000000..4a59dbca5
--- /dev/null
+++ b/416/CH2/EX2.12/exp2_12c.sce
@@ -0,0 +1,43 @@
+clc
+disp("example 2.12")
+disp("from the above data,the durations of different loads during one week are")
+aw=[0 5 8 12 13 17 21 24] //given week timings and corresponding loads
+lw=[100 150 250 100 250 350 150]
+aen=[0 5 17 21 24] //given weakends timing and corresponding
+len=[100 150 200 150]
+saw=size(aw);saen=size(aen)
+sae=saw(1,2)-1;saen=saen(1,2)-1
+for x=1:sae //getting duration of load
+ tdw(1,x)=aw(1,x+1)-aw(1,x)
+end
+for x=1:saen
+ tden(1,x)=aen(1,x+1)-aen(1,x)
+end
+taw=5*tdw //duration of entair week
+taen=2*tden
+alw=[taw taen;lw len]
+lwen=[lw len] //arranging load in accending order
+[m n]=gsort(lwen)
+kn=size(lwen)
+kld=kn(1,2)
+
+for x=2:kld
+
+ ldcq(:,x)=alw(:,n(x))
+ if x>1 then
+ ldcq(1,x)=ldcq(1,x)+ldcq(1,x-1)
+ end
+end
+
+plot2d2(ldcq(1,:),ldcq(2,:))
+printf(" load duration \n 350MW 4x5 =20hours \n 250MW 20+8x5=60hours \n 200MW 60+4x2 =68hours \n 150MW 68+6x5+15x2 =128hours \n 100MW 128+6x5+5x2 =168hours")
+disp("the load duration curve is plotted in fig")
+disp("the total area under the load duration curve is 31600MWh which represents the energy conumption in one week.")
+eclw=ldcq(2,1)*ldcq(1,1)
+for x=2:1:kld
+ eclw=eclw+(ldcq(2,x)*(ldcq(1,x)-ldcq(1,x-1)))
+end
+lf=eclw/(max(lwen)*24*7)
+printf("total energy consumed is %dWh",eclw)
+printf("\ntotal maximum energy could consume %dWh",eclw/lf)
+printf("\nload factor =%f",lf)
diff --git a/416/CH2/EX2.12/exp2_12c.txt b/416/CH2/EX2.12/exp2_12c.txt
new file mode 100755
index 000000000..ccd67ffc8
--- /dev/null
+++ b/416/CH2/EX2.12/exp2_12c.txt
@@ -0,0 +1,19 @@
+
+ example 2.12
+
+ from the above data,the durations of different loads d
+ uring one week are
+ load duration
+ 350MW 4x5 =20hours
+ 250MW 20+8x5=60hours
+ 200MW 60+4x2 =68hours
+ 150MW 68+6x5+15x2 =128hours
+ 100MW 128+6x5+5x2 =168hours
+ the load duration curve is plotted in fig
+
+ the total area under the load duration curve is 31600M
+ Wh which represents the energy conumption in one
+ week.
+total energy consumed is 24600
+total maximum energy could consume 58800
+load factor =0.418367 \ No newline at end of file
diff --git a/416/CH2/EX2.13/exp2_13.sce b/416/CH2/EX2.13/exp2_13.sce
new file mode 100755
index 000000000..9caa7d3b8
--- /dev/null
+++ b/416/CH2/EX2.13/exp2_13.sce
@@ -0,0 +1,6 @@
+clc
+disp("example 2.13")
+dlf=0.825; //daily load factor
+lptmlp=0.87; //average daily peak load to monthly load peak
+mlptalp=0.78; //average monthly peak load to annual load peak
+printf("annual load factor =%fx%fx%f=%f.",dlf,lptmlp,mlptalp,dlf*lptmlp*mlptalp) \ No newline at end of file
diff --git a/416/CH2/EX2.13/exp2_13.txt b/416/CH2/EX2.13/exp2_13.txt
new file mode 100755
index 000000000..8a67e1b35
--- /dev/null
+++ b/416/CH2/EX2.13/exp2_13.txt
@@ -0,0 +1,3 @@
+
+ example 2.13
+annual load factor =0.825000x0.870000x0.780000=0.559845. \ No newline at end of file
diff --git a/416/CH2/EX2.14/exp2_14.sce b/416/CH2/EX2.14/exp2_14.sce
new file mode 100755
index 000000000..148e83249
--- /dev/null
+++ b/416/CH2/EX2.14/exp2_14.sce
@@ -0,0 +1,12 @@
+clc
+disp("example 2.14")
+disp("(a)")
+//given
+transformer1.motorload=300;transformer1.demandfactorm=0.6;tarnsformer1.commercialload=100;transformer1.demandfactorc=0.5;transformer1.diversityfactor=2.3;transformer2.residentalload=500;transformer2.demandfactor=0.4;transformer2.diversitryfactor=2.5;transformer3.residentalload=400;transformer3.demandfactor=0.5;transformer3.diversityfactor=2.0;diversitybtwxmer=1.4
+peakloadoftransformer1=((transformer1.motorload*transformer1.demandfactorm)+(tarnsformer1.commercialload*transformer1.demandfactorc))/transformer1.diversityfactor
+peakloadonxmer=(transformer2.residentalload*transformer2.demandfactor)/transformer2.diversitryfactor
+peakloadonxmer3=(transformer3.residentalload*transformer3.demandfactor)/(transformer3.diversityfactor)
+printf("peak load on transformer 1 =(300x0.6+100x0.5)/2.3 =%dkW \npeak load on transformer 2 =%dkW \n peak load on transformer 3 =%dkW",peakloadoftransformer1,peakloadonxmer,peakloadonxmer3)
+disp("(b)")
+peakloadonfeeder=(peakloadoftransformer1+peakloadonxmer+peakloadonxmer3)/diversitybtwxmer
+printf("peak load on feeder =(100+80+100)/1.4 =%dkW",peakloadonfeeder)
diff --git a/416/CH2/EX2.14/exp2_14.txt b/416/CH2/EX2.14/exp2_14.txt
new file mode 100755
index 000000000..b596d14ff
--- /dev/null
+++ b/416/CH2/EX2.14/exp2_14.txt
@@ -0,0 +1,9 @@
+
+ example 2.14
+
+ (a)
+peak load on transformer 1 =(300x0.6+100x0.5)/2.3 =100kW
+peak load on transformer 2 =80kW
+ peak load on transformer 3 =100kW
+ (b)
+peak load on feeder =(100+80+100)/1.4 =200kW \ No newline at end of file
diff --git a/416/CH2/EX2.2/exp2_2.png b/416/CH2/EX2.2/exp2_2.png
new file mode 100755
index 000000000..56a8f1607
--- /dev/null
+++ b/416/CH2/EX2.2/exp2_2.png
Binary files differ
diff --git a/416/CH2/EX2.2/exp2_2pp.sce b/416/CH2/EX2.2/exp2_2pp.sce
new file mode 100755
index 000000000..16483d5a6
--- /dev/null
+++ b/416/CH2/EX2.2/exp2_2pp.sce
@@ -0,0 +1,38 @@
+clc
+disp("example 2.2")
+disp("(a)");
+mca=1.1;cla=2.5;mcb=1;clb=3; //mca=maximum demand of consumera;cla=connected load of a;mcb=maximum load of consumer b;clb=connected load of consumer b
+printf("maximum demand of consumer A =%1fkW \n \ndemand factor of consumer A =%2f \n \nmaximum demand of consumer B =%dkW\n \ndemand factor of consumer B = %2f",mca,mca/cla,mcb,mcb/clb)
+disp("(b)")
+printf("The variation in demand versus time curves are plotted and shown in Fig This is known as chonological load curve.")
+A=[100*ones(1,5),1100*ones(1,1),200*ones(1,2),0*ones(1,9),500*ones(1,7)]
+B=[0*ones(1,7),300*ones(1,1),1000*ones(1,2),200*ones(1,8),600*ones(1,5),0*ones(1,1)]; //time line of different periods by a and b consumers
+t=1:1:24 ;//for 24 hours ploting
+ma=max(A);mb=max(B);
+subplot(121); //matrix plotting
+plot2d2(t,A,1);
+plot2d2(t,B,2);
+xtitle("load curves of A and B/ fig 1","time","load watts")
+C=A+B;
+subplot(122);
+plot2d2(t,C,1);
+xtitle("chronological load of group / fig 2","time","load watts")
+mg=max(C); //maximum demand of group
+disp("(c)")
+printf("maximum demand of the group is %dW",mg);
+gd=(ma+mb)/mg;
+printf("group diversity factor = %3f",gd) ; //group diversity factor is sum of individual maximum consumaer load to the group max load
+disp("(d)")
+sa=sum(A)
+printf("energy consumed by A during 24 hours is =%dWh",sa)
+printf("\nit is seen that energy consumed by A is equal to the area under the chronological load curve of A \n energy consumed by B during 24 hours is")
+sb=sum(B);
+printf("300x1+100x2+200x8+600x5=%dWh",sb);
+disp("(e)");
+printf("maximum energy which A could consume in 24hours = %.2fkWh \nmaximum energy which B consume in 24 hours is =%.2fkWh",mca*24,mcb*24 );
+disp("(f)");
+printf("actual energy/maximum energy");
+mca=mca*10^3;mcb=mcb*10^3
+aemea=sa/(mca*24)
+aemeb=sb/(mcb*24)
+printf("\nfor A = %d/%d =%f \nfor b =%d/%d =%f",sa,mca*24,sa/(mca*24),sb,mcb*24,aemeb); \ No newline at end of file
diff --git a/416/CH2/EX2.2/exp2_2pp.txt b/416/CH2/EX2.2/exp2_2pp.txt
new file mode 100755
index 000000000..4488cbb9b
--- /dev/null
+++ b/416/CH2/EX2.2/exp2_2pp.txt
@@ -0,0 +1,26 @@
+
+ example 2.2
+
+ (a)
+maximum demand of consumer A =1.100000kW
+
+demand factor of consumer A =0.440000
+
+maximum demand of consumer B =1kW
+
+demand factor of consumer B = 0.333333
+ (b)
+The variation in demand versus time curves are plotted and shown in Fig This is known as chonological load curve.
+ (c)
+maximum demand of the group is 1100Wgroup diversity factor = 1.909091
+ (d)
+energy consumed by A during 24 hours is =5500Wh
+it is seen that energy consumed by A is equal to the area under the chronological load curve of A
+ energy consumed by B during 24 hours is300x1+100x2+200x8+600x5=6900Wh
+ (e)
+maximum energy which A could consume in 24hours = 26.40kWh
+maximum energy which B consume in 24 hours is =24.00kWh
+ (f)
+actual energy/maximum energy
+for A = 5500/26400 =0.208333
+for b =6900/24000 =0.287500 \ No newline at end of file
diff --git a/416/CH2/EX2.3/exp2_3pp.sce b/416/CH2/EX2.3/exp2_3pp.sce
new file mode 100755
index 000000000..990d2f3eb
--- /dev/null
+++ b/416/CH2/EX2.3/exp2_3pp.sce
@@ -0,0 +1,23 @@
+clc
+disp("example 2.3")
+printf("\n")
+cola=5;na=600;ns=20;
+cls=2;clfm=10;clsm=5;cll=20;clci=80;
+dffl=0.7;dfsm=0.8;dfl=0.65;dfci=0.5;
+nsl=200;clsl=0.04;dfa=0.5;gdfa=3.0;
+pdfa=1.25;gdfc=2;pdfc=1.6;dfs=0.8; //given col||cl=connected load,n=number,df=demand factor,gdf=group diversity factor,pdf=peak diversity factor,a=appartement,c=commertials,s=shop,sl=streetlight,fm=flourmill,sm=saw mill,l=laundry,ci=cinema complex.
+mdea=cola*dfa
+printf("maximum demand of each appartment =%.2fkWh \n",mdea)
+mda=(na*mdea)/gdfa
+printf("maximum demand of 600 apatments =%.2fkW \n",mda);
+datsp=mda/pdfa
+printf("demand of 600 apartments at time of the system peak =%dkW \n",datsp);
+mdtcc=((cls*ns*dfs)+(clfm*dffl)+(clsm*dfsm)+(cll*dfl)+(clci*dfci))/gdfc
+printf("maximum demand of total commertial complex=%dkW \n",mdtcc)
+dcsp=mdtcc/pdfc
+printf("demand of the commertial load at the time of the peak = %dkW\n",dcsp);
+dsltsp=nsl*clsl
+printf("demand of the street lighting at the time of the system peak =%dkW",dsltsp);
+ispd=datsp+dcsp+dsltsp
+printf("\nincrease in system peak deamand =%dkW ",ispd)
+
diff --git a/416/CH2/EX2.3/exp2_3pp.txt b/416/CH2/EX2.3/exp2_3pp.txt
new file mode 100755
index 000000000..b8b0f486c
--- /dev/null
+++ b/416/CH2/EX2.3/exp2_3pp.txt
@@ -0,0 +1,10 @@
+
+ example 2.3
+
+maximum demand of each appartment =2.50kWh
+maximum demand of 600 apatments =500.00kW
+demand of 600 apartments at time of the system peak =400kW
+maximum demand of total commertial complex=48kW
+demand of the commertial load at the time of the peak = 30kW
+demand of the street lighting at the time of the system peak =8kW
+increase in system peak deamand =438kW \ No newline at end of file
diff --git a/416/CH2/EX2.4/exp2_4.png b/416/CH2/EX2.4/exp2_4.png
new file mode 100755
index 000000000..1fd7fde1b
--- /dev/null
+++ b/416/CH2/EX2.4/exp2_4.png
Binary files differ
diff --git a/416/CH2/EX2.4/exp2_4pp.sce b/416/CH2/EX2.4/exp2_4pp.sce
new file mode 100755
index 000000000..e3b921314
--- /dev/null
+++ b/416/CH2/EX2.4/exp2_4pp.sce
@@ -0,0 +1,22 @@
+clc
+disp("example 2.4")
+printf("\n")
+printf("the chronological load curve is plotted in fig 1 the durition of loads is as under :")
+lc=[20*ones(1,5),40*ones(1,4),80*ones(1,9),100*ones(1,4),20*ones(1,2)]
+ldc=gsort(lc);
+[mm,nn]=size(ldc)
+printf("\n")
+for i=1:nn
+printf("\t%dW",ldc(i));//arranging accending order
+end
+e=sum(ldc)
+printf("\nthe load duration curve is ploted in 2 the energy produced by plant in 24 hours \n =100x4+80x(13-4)+40(17-13)+20(24-17)=%dMWh \n",e);
+lff=e/(24*max(ldc));
+printf("load factor =1420/2400=%f=%f in persent",lff,lff*100)
+t=1:1:24
+subplot(121);
+plot2d2(t,lc);
+xtitle("chronological curve","time","load MW");
+subplot(122);
+plot2d2(t,ldc);
+xtitle("load duration curve","time","load MW");
diff --git a/416/CH2/EX2.4/exp2_4pp.txt b/416/CH2/EX2.4/exp2_4pp.txt
new file mode 100755
index 000000000..d2d0e2280
--- /dev/null
+++ b/416/CH2/EX2.4/exp2_4pp.txt
@@ -0,0 +1,8 @@
+
+ example 2.4
+
+the chronological load curve is plotted in fig 1 the durition of loads is as under :
+ 100W 100W 100W 100W 80W 80W 80W 80W 80W 80W 80W 80W 80W 40W 40W 40W 40W 20W 20W 20W 20W 20W 20W 20W
+the load duration curve is ploted in 2 the energy produced by plant in 24 hours
+ =100x4+80x(13-4)+40(17-13)+20(24-17)=1420MWh
+load factor =1420/2400=0.591667=59.166667 in persent \ No newline at end of file
diff --git a/416/CH2/EX2.5/exp2_5.txt b/416/CH2/EX2.5/exp2_5.txt
new file mode 100755
index 000000000..5815b700d
--- /dev/null
+++ b/416/CH2/EX2.5/exp2_5.txt
@@ -0,0 +1,4 @@
+
+ example 2.5
+capacity factor =0.473360
+utilisation factor =169.004563 \ No newline at end of file
diff --git a/416/CH2/EX2.5/exp2_5q.sce b/416/CH2/EX2.5/exp2_5q.sce
new file mode 100755
index 000000000..cf834f488
--- /dev/null
+++ b/416/CH2/EX2.5/exp2_5q.sce
@@ -0,0 +1,6 @@
+clc
+disp("example 2.5")
+lf=0.5917;ml=100;ic=125; //lf=load factor,ic=installed capacity,ml=maximum load,cf=capacity factor,uf=utillization factor
+cf=(ml*lf)/ic;uf=ml/lf
+printf("capacity factor =%f",cf)
+printf("\nutilisation factor =%f",uf)
diff --git a/416/CH2/EX2.6/exp2_6.png b/416/CH2/EX2.6/exp2_6.png
new file mode 100755
index 000000000..a876ed423
--- /dev/null
+++ b/416/CH2/EX2.6/exp2_6.png
Binary files differ
diff --git a/416/CH2/EX2.6/exp2_6pp.sce b/416/CH2/EX2.6/exp2_6pp.sce
new file mode 100755
index 000000000..d5415c978
--- /dev/null
+++ b/416/CH2/EX2.6/exp2_6pp.sce
@@ -0,0 +1,52 @@
+clc
+disp("Example 2.6")
+time=[5 9 18 22 24]
+loadt=[20 40 80 100 20] //given time and load
+k=size(time)
+k=k(1,2)
+timed(1,1)=time(1,1)
+for x=2:k //finding time duration of each load
+ timed(1,x)=time(1,x)-time(1,x-1)
+end
+[m n]=gsort(loadt) //sorting decresing order
+for x=1:k //sorting the load and timeduration correspondingly
+ timed1(1,x)=timed(1,n(x))
+end
+tim(1,1)=timed1(1,1)
+for x=2:k
+ tim(1,x)=timed1(1,x)+tim(1,x-1)
+end
+lo(1,1)=24*min(m)
+m(k+1)=[]
+printf("the energy at different load levels is as under :")
+printf("\nload=%dMW,energy=%dMWh",m(k),lo(1,1))
+y=2
+for x=k-2:-1:1
+ lo(1,y)=lo(1,y-1)+(tim(1,x))*(m(x)-m(x+1))
+ t=m(x);l=lo(1,y)
+ printf("\nload=%dMW,energy=%dMWh",t,l)
+ y=y+1
+end
+for x=1:k
+ for y=x+1:k
+ if m(1,x)==m(1,y) then
+ m(1,y)=[]
+ end
+ end
+end
+pop=gsort(m,'g','i')
+subplot(121)
+plot(lo,pop)
+xtitle("energy load curve","energy","load")
+//time=[5 9 18 22 24]
+//loadt=[20 40 80 100 20]
+printf("\nthe energy load curve is plotted in fig 1 \nthe energy supplied up to different times of the day is as under :")
+et(1,1)=time(1,1)*loadt(1,1)
+for x=2:k
+ printf("\nenergy supplied upto %d is %dMWh",time(1,x-1),et(1,x-1))
+ et(1,x)=et(1,x-1)+loadt(1,x)*(time(1,x)-time(1,x-1))
+
+end
+subplot(122)
+plot(time,et)
+xtitle("masscurve","time in hours","load in MW")
diff --git a/416/CH2/EX2.6/exp2_6pp.txt b/416/CH2/EX2.6/exp2_6pp.txt
new file mode 100755
index 000000000..9aaf6b791
--- /dev/null
+++ b/416/CH2/EX2.6/exp2_6pp.txt
@@ -0,0 +1,13 @@
+
+ Example 2.6
+the energy at different load levels is as under :
+load=20MW,energy=480MWh
+load=40MW,energy=820MWh
+load=80MW,energy=1340MWh
+load=100MW,energy=1420MWh
+the energy load curve is plotted in fig 1
+the energy supplied up to different times of the day is as under :
+energy supplied upto 5 is 100MWh
+energy supplied upto 9 is 260MWh
+energy supplied upto 18 is 980MWh
+energy supplied upto 22 is 1380MWh \ No newline at end of file
diff --git a/416/CH2/EX2.7/exp2_7c.sce b/416/CH2/EX2.7/exp2_7c.sce
new file mode 100755
index 000000000..a3926f876
--- /dev/null
+++ b/416/CH2/EX2.7/exp2_7c.sce
@@ -0,0 +1,15 @@
+clc
+disp("example 2.7")
+md=40;cf=0.5;uf=0.8;//maximum demand in MW;capacity factor;utility factor
+disp("(a)")
+lf=cf/uf; //load factor is ratio of capacity factor to the utility factor
+printf("load factor = capacity factor/utilisation factor =%f",lf)
+disp("(b)")
+pc=md/uf; //plant capacity is ratio of maximum demand to utility factor
+printf("plant capacity = maximum demand/utilisation factor =%dMW",pc)
+disp("(c)")
+rc=pc-md; //reserve capacity is plant capacity minus maximum demand
+printf("reserve capacity =%dMW",rc)
+disp("d")
+printf("annual energy production =%dMWh",md*lf*8760)
+
diff --git a/416/CH2/EX2.7/exp2_7c.txt b/416/CH2/EX2.7/exp2_7c.txt
new file mode 100755
index 000000000..418a99042
--- /dev/null
+++ b/416/CH2/EX2.7/exp2_7c.txt
@@ -0,0 +1,11 @@
+
+ example 2.7
+
+ (a)
+load factor = capacity factor/utilisation factor =0.625000
+ (b)
+plant capacity = maximum demand/utilisation factor =50MW
+ (c)
+reserve capacity =10MW
+ d
+annual energy production =219000MWh \ No newline at end of file
diff --git a/416/CH2/EX2.8/exp2_8c.png b/416/CH2/EX2.8/exp2_8c.png
new file mode 100755
index 000000000..418795901
--- /dev/null
+++ b/416/CH2/EX2.8/exp2_8c.png
Binary files differ
diff --git a/416/CH2/EX2.8/exp2_8cpp.sce b/416/CH2/EX2.8/exp2_8cpp.sce
new file mode 100755
index 000000000..febcc81ba
--- /dev/null
+++ b/416/CH2/EX2.8/exp2_8cpp.sce
@@ -0,0 +1,14 @@
+clc
+disp("example 2.8")
+disp("the chronological load curve is plotted in fig 1")
+a=[0 5 9 18 20 22 24] //time in matrix format
+b=[50 50 100 100 150 80 50]//load in matrix format
+for x=1:6
+ z(1,x)=((b(1,x)+b(1,x+1))/2)*(a(1,(x+1))-a(1,x))
+end
+e=sum(z);
+printf("energy required required by the system in 24 hrs \n =50x5MWh+((100+50)/2)x4MWh +(100x9)MWh+(100+150)MWh+(150+80)MWh+(80+50)MWh \n =%dMWh",sum(z))
+dlf=e/(max(b)*24)
+printf("\ndaily load factor =2060/(150x24) =%f",dlf)
+plot(a,b)
+xtitle("load curve","time","MW")
diff --git a/416/CH2/EX2.8/exp2_8cpp.txt b/416/CH2/EX2.8/exp2_8cpp.txt
new file mode 100755
index 000000000..1c7ffd485
--- /dev/null
+++ b/416/CH2/EX2.8/exp2_8cpp.txt
@@ -0,0 +1,8 @@
+
+ example 2.8
+
+ the chronological load curve is plotted in fig 1
+energy required required by the system in 24 hrs
+ =50x5MWh+((100+50)/2)x4MWh +(100x9)MWh+(100+150)MWh+(150+80)MWh+(80+50)MWh
+ =2060MWh
+daily load factor =2060/(150x24) =0.572222 \ No newline at end of file
diff --git a/416/CH2/EX2.9/exp2_9.png b/416/CH2/EX2.9/exp2_9.png
new file mode 100755
index 000000000..21ef42bfa
--- /dev/null
+++ b/416/CH2/EX2.9/exp2_9.png
Binary files differ
diff --git a/416/CH2/EX2.9/exp2_9c.sce b/416/CH2/EX2.9/exp2_9c.sce
new file mode 100755
index 000000000..d9e2546e4
--- /dev/null
+++ b/416/CH2/EX2.9/exp2_9c.sce
@@ -0,0 +1,32 @@
+clc
+clear
+disp("example 2.9")
+disp("load duration curve in fig1")
+disp("the energy consumed upto different times is as ")
+a=[0 5 9 18 20 22 24] //time in matrix format
+b=[50 50 100 100 150 80 50] //load in matrix format
+for x=1:6
+ z(1,x)=((b(1,x)+b(1,x+1))/2)*(a(1,(x+1))-a(1,x))
+end
+et=0
+for x=1:6
+ et=et+z(1,x);
+ A=a(1,(x+1))
+ ett(1,x)=et;
+ q(1,x)=a(1,x+1)
+ printf("\nfrom mid night upto %d,energy=%dMWh",A,et)
+end
+q(1,x+1)=[]
+[m n]=gsort(b)
+m(1,7)=[];m(1,6)=[]; //rearranging for mass curve
+disp("energy curve in fig 2")
+t=[0 3.88 15.88 19.88 23]
+for j=1:6
+ k(1,j)=a(1,(j+1))
+end
+subplot(121);
+plot(t,m);
+xtitle("load duration","hours","MW")
+subplot(122);
+plot(q,ett,-9);
+xtitle("energy curve","time","MWh")
diff --git a/416/CH2/EX2.9/exp2_9c.txt b/416/CH2/EX2.9/exp2_9c.txt
new file mode 100755
index 000000000..561a14769
--- /dev/null
+++ b/416/CH2/EX2.9/exp2_9c.txt
@@ -0,0 +1,15 @@
+
+ example 2.9
+
+ load duration curve in fig1
+
+ the energy consumed upto different times is as
+
+from mid night upto 5,energy=250MWh
+from mid night upto 9,energy=550MWh
+from mid night upto 18,energy=1450MWh
+from mid night upto 20,energy=1700MWh
+from mid night upto 22,energy=1930MWh
+from mid night upto 24,energy=2060MWh
+ energy curve in fig 2
+ \ No newline at end of file
diff --git a/416/CH20/EX20.1/ans20_1.txt b/416/CH20/EX20.1/ans20_1.txt
new file mode 100755
index 000000000..f32f8a646
--- /dev/null
+++ b/416/CH20/EX20.1/ans20_1.txt
@@ -0,0 +1,16 @@
+
+ example 20.1
+(a)
+economic power factor 0.927lagging
+(b)
+capacitor kVAr to improve the power factor 0.3979
+(c)
+initial kVA 1282.05KVA
+annual energy used 7.008e+009kWh
+electrical bill Rs2.452826e+010 per year
+(d)
+KVA after installation of capacitors 1078.75KVA
+energy bill after installation of capacitor Rs2.452822e+010 per year
+annual interest and depreciation of capacitor bank Rs29842.5per year
+total expendition after installation of capacitors Rs2.452825e+010 per year
+ annual savings due to installation of capacitors Rs10817 per year \ No newline at end of file
diff --git a/416/CH20/EX20.1/example20_1.sce b/416/CH20/EX20.1/example20_1.sce
new file mode 100755
index 000000000..de23afab7
--- /dev/null
+++ b/416/CH20/EX20.1/example20_1.sce
@@ -0,0 +1,31 @@
+clc
+clear
+disp('example 20.1')
+lod=1 //industrial installation load
+pf=0.78 //power factor
+tf=200 //tariff
+md=3.5 //extra maximum demand
+ic=500 //installation of capacitor
+id=0.15 //interest and depreciation
+lf=0.8 //load factor
+sinp=ic*id/tf
+ph2=asind(sinp)
+epf2=cosd(ph2)
+ph1=acosd(pf)
+ph1=round(ph1*10^2)/10^2
+ph2=round(ph2*10^2)/10^2
+q=lod*(tand(ph1)-tand(ph2))
+q=round(q*10^4)/10^4
+ikva=lod/pf
+ikv=round(ikva*(10^5))/10^2
+aeu=lod*lf*8760*10^6
+eb=ikv*tf+aeu*md
+printf("(a)\neconomic power factor %.3flagging \n(b) \ncapacitor kVAr to improve the power factor %.4f \n(c) \ninitial kVA %.2fKVA \nannual energy used %0.3ekWh \nelectrical bill Rs%e per year",epf2,q,ikv,aeu,eb)
+kvc=round((lod*10^3/(round(epf2*1000)/10^3))*10^2)/10^2
+ebc=kvc*tf+aeu*md
+aidc=q*10^3*ic*id
+te=ebc+aidc
+asc=eb-te
+printf("\n(d)\nKVA after installation of capacitors %.2fKVA \n",kvc)
+printf("energy bill after installation of capacitor Rs%e per year \n",ebc)
+printf("annual interest and depreciation of capacitor bank Rs%.1fper year \ntotal expendition after installation of capacitors Rs%e per year \n annual savings due to installation of capacitors Rs%d per year",aidc,te,asc) \ No newline at end of file
diff --git a/416/CH20/EX20.2/ans20_2.txt b/416/CH20/EX20.2/ans20_2.txt
new file mode 100755
index 000000000..7cefb0c43
--- /dev/null
+++ b/416/CH20/EX20.2/ans20_2.txt
@@ -0,0 +1,14 @@
+
+ example 20.2
+ depreciation rate 0.01235
+ total fixed charge rate 0.142350
+ annual cost of efficiency motor Rs7.118000e+005per year
+ total electrical bill with present motors Rs2.050000e+007per year
+ total electrical bill with efficiency motor Rs.1.845000e+007
+ total annual cost if motors are replaced by high efficiency motors Rs1.916180e+007 per year
+ annual saving Rs1338200 per year
+ b
+present worth factor 0.14235
+ present worth of annual cost with existing motors Rs1.440100e+008
+ present worth of annual cost with new motor Rs1.296100e+008
+ total present worth 1.346100e+008 per year \ No newline at end of file
diff --git a/416/CH20/EX20.2/example20_2.sce b/416/CH20/EX20.2/example20_2.sce
new file mode 100755
index 000000000..cf9cf3567
--- /dev/null
+++ b/416/CH20/EX20.2/example20_2.sce
@@ -0,0 +1,30 @@
+clc
+clear
+disp('example 20.2')
+ee=5*10^16 //electrical energy requirement
+eer=0.1 //energy requirement
+i=5*10^6 //investement
+n=20 //life time
+ec=4.1 //energy cost
+r=0.13 //interest rate
+dr=r/((1+r)^(n)-1) //depreciation rate
+dr=round(dr*10^5)/10^5
+tfc=r+dr //total fixed cost
+ace=i*tfc //annual cost
+ace=round(ace/10^2)*10^2
+eb=i*ec //electrical bill with present motor
+teb=eb*(1-eer) //electrical bill with efficiency motor
+tac=teb+ace //total annual cost with efficiency cost
+as=eb-tac //annual saving
+printf(" depreciation rate %.5f \n total fixed charge rate %f\n annual cost of efficiency motor Rs%eper year \n total electrical bill with present motors Rs%eper year \n total electrical bill with efficiency motor Rs.%e \n total annual cost if motors are replaced by high efficiency motors Rs%e per year \n annual saving Rs%d per year",dr,tfc,ace,eb,teb,tac,as)
+disp('b')
+pwf=r/(1-((1+r)^-n)) //present worth factor
+pwf=round(pwf*10^5)/10^5
+pwm=teb/pwf //present worth annual cost with existing motors
+pwm=round(pwm/10^4)*10^4 //present worth with existing motors
+pwem=eb/pwf //present worth with efficiency motor
+pwem=round(pwem/10^4)*10^4
+pwam=teb/pwf
+pwam=round(pwam/10^4)*10^4
+tpw=pwam+i //total persent worth
+printf("present worth factor %.5f \n present worth of annual cost with existing motors Rs%e \n present worth of annual cost with new motor Rs%e \n total present worth %e per year",pwf,pwem,pwam,tpw) \ No newline at end of file
diff --git a/416/CH23/EX23.1/ans23_1pp.txt b/416/CH23/EX23.1/ans23_1pp.txt
new file mode 100755
index 000000000..c44086ee9
--- /dev/null
+++ b/416/CH23/EX23.1/ans23_1pp.txt
@@ -0,0 +1,14 @@
+
+ example:23.1
+
+capitel cost is 27272.7/kW
+CRF=0.171
+annual fixed cost is Rs4664.10/kW
+heat rate is 2457.142857cal/kWh
+number of kWh generated per liter of fuel is 4.11kWh/litre
+fuel cost per unit Rs1.702970per kWh
+annual operation cost Rs.545.4545/kW
+annual fixed, operation and maintence cost Rs.5209.56/kW
+energygenerated per year is 7008kWh
+annual fixed operation and maintenence cost per kWh of energy 0.7434/kWh
+generated cost is Rs2.4463/kWh \ No newline at end of file
diff --git a/416/CH23/EX23.1/exp23_1pp.sce b/416/CH23/EX23.1/exp23_1pp.sce
new file mode 100755
index 000000000..46a9b2e81
--- /dev/null
+++ b/416/CH23/EX23.1/exp23_1pp.sce
@@ -0,0 +1,28 @@
+clc
+clear
+disp('example:23.1')
+sp=11*10^3;pc=300*10^6;ir=0.15;lp=15;fc=7;eff=0.35;cv=10100;mc=0.02;lf=0.8;er=860 //let the given variable be --sp=size of plant ,pc=project cost,ir=interest rate,lp=life of the plant,fc=fuel cost,eff=efficiency,cv=calorific value,er=860,mc=maintenance cost,lf=load factor,
+cac=pc/sp //let the variable cac be captel cost
+printf("\ncapitel cost is %.1f/kW",cac)
+crfd1=(1+ir)^(-lp)
+crfd=1-crfd1
+crf=ir/crfd //crf=capitel cost recovery factor
+printf("\nCRF=%.3f",crf)
+anfc=cac*crf //anual fixed cost is prodect of capitel cost and capitel recovery factor
+printf("\nannual fixed cost is Rs%.2f/kW",anfc)
+hr=er/eff //heat rate is energy ratedivided by efficiency
+printf("\nheat rate is %fcal/kWh",hr)
+gpf=cv/hr;//kW generated per liter is division of calorific value to hr
+printf("\nnumber of kWh generated per liter of fuel is %.2fkWh/litre",gpf)
+fcp=fc/gpf //fuel cost per unit is fuel cost divided by generated per liter
+printf("\nfuel cost per unit Rs%fper kWh",fcp)
+aomc=cac*mc //annual operation and maintenence cost
+printf("\nannual operation cost Rs.%.4f/kW",aomc)
+afom=anfc+aomc
+printf("\nannual fixed, operation and maintence cost Rs.%.2f/kW",afom)
+egpy=8760*lf //energy generated is 24*12*60
+printf("\nenergygenerated per year is %dkWh",egpy)
+afomc=afom/egpy
+printf("\nannual fixed operation and maintenence cost per kWh of energy %.4f/kWh",afomc)
+gco=fcp+afomc //generated cost is sum of fuel cost and maintenence cost
+printf("\ngenerated cost is Rs%.4f/kWh",gco)
diff --git a/416/CH23/EX23.11.2/sample23_11_2pp.sce b/416/CH23/EX23.11.2/sample23_11_2pp.sce
new file mode 100755
index 000000000..def165145
--- /dev/null
+++ b/416/CH23/EX23.11.2/sample23_11_2pp.sce
@@ -0,0 +1,18 @@
+clc
+clear
+disp("sample problem in 23.11.2")
+pp=11 //power capacity
+cost=35 //cost of the system
+in=0.14 //interest
+lis=30 //life of system
+sv=0.15 //salvage value
+es=13.5*10^6 //energy sent
+los=0.05 //losses
+omc=0.02 //O&M charges
+gr=0.006 //general revenue
+rd=(1-sv)*100/lis
+rdd=rd/100
+tac=cost*(in+omc+rdd+gr)
+ery=es*(1-los)
+wc=(tac/ery)*10^5
+printf("rate of depreciation is %.3fpercent \ntotal annual cost is Rs.%.5f lakhs/year \nenergy received per year %ekWh/year \nwheeling charges Rs%f",rd,tac,ery,wc) \ No newline at end of file
diff --git a/416/CH23/EX23.11.2/samplepp.txt b/416/CH23/EX23.11.2/samplepp.txt
new file mode 100755
index 000000000..f4d664d66
--- /dev/null
+++ b/416/CH23/EX23.11.2/samplepp.txt
@@ -0,0 +1,6 @@
+
+ sample problem in 23.11.2
+rate of depreciation is 2.833percent
+total annual cost is Rs.6.80167 lakhs/year
+energy received per year 1.282500e+007kWh/year
+wheeling charges Rs0.053034 \ No newline at end of file
diff --git a/416/CH23/EX23.2/ans23_2.txt b/416/CH23/EX23.2/ans23_2.txt
new file mode 100755
index 000000000..a344f7fd4
--- /dev/null
+++ b/416/CH23/EX23.2/ans23_2.txt
@@ -0,0 +1,10 @@
+
+ example 23.2
+net capital cost Rs560*10^6
+net capital cost per KW Rs22400.000000/kW
+crf 0.117460
+annual fixed cost Rs2631 per kW
+annual operation and maintenance cost Rs1120per kW
+Total annual cost Rs3751per kW
+Annual energy generated per kW of plant capacity 5256.0kWh
+generation cost Rs0.714kWh \ No newline at end of file
diff --git a/416/CH23/EX23.2/exp23_2.sce b/416/CH23/EX23.2/exp23_2.sce
new file mode 100755
index 000000000..15da2a607
--- /dev/null
+++ b/416/CH23/EX23.2/exp23_2.sce
@@ -0,0 +1,19 @@
+clc
+clear
+disp('example 23.2')
+sp=25*10^3 //size of the plant
+cc=800*10^6 //capital cost
+ir=0.1 //interest rate
+lp=20 //life of the plant
+mc=0.05 //maintence cost
+lf=0.6 //load factor
+sub=0.3 //subsidy
+nc=cc*(1-sub)
+nck=nc/sp
+crf=ir/(1-(1+ir)^(-lp))
+afc=nck*crf
+aomc=nck*mc
+tac=afc+aomc
+aeg=8760*lf
+gc=tac/aeg
+printf("net capital cost Rs%d*10^6 \nnet capital cost per KW Rs%f/kW \ncrf %f \nannual fixed cost Rs%d per kW \nannual operation and maintenance cost Rs%dper kW \nTotal annual cost Rs%dper kW \nAnnual energy generated per kW of plant capacity %.1fkWh \ngeneration cost Rs%.3fkWh",nc/(10^6),nck,crf,afc,aomc,tac,aeg,gc) \ No newline at end of file
diff --git a/416/CH3/EX3.1/exp3_1c.sce b/416/CH3/EX3.1/exp3_1c.sce
new file mode 100755
index 000000000..856f6112a
--- /dev/null
+++ b/416/CH3/EX3.1/exp3_1c.sce
@@ -0,0 +1,21 @@
+clc
+disp("example 3.1")
+totpow=110*10^3 //(kW)
+uc1=18000;fcr1=0.1;cf1=0.55;fuelcons1=0.7;fuelcost1=1500/1000;om1=0.2;utilizationf1=1;
+uc2=30000;fcr2=0.1;cf2=0.60;fuelcons2=0.65;fuelcost2=1500/1000;om2=0.2;utilizationf2=1;
+//given uck=unit capital cost k;fcrk= fixed charge rate of kth unit;cfk=capacity factor at k th unit; omk=annual cost of operating labour ;totpow=total power rating of units
+afc1=fcr1*uc1*totpow;afc2=fcr2*uc2*totpow;
+e1=8760*cf1*totpow;e2=8760*cf2*totpow;
+annualfuel1=e1*fuelcons1;annualfuel2=e2*fuelcons2;
+fc1=annualfuel1*fuelcost1;fc2=annualfuel2*fuelcost2;
+om11=om1*fc1;om22=om2*fc2;
+aoc1=fc1+om1;aoc2=fc2+om2;
+apc1=aoc1+afc1;apc2=aoc2+afc2;
+gc1=apc1/fc1;gc2=apc2/fc2
+disp("solution for (a)")
+printf("\nafc1=Rs.%d\n e1=%dkWh\n annualfual1=%fkg \n fc1=Rs.%d \n om1=Rs.%d \n aoc1=Rs.%f \n apc1=Rs.%f \n gc1=%fkWh\n",afc1,e1,annualfuel1,fc1,om11,aoc1,apc1,gc1)
+ disp("solution for (b)")
+printf("\nafc2=Rs.%d\n e2=%dkWh\n annualfual2=%fkg \n fc2=Rs.%d \n om22=Rs.%d \n aoc2=Rs.%f \n apc2=Rs.%f \n gc2=%fkWh\n",afc2,e2,annualfuel2,fc2,om22,aoc2,apc2,gc1)
+ogc=(apc1+apc2)/(e1+e2)
+
+printf("\n\nsolution of (c)\nogc=Rs.%f/kWh",ogc) \ No newline at end of file
diff --git a/416/CH3/EX3.1/exp3_1c.txt b/416/CH3/EX3.1/exp3_1c.txt
new file mode 100755
index 000000000..6e51aba82
--- /dev/null
+++ b/416/CH3/EX3.1/exp3_1c.txt
@@ -0,0 +1,29 @@
+
+
+ example 3.1
+
+ solution for (a)
+
+afc1=Rs.198000000
+ e1=529980000kWh
+ annualfual1=370986000.000000kg
+ fc1=Rs.556479000
+ om1=Rs.111295800
+ aoc1=Rs.556479000.200000
+ apc1=Rs.754479000.200000
+ gc1=1.355809kWh
+
+ solution for (b)
+
+afc2=Rs.330000000
+ e2=578160000kWh
+ annualfual2=375804000.000000kg
+ fc2=Rs.563706000
+ om22=Rs.112741200
+ aoc2=Rs.563706000.200000
+ apc2=Rs.893706000.200000
+ gc2=1.355809kWh
+
+
+solution of (c)
+ogc=Rs.1.487344/kWh \ No newline at end of file
diff --git a/416/CH3/EX3.16/data3_16pp.sce b/416/CH3/EX3.16/data3_16pp.sce
new file mode 100755
index 000000000..1b7462bcf
--- /dev/null
+++ b/416/CH3/EX3.16/data3_16pp.sce
@@ -0,0 +1,29 @@
+clear
+clc
+disp("data 3.16")
+pu=500*10^3 ;pc=2*pu //plant unit,plant capacity
+land=11.865*10^9
+cicost=30.135*10^9
+ccost=land+cicost; //capital cost =land cost+civil cost
+plife=25; //plant life
+ir=0.16; //interest rate
+ond=1.5*10^-2;// o and mof capital cost
+gr=0.5*10^-2 //grneral reserve of capital cost
+calv=4158 //calorific value kj per kg
+coalcost=990 //caol cost per ton
+heat=2500//heat rate kcal/kWh
+retur=0.08 //return
+salvage=0
+plf=0.69 ;auxcons=0.075 //auxiliary consumption
+disp("cost calculation ")
+disp("using sinking fund depreciation")
+ande=(ir/((ir+1)^(plife)-1))*100
+afixcost=ccost*(ir+ond+retur+gr+(ande/100))
+afcppc=afixcost/pc
+printf("annual depretion reserve is %fpersent \n annual fixed cost Rs%f \n annual fixed cost per Rs%dkWh",ande,afixcost,afcppc)
+fclco=(heat*coalcost)/(calv*1000)
+engepc=24*365*plf
+enavil=engepc*(1-auxcons)
+gencost=(afcppc/enavil)+fclco
+printf("\nfuel cost Rs.%f/kWh \nenergy generated per kW of plant capacity Rs.%fkWh \nenergy available bus bar %fkWh \n generation cost Rs%f perkWh",fclco,engepc,enavil,gencost)
+
diff --git a/416/CH3/EX3.16/data3_16pp.txt b/416/CH3/EX3.16/data3_16pp.txt
new file mode 100755
index 000000000..c16fb6eb2
--- /dev/null
+++ b/416/CH3/EX3.16/data3_16pp.txt
@@ -0,0 +1,14 @@
+
+
+ data 3.16
+
+ cost calculation
+
+ using sinking fund depreciation
+annual depretion reserve is 0.401262persent
+ annual fixed cost Rs11088529841.947702
+ annual fixed cost per Rs11088kWh
+fuel cost Rs.0.595238/kWh
+energy generated per kW of plant capacity Rs.6044.400000kWh
+energy available bus bar 5591.070000kWh
+ generation cost Rs2.578495 perkWh \ No newline at end of file
diff --git a/416/CH3/EX3.17/data3_17c.sce b/416/CH3/EX3.17/data3_17c.sce
new file mode 100755
index 000000000..fd7a7c95c
--- /dev/null
+++ b/416/CH3/EX3.17/data3_17c.sce
@@ -0,0 +1,16 @@
+clear
+clc
+disp("dat 3.17")
+pco=120*10^3 //3 units of 40MW
+caco=68*10^8 //6 year of consumption
+inr=0.16 //intrest rate
+de=2.5*10^-2 //depreciation
+oanm=1.5*10^-2//OandM
+ger=0.5*10^-2//general reserve
+pllf=0.6 //plant load facot
+aucon=0.5*10^-2 //auxiliary consumption
+tac=caco*(inr+de+oanm+aucon) ///total cost
+engpy=pco*pllf*24*365 //energy generatedper year
+eabb=engpy*(1-ger) //energy available at bus bar
+geco=tac/eabb //generation cost
+printf(" total annual costs is Rs%e per year \n energy generated per year =%ekWh/year \n energy available at bus bar %ekWh/year \n generation cost is Rs.%fper kWh",tac,engpy,eabb,geco) \ No newline at end of file
diff --git a/416/CH3/EX3.17/data3_17c.txt b/416/CH3/EX3.17/data3_17c.txt
new file mode 100755
index 000000000..3fc0e8b18
--- /dev/null
+++ b/416/CH3/EX3.17/data3_17c.txt
@@ -0,0 +1,6 @@
+
+ dat 3.17
+ total annual costs is Rs1.394000e+009 per year
+ energy generated per year =6.307200e+008kWh/year
+ energy available at bus bar 6.275664e+008kWh/year
+ generation cost is Rs.2.221279per kWh \ No newline at end of file
diff --git a/416/CH3/EX3.2/exp3_2c.sce b/416/CH3/EX3.2/exp3_2c.sce
new file mode 100755
index 000000000..be4ede5be
--- /dev/null
+++ b/416/CH3/EX3.2/exp3_2c.sce
@@ -0,0 +1,14 @@
+clear
+clc
+disp("example 3.2")
+c=2*10^8;//cost
+s=0.15;//salvage value
+ul=25; ///useful value
+i=0.08;//life of plant
+disp("solution for (a)")
+printf("\nannual straight line depreciation reserve =Rs.%.1eperyear\n",c*(1-s)/ul)
+disp("solution for (b)")
+it=(i+1)^25-1
+iit=i/it
+asdr=c*(1-s)*iit*100
+printf("\n annual sinking fund depreciation reserve is =Rs%.3eperyear",asdr)
diff --git a/416/CH3/EX3.2/exp3_2c.txt b/416/CH3/EX3.2/exp3_2c.txt
new file mode 100755
index 000000000..2614d44d1
--- /dev/null
+++ b/416/CH3/EX3.2/exp3_2c.txt
@@ -0,0 +1,10 @@
+
+ example 3.2
+
+ solution for (a)
+
+annual straight line depreciation reserve =Rs.6.8e+006peryear
+
+ solution for (b)
+
+ annual sinking fund depreciation reserve is =Rs2.325e+008peryear \ No newline at end of file
diff --git a/416/CH3/EX3.3/exp3_3pp.sce b/416/CH3/EX3.3/exp3_3pp.sce
new file mode 100755
index 000000000..36703a32e
--- /dev/null
+++ b/416/CH3/EX3.3/exp3_3pp.sce
@@ -0,0 +1,11 @@
+clear
+clc
+disp("example 3.3")
+cost=2*10^8
+sal=0.15
+use=25
+t=(1-(sal^(1/use)))
+printf("rate of depretion by fixed percentage method =%fpersent",t*100)
+rd=cost*(1-t)^10
+printf("\nremaining depreciation at the end of 10th year =Rs.%f=Rs.%fx10^8",rd,rd/(10^8))
+printf("\naccumulated depreciation at the end of 10 year is Rs.%f =Rs.%fx10^8",cost-rd,(cost-rd)/10^8) \ No newline at end of file
diff --git a/416/CH3/EX3.3/exp3_3pp.txt b/416/CH3/EX3.3/exp3_3pp.txt
new file mode 100755
index 000000000..9216d56f1
--- /dev/null
+++ b/416/CH3/EX3.3/exp3_3pp.txt
@@ -0,0 +1,5 @@
+
+ example 3.3
+rate of depretion by fixed percentage method =7.307702persent
+remaining depreciation at the end of 10th year =Rs.93641098.400924=Rs.0.936411x10^8
+accumulated depreciation at the end of 10 year is Rs.106358901.599076 =Rs.1.063589x10^8 \ No newline at end of file
diff --git a/416/CH3/EX3.4/exp3_4.png b/416/CH3/EX3.4/exp3_4.png
new file mode 100755
index 000000000..3be3412dc
--- /dev/null
+++ b/416/CH3/EX3.4/exp3_4.png
Binary files differ
diff --git a/416/CH3/EX3.4/exp3_4pp.sce b/416/CH3/EX3.4/exp3_4pp.sce
new file mode 100755
index 000000000..3cb275158
--- /dev/null
+++ b/416/CH3/EX3.4/exp3_4pp.sce
@@ -0,0 +1,33 @@
+clc
+clear
+disp("example 3 4")
+p=100 //ratring of steam station
+fc=3000 //fixed cost of plant per year
+rg=0.9 //90 paise per kv generation
+uf=1 //utilization factor 1
+lf=20:20:100 //let load factor be 5 discreate units
+lm=uf*lf //lwt load MW is as same as lf as utilisation factor is 1
+n=size(lm)
+fc=fc*ones(1,n(2))
+op=rg*100*ones(1,n(2))
+for i=1:n(2)
+ negp(1,i)=lm(i)*8760
+ fcgp(1,i)=fc(i)*10000/negp(i)
+ tgc(1,i)=fcgp(i)+op(i)
+end
+plot2d4(lf,tgc)
+printf("load factor")
+disp(lf)
+printf("load MW\n")
+fcgp=fcgp/100;op=op/100;tgc=tgc/100
+printf("%dMW\t%dMW\t%dMW\t%dMW\t%dMW",lm(1),lm(2),lm(3),lm(4),lm(5))
+disp("fixed cost")
+printf("Rs%d\tRS%d\tRs%d\tRs%d\tRs%d",fc(1),fc(2),fc(3),fc(4),fc(5))
+disp("number of KW hrs of energy generated in paise per unit of energy")
+printf("%dkWh\t%dkWh\t%dkWh\t%dkWh\t%dkWh",negp(1),negp(2),negp(3),negp(4),negp(5))
+disp("fixed cost in paise per unit of energy")
+printf("Rs%.3f\tRS%.3f\tRs%.3f\tRs%.3f\tRs%.3f",fcgp(1),fcgp(2),fcgp(3),fcgp(4),fcgp(5))
+disp("operating cost in paise per unit of energy")
+printf("Rs%.3f\tRS%.3f\tRs%.3f\tRs%.3f\tRs%.3f",op(1),op(2),op(3),op(4),op(5))
+disp("totla generation cost in paise per unit of energy")
+printf("Rs%.3f\tRS%.3f\tRs%.3f\tRs%.3f\tRs%.3f",tgc(1),tgc(2),tgc(3),tgc(4),tgc(5)) \ No newline at end of file
diff --git a/416/CH3/EX3.4/exp3_4pp.txt b/416/CH3/EX3.4/exp3_4pp.txt
new file mode 100755
index 000000000..fb5e17681
--- /dev/null
+++ b/416/CH3/EX3.4/exp3_4pp.txt
@@ -0,0 +1,29 @@
+
+ example 3 4
+load factor
+ 20. 40. 60. 80. 100.
+load MW
+20MW 40MW 60MW 80MW 100MW
+ fixed cost
+Rs3000 RS3000 Rs3000 Rs3000 Rs3000
+ number of KW hrs of energy generated in paise per unit of energy
+175200kWh 350400kWh 525600kWh 700800kWh 876000kWh
+ fixed cost in paise per unit of energy
+Rs1.712 RS0.856 Rs0.571 Rs0.428 Rs0.342
+ operating cost in paise per unit of energy
+Rs0.900 RS0.900 Rs0.900 Rs0.900 Rs0.900
+ totla generation cost in paise per unit of energy
+Rs2.612 RS1.756 Rs1.471 Rs1.328 Rs1.242
+
+ 90. 90. 90. 90. 90.
+
+ totla generation cost in paise per unit of energy
+
+
+ column 1 to 4
+
+ 261.23288 175.61644 147.07763 132.80822
+
+ column 5
+
+ 124.24658 \ No newline at end of file
diff --git a/416/CH3/EX3.5/exp3_5c.sce b/416/CH3/EX3.5/exp3_5c.sce
new file mode 100755
index 000000000..22745af8b
--- /dev/null
+++ b/416/CH3/EX3.5/exp3_5c.sce
@@ -0,0 +1,24 @@
+clear
+clc
+disp("example 3.5")
+ic=120 //installed capacity
+ccppkw=40000 ///capital cost of plant
+iand=0.15 //interest and depreciation
+fco=0.64 //fuel consumption
+fc=1.5//fuel cost
+oc=50*10^6 //operating cost
+pl=100//peak load
+lf=0.6 //load factor
+al=lf*pl//avarrage load
+printf(" average load %dMW",al)
+eg=al*8760*10^3//energy generated
+printf("\n energy generated =%ekWhr",eg)
+ti=ic*ccppkw //total investiment
+printf("\n total investement Rs.%e",ti)
+ind=ti*iand*10^3//interest and depreciation
+printf("\n investement amd depression is Rs.%e",ind)
+fcons=eg*fco //fual consumption
+printf("\n fuel consumtion is %ekgper year",fcons)
+fcost=fcons*fc//fuel cost
+aco=ti+fcost+ind+oc//annual cost
+printf("\n fuel cost Rs.%eper year \n annual plant cost Rs%eper year \n generation cost Rs%fper year",fcost,aco,aco/eg) \ No newline at end of file
diff --git a/416/CH3/EX3.5/exp3_5c.txt b/416/CH3/EX3.5/exp3_5c.txt
new file mode 100755
index 000000000..55c8f04f9
--- /dev/null
+++ b/416/CH3/EX3.5/exp3_5c.txt
@@ -0,0 +1,10 @@
+
+ example 3.5
+ average load 60MW
+ energy generated =5.256000e+008kWhr
+ total investement Rs.4.800000e+006
+ investement amd depression is Rs.7.200000e+008
+ fuel consumtion is 3.363840e+008kgper year
+ fuel cost Rs.5.045760e+008per year
+ annual plant cost Rs1.279376e+009per year
+ generation cost Rs2.434125per year \ No newline at end of file
diff --git a/416/CH3/EX3.6/exp3_6cpp.sce b/416/CH3/EX3.6/exp3_6cpp.sce
new file mode 100755
index 000000000..631dfc248
--- /dev/null
+++ b/416/CH3/EX3.6/exp3_6cpp.sce
@@ -0,0 +1,24 @@
+clear
+clc
+disp("example 3.6")
+md=50*10^3;//maximum demand in kW
+ecy=0
+pst=600*md+2.5*ecy//public supply tariff equation
+lfr=0.5; //load factor
+rc=20*10^3;//reserve capacity
+cik=30000; //capital investiment
+inad=0.15;///interest and depreciation
+fuc=0.6;fuco=1.4;oct=0.8//fuel consumption//fuel cost//other cost
+avl=md*lfr;//average load
+ecy=avl*8760 //energy cosumption per year
+disp("solution of (a)")
+printf(" average load = %dkW \n energy consumton =%dkWh\n annual expenditure is Rs%dperyear\n",avl,ecy,pst)
+disp("(b) private steam plant")
+ict=md+rc; //installed capacity
+caint=cik*ict; //capital investiment
+iande=inad*caint; //interest and depreciation
+fuelcon=ecy*fuc; //fuel consumption
+fucost=fuelcon*fuco; //fuel cost
+opwe=oct*ecy //other expenditure
+totex=iande+fucost+opwe//total expenditure
+printf("\n installed capacity is Rs%d \n capital investiment is Rs%d \n interest and depreciation is Rs.%d \n fuel consumption is Rs.%f \n fuel cost is Rs.%f per year \n wage,repair and other expenses are Rs%f per year \n total expenditure is Rs%e per year",ict,caint,iande,fuelcon,fucost,opwe,totex) \ No newline at end of file
diff --git a/416/CH3/EX3.6/exp3_6cpp.txt b/416/CH3/EX3.6/exp3_6cpp.txt
new file mode 100755
index 000000000..48a7d2fc9
--- /dev/null
+++ b/416/CH3/EX3.6/exp3_6cpp.txt
@@ -0,0 +1,17 @@
+
+ example 3.6
+
+ solution of (a)
+ average load = 25000kW
+ energy consumton =219000000kWh
+ annual expenditure is Rs30000000peryear
+
+ (b) private steam plant
+
+ installed capacity is Rs70000
+ capital investiment is Rs2100000000
+ interest and depreciation is Rs.315000000
+ fuel consumption is Rs.131400000.000000
+ fuel cost is Rs.183960000.000000 per year
+ wage,repair and other expenses are Rs175200000.000000 per year
+ total expenditure is Rs6.741600e+008 per year \ No newline at end of file
diff --git a/416/CH3/EX3.7/exp3_7pp.sce b/416/CH3/EX3.7/exp3_7pp.sce
new file mode 100755
index 000000000..afc5fb15a
--- /dev/null
+++ b/416/CH3/EX3.7/exp3_7pp.sce
@@ -0,0 +1,17 @@
+clc
+clear
+disp("example 3 7")
+md=500 //given maximum demand
+lf=0.5 //load factor
+hp=7200;he=0.36//operating cost of hydro plant
+tp=3600;te=1.56 //operating cost of thermal plant
+teg=md*1000*lf*8760 //total energy generated
+printf("total energy generated per year %2.2eW",teg)
+t=(hp-tp)/(te-he) //time of operating useing (de/dp)
+ph=md*(1-t/8760) //from triangle adf
+pt=md-ph
+et=pt*t*1000/2
+eh=teg-et
+co=hp*ph*1000+he*eh+tp*pt*1000+te*et
+ogc=co/teg
+printf("\n capacity of hydro plant is %dMW \n capacity of thermal plant %dMW\n energy generatede by hydro plant %dkWh\n energy generated by thermal plant %dkWh\n over all generation cost is %.3f/kWh",ph,pt,eh,et,ogc)
diff --git a/416/CH3/EX3.7/exp3_7pp.txt b/416/CH3/EX3.7/exp3_7pp.txt
new file mode 100755
index 000000000..fbf2a877c
--- /dev/null
+++ b/416/CH3/EX3.7/exp3_7pp.txt
@@ -0,0 +1,8 @@
+
+ example 3 7
+total energy generated per year 2.19e+009W
+ capacity of hydro plant is 328MW
+ capacity of thermal plant 171MW
+ energy generatede by hydro plant 1933150684kWh
+ energy generated by thermal plant 256849315kWh
+ over all generation cost is 1.863/kWh \ No newline at end of file
diff --git a/416/CH4/EX4.1/ans4_1.txt b/416/CH4/EX4.1/ans4_1.txt
new file mode 100755
index 000000000..7740f321d
--- /dev/null
+++ b/416/CH4/EX4.1/ans4_1.txt
@@ -0,0 +1,5 @@
+
+ example 4 1
+total energy consumption in 30 day 123units
+the monthly bill Rs308.16
+net monthly bill Rs292.75 \ No newline at end of file
diff --git a/416/CH4/EX4.1/example4_1.sce b/416/CH4/EX4.1/example4_1.sce
new file mode 100755
index 000000000..e89f2101f
--- /dev/null
+++ b/416/CH4/EX4.1/example4_1.sce
@@ -0,0 +1,18 @@
+clc
+clear
+disp('example 4 1')
+day=30 //days
+pll=40;nll=5;tll=3 //light load
+pfl=100;nfl=3;tfl=5 //fan load
+prl=1*1000 //refrigerator
+pml=1*1000;nml=1 //misc. load
+t1=2.74;t11=15//tariff
+t2=2.70;t22=25 //tariff on 25 units
+tr=2.32; //reamaining units
+tc=7.00;//constant charge
+dis=0.05//discount for prompt payment
+te=(pll*nll*tll+pfl*nfl*tfl)*day+prl*day+pml*day
+tee=te/1000
+mb=tc+tr*(tee-t11-t22)+t1*t11+t2*t22
+nmb=mb*(1-dis)
+printf("total energy consumption in %d day %dunits \nthe monthly bill Rs%.2f \nnet monthly bill Rs%.2f",day,tee,mb,nmb) \ No newline at end of file
diff --git a/416/CH4/EX4.10/exp4_10cpp.sce b/416/CH4/EX4.10/exp4_10cpp.sce
new file mode 100755
index 000000000..fda06e931
--- /dev/null
+++ b/416/CH4/EX4.10/exp4_10cpp.sce
@@ -0,0 +1,22 @@
+clc
+clear
+disp("example 4 10")
+v=400//voltage
+i=25///current
+pf=0.8//at power factor
+pf2=0.9//over all power factor
+kw=v*i*pf*sqrt(3)/1000
+printf("kw rating of induction motor %.2fkW",kw)
+dm=acosd(pf)
+rp=kw*tand(dm)
+printf("\n power factor angle %.2f \n reactive power %.2fkVR",dm,rp)
+fdm=acosd(pf2)
+rp2=kw*tand(fdm)
+printf("\n final power factor %.2f \n final reactance power %.2fkVR",fdm,rp2)
+ckvb=rp-rp2
+cc=ckvb*1000/(sqrt(3)*v)
+vc=v/sqrt(3)
+xc=vc/cc
+f=50
+cec=1*10^(6)/(xc*2*%pi*f)
+printf("\n kvar rating of capacitor bank %.4f \n current through each capacitor %.2fA\n voltage across each capacitor %.2f \n reactance of each capacitor %.2fohm \n capacitance of each capacitance %.2fuf",ckvb,cc,vc,xc,cec) \ No newline at end of file
diff --git a/416/CH4/EX4.10/exp4_10cpp.txt b/416/CH4/EX4.10/exp4_10cpp.txt
new file mode 100755
index 000000000..1a809a72a
--- /dev/null
+++ b/416/CH4/EX4.10/exp4_10cpp.txt
@@ -0,0 +1,12 @@
+
+ example 4 10
+kw rating of induction motor 13.86kW
+ power factor angle 36.87
+ reactive power 10.39kVR
+ final power factor 25.84
+ final reactance power 6.71kVR
+ kvar rating of capacitor bank 3.6813
+ current through each capacitor 5.31A
+ voltage across each capacitor 230.94
+ reactance of each capacitor 43.46ohm
+ capacitance of each capacitance 73.24uf \ No newline at end of file
diff --git a/416/CH4/EX4.11/exp4_11cpp.sce b/416/CH4/EX4.11/exp4_11cpp.sce
new file mode 100755
index 000000000..2da0be3a3
--- /dev/null
+++ b/416/CH4/EX4.11/exp4_11cpp.sce
@@ -0,0 +1,28 @@
+clc
+clear
+disp("example 4 11")
+v=400//line voltage
+i=50 //line current
+pf=0.8 //at power factor
+pf2=0.95 // overall power factor
+sm=25 //hp of synchronous motor
+e=0.9//efficiency
+kwri=v*i*pf*sqrt(3)/1000
+kvari=v*i*sqrt(3)/1000
+karri=(-kwri^2+kvari^2)^0.5
+kwsm=sm*735.5/(e*1000)
+tkw=kwri+kwsm
+printf(" kw rating of installation %.1fkW \n kVA rating of installation %.2fkva \n kVAR rating %.2fkvar \n kw input to synchrounous motor %.2fkw \n total kw=%.2f\n",kwri,kvari,karri,kwsm,tkw)
+pd=acosd(pf2)
+tkr=tkw*tand(pd)
+krsm=tkr-karri
+kasm=(kwsm^2+krsm^2)^0.5
+pfsm=kwsm/kasm
+if krsm<0 then
+ ch=char('capacitor')
+ ich=char('leading')
+else
+ ch=char('inductive')
+ ich=char('lagging')
+end
+printf(" overall power factor angle %.2fkw \n total kvar %.2fkvar \n kvar of synchrounous motor %.2fkvar %c \n kva of synchrounous motor %.2fkva \n power factor of synchrounous motor %.2f %c",pd,tkr,krsm,ch,kasm,pfsm,ich)
diff --git a/416/CH4/EX4.11/exp4_11cpp.txt b/416/CH4/EX4.11/exp4_11cpp.txt
new file mode 100755
index 000000000..0bdbe8222
--- /dev/null
+++ b/416/CH4/EX4.11/exp4_11cpp.txt
@@ -0,0 +1,12 @@
+
+ example 4 11
+ kw rating of installation 27.7kW
+ kVA rating of installation 34.64kva
+ kVAR rating 20.78kvar
+ kw input to synchrounous motor 20.43kw
+ total kw=48.14
+ overall power factor angle 18.19kw
+ total kvar 15.82kvar
+ kvar of synchrounous motor -4.96kvar c
+ kva of synchrounous motor 21.02kva
+ power factor of synchrounous motor 0.97 l \ No newline at end of file
diff --git a/416/CH4/EX4.12/ans4_12.txt b/416/CH4/EX4.12/ans4_12.txt
new file mode 100755
index 000000000..865e4d722
--- /dev/null
+++ b/416/CH4/EX4.12/ans4_12.txt
@@ -0,0 +1,20 @@
+
+ example 4 12
+
+ (a)
+ total current 433.01 -286jA
+ overall power factor 0.834 lagging
+ copper losses in synchrounous motor 6250W
+ copper losses in cable 24.25KW
+ (b)
+ total current 433.01 -178jA
+ overall power factor 0.925 lagging
+ copper losses in synchrounous motor 6250W
+ copper losses in cable 19.73KW
+ (c)
+ total current 433.01 -94jA
+ overall power factor 0.977 lagging
+ copper losses in synchrounous motor 6250W
+ copper losses in cable 17.67KW
+ (d)
+copper loss of synchronous motor this is evidently minimum when tand=0 cosd=1 \ No newline at end of file
diff --git a/416/CH4/EX4.12/example4_12.sce b/416/CH4/EX4.12/example4_12.sce
new file mode 100755
index 000000000..3448d7535
--- /dev/null
+++ b/416/CH4/EX4.12/example4_12.sce
@@ -0,0 +1,27 @@
+clc
+clear
+disp("example 4 12")
+psm=100 //power of synchrounous motors
+pim=200 //power of inducion motor
+v=400 //voltage
+pff=0.71;pp=-1//power factor
+rsm=0.1 //resistance of synchrounous motor
+rt=0.03 //resistance of cable
+pf(1)=1;p(1)=1 //power factor in a
+pf(2)=0.8;p(2)=1 //power factor in b
+pf(3)=0.6;p(3)=1 //power factor in c
+i1=pim*1000/(v*pff*sqrt(3))
+i11=i1*(complex(pff,pp*sind(acosd(pff))))
+i2f=psm*1000/(v*sqrt(3))
+ch=['a' 'b' 'c']
+for i=1:3
+ printf("\n (%c)",ch(i))
+ d=acosd(pf(i))
+ it(i)=i11(1)+complex(i2f,(p(i)*i2f*tand(d)))
+ opf(i)=cosd(atand(imag(it(i))/real(it(i))))
+ clsm=3*((i2f)^2)*rsm
+ clt=3*(abs(it(i))^2)*rt/1000
+ printf("\n total current %.2f %.fjA \n overall power factor %.3f lagging \n copper losses in synchrounous motor %.fW \n copper losses in cable %.2fKW",it(i),imag(it(i)),opf(i),clsm,clt)
+end
+disp("(d)")
+printf("copper loss of synchronous motor this is evidently minimum when tand=%d cosd=%d",0,1) \ No newline at end of file
diff --git a/416/CH4/EX4.13/exp4_13cpp.sce b/416/CH4/EX4.13/exp4_13cpp.sce
new file mode 100755
index 000000000..b2c45adbf
--- /dev/null
+++ b/416/CH4/EX4.13/exp4_13cpp.sce
@@ -0,0 +1,22 @@
+clc
+clear
+disp('example 4 13')
+p=2//constant output in MW
+pf=0.9//power factor
+pa=10//load
+pb=5
+pfb=0.8//power factor at load of 5MW
+td=tand(acosd(pf))
+go=p*(1-td*%i)
+op=0.8
+tp=tand(acosd(pfb))
+printf("power factor of indection generator is leading therefor induction generator output %d%.2fiMVA /n (a) \n",real(go),imag(go))
+tl=pa*(1+tp*%i)
+sg=tl-go
+da=atand(imag(sg)/real(sg))
+printf(" total load %d+%.1fiMW \n synchronous generator load %d+%.3fiMW \n\t\t=%.2fMW at angle %.2f \n power factor of synchronous generator is %.2flagging",real(tl),imag(tl),real(sg),imag(sg),abs(sg),da,cosd(da))
+tl1=pb*(1+tp*%i)
+sg1=tl1-go
+da1=atand(imag(sg1)/real(sg1))
+disp("(b)")
+printf(" total load %d+%.1fiMW \n synchronous generator load %d+%.3fiMW \n\t\t=%.2fMW at angle %.2f \n power factor of synchronous generator is %.2flagging",real(tl1),imag(tl1),real(sg1),imag(sg1),abs(sg1),da1,cosd(da1))
diff --git a/416/CH4/EX4.13/exp4_13cpp.txt b/416/CH4/EX4.13/exp4_13cpp.txt
new file mode 100755
index 000000000..c95521532
--- /dev/null
+++ b/416/CH4/EX4.13/exp4_13cpp.txt
@@ -0,0 +1,12 @@
+
+ example 4 13
+power factor of indection generator is leading therefor induction generator output 2-0.97iMVA /n (a)
+ total load 10+7.5iMW
+ synchronous generator load 8+8.469iMW
+ =11.65MW at angle 46.63
+ power factor of synchronous generator is 0.69lagging
+ (b)
+ total load 5+3.7iMW
+ synchronous generator load 3+4.719iMW
+ =5.59MW at angle 57.55
+ power factor of synchronous generator is 0.54lagging \ No newline at end of file
diff --git a/416/CH4/EX4.14/exp4_14pp.sce b/416/CH4/EX4.14/exp4_14pp.sce
new file mode 100755
index 000000000..4128f9901
--- /dev/null
+++ b/416/CH4/EX4.14/exp4_14pp.sce
@@ -0,0 +1,25 @@
+clc
+clear
+disp("example 4 14")
+c=40*10^(-6) //bank of capacitors in farads
+v=400 //line voltage
+i=40///line current
+pf=0.8//power factor
+f=50//line frequency
+xc=1/(2*%pi*f*c)
+ic=v/(sqrt(3)*xc)
+il=i*(pf-sind(acosd(pf))*%i)
+til=il+%i*ic
+od=atand(imag(til)/real(til))
+opf=cosd(od)
+nlol=(abs(od)/i)^2
+disp("(a)")
+printf(" line current of capacitor bank %.1fA \n load current %d%diA \n total line current %d%.1fjA \n overall p.f %.3f \n new line loss to old line loss %.3f",ic,real(il),imag(il),real(til),imag(til),opf,nlol)
+pcb=(v/xc)
+printf("\n phase current of capacitor bank %.3fA",pcb)
+lcb=pcb*sqrt(3)
+printf("\n line current of capacitor bank %.1fA",lcb)
+tcu=il+lcb*%i
+printf("\n total current %d%.1fjA =%.2fA at an angle %.2f",tcu,imag(tcu),abs(tcu),atand(imag(tcu)/real(tcu)))
+pf2=cosd(atand(imag(tcu)/real(tcu)))
+printf("\n power factor %.1f \n ratio of new line loss to original loss %.3f",pf2,(abs(tcu)/i)^2)
diff --git a/416/CH4/EX4.14/exp4_14pp.txt b/416/CH4/EX4.14/exp4_14pp.txt
new file mode 100755
index 000000000..ad12c4441
--- /dev/null
+++ b/416/CH4/EX4.14/exp4_14pp.txt
@@ -0,0 +1,14 @@
+
+ example 4 14
+
+ (a)
+ line current of capacitor bank 2.9A
+ load current 32-24iA
+ total line current 32-21.1jA
+ overall p.f 0.835
+ new line loss to old line loss 0.697
+ phase current of capacitor bank 5.027A
+ line current of capacitor bank 8.7A
+ total current 32-15.3jA =35.47A at an angle -25.54
+ power factor 0.9
+ ratio of new line loss to original loss 0.786 \ No newline at end of file
diff --git a/416/CH4/EX4.15/exp4_15c.sce b/416/CH4/EX4.15/exp4_15c.sce
new file mode 100755
index 000000000..e1fc15296
--- /dev/null
+++ b/416/CH4/EX4.15/exp4_15c.sce
@@ -0,0 +1,15 @@
+clc
+clear
+disp("example 4 15")
+p=30 //b.h.p of induction motor
+f=50//line frequency
+v=400//line voltage
+e=0.85//effiency
+pf=0.8 //power factor
+i=p*746/(v*e*pf*sqrt(3))
+i=i*complex(pf,-sind(acosd(pf)))
+ccb=imag(i)/sqrt(3)
+xc=v/ccb
+c=10^6/(2*f*%pi*xc)
+prl=((abs(i)^2-real(i)^2)/abs(i)^2)*100
+printf(" current drawn by motor is %.1fA \n the line loss will be minimum when i is munimum.the minimum value of i is %dA and occurs when the capacitor bank draws a line current of %djA \n capacitor C %.2fuf \n percentage loss reduction %d",abs(i),i,imag(i),abs(c),prl)
diff --git a/416/CH4/EX4.15/exp4_15c.txt b/416/CH4/EX4.15/exp4_15c.txt
new file mode 100755
index 000000000..585a3d952
--- /dev/null
+++ b/416/CH4/EX4.15/exp4_15c.txt
@@ -0,0 +1,6 @@
+
+ example 4 15
+ current drawn by motor is 47.5A
+ the line loss will be minimum when i is munimum.the minimum value of i is 38A and occurs when the capacitor bank draws a line current of -28jA
+ capacitor C 130.95uf
+ percentage loss reduction 36 \ No newline at end of file
diff --git a/416/CH4/EX4.16/exp4_16pp.sce b/416/CH4/EX4.16/exp4_16pp.sce
new file mode 100755
index 000000000..3071a5950
--- /dev/null
+++ b/416/CH4/EX4.16/exp4_16pp.sce
@@ -0,0 +1,34 @@
+clc
+clear
+disp("example 4 16")
+po=666.66 //power
+f=50 //frequency
+v=400 //voltage
+pf=0.8 ;p=-1//power factor
+pf2=0.95;p2=-1//improved power factor
+vc=2200 //capacitor voltage
+rc=vc
+il=po*1000/(v*pf*sqrt(3))
+il1=il*(complex(pf,p*sind(acosd(pf))))
+i2c=il*pf
+tad=tand(acosd(pf2))
+i2=complex(i2c,i2c*tad*p2)
+printf(" load current i1 %.2f%.2fA \n load current current on improved power factor %.2f%.2fjA",il1,imag(il1),i2,imag(i2))
+disp("(a)")
+ic=abs(il1-i2)
+ilc=ic*v/vc
+pic=ilc/sqrt(3)
+xc=vc/pic
+ca=10^6/(2*%pi*f*xc)
+printf(" line current of %dV capacitor bank %.2fA\n line current of %d capacitor bank %.2fA \n phase current of capacitor bank %.2fA \n reactance %.2f \n capacitance %.2fF*10^(-6)",v,ic,vc,ilc,pic,xc,ca)
+disp("(b)")
+kr=3*vc*pic/1000
+printf(" kVA rating %.1fkVA \n kVA rating of transformer to convert %dV to %dV will be the same as the kVA rating of capacitor bank",kr,v,vc)
+pl=100*(abs(il1)^2-abs(i2)^2)/abs(il1)^2
+printf("percentage reduction in losses %d percent",pl)
+disp("(d)")
+pi=ic/sqrt(3)
+xcc=v/pi
+cc=1*10^6/(2*%pi*f*xcc)
+roc=ca/cc
+printf(" phase current %.1fA \n reactance %.2fohm \n capasitance %.2f*10^-6F \n ratio of capacitance %.3f",pi,xcc,cc,roc) \ No newline at end of file
diff --git a/416/CH4/EX4.16/exp4_16pp.txt b/416/CH4/EX4.16/exp4_16pp.txt
new file mode 100755
index 000000000..8f1c9e5c7
--- /dev/null
+++ b/416/CH4/EX4.16/exp4_16pp.txt
@@ -0,0 +1,18 @@
+
+ example 4 16
+ load current i1 962.24-721.68A
+ load current current on improved power factor 962.24-316.27jA
+ (a)
+ line current of 400V capacitor bank 405.41A
+ line current of 2200 capacitor bank 73.71A
+ phase current of capacitor bank 42.56A
+ reactance 51.70
+ capacitance 61.57F*10^(-6)
+ (b)
+ kVA rating 280.9kVA
+ kVA rating of transformer to convert 400V to 2200V will be the same as the kVA rating of capacitor bankpercentage reduction in losses 29 percent
+ (d)
+ phase current 234.1A
+ reactance 1.71ohm
+ capasitance 1862.61*10^-6F
+ ratio of capacitance 0.033 \ No newline at end of file
diff --git a/416/CH4/EX4.17/exp4_17c.sce b/416/CH4/EX4.17/exp4_17c.sce
new file mode 100755
index 000000000..11e13b4cc
--- /dev/null
+++ b/416/CH4/EX4.17/exp4_17c.sce
@@ -0,0 +1,10 @@
+clc
+clear
+disp("example 4 17")
+v1=132//line voltage at primary
+v2=11//line voltage at secondary
+p=10 //power
+pf=0.8 //power factor
+mva=p*(complex(pf,sind(acosd(pf))))
+printf(" MVA rating of secondary = %dMVA =%d+%djMVA \n ",p,mva,imag(mva))
+printf("\n since the power factor at primary terminals is unity,rating of primary need be %dMVA only \n the tertiary will supply capacitor curren.since p.f is to be raised to 1 ,the mav compensation needed is 6MVA so rating of teritiary is %dMVA",mva,imag(mva)) \ No newline at end of file
diff --git a/416/CH4/EX4.17/exp4_17c.txt b/416/CH4/EX4.17/exp4_17c.txt
new file mode 100755
index 000000000..29cfdcb66
--- /dev/null
+++ b/416/CH4/EX4.17/exp4_17c.txt
@@ -0,0 +1,6 @@
+
+ example 4 17
+ MVA rating of secondary = 10MVA =8+6jMVA
+
+ since the power factor at primary terminals is unity,rating of primary need be 8MVA only
+ the tertiary will supply capacitor curren.since p.f is to be raised to 1 ,the mav compensation needed is 6MVA so rating of teritiary is 6MVA \ No newline at end of file
diff --git a/416/CH4/EX4.18/exp4_18cpp.sce b/416/CH4/EX4.18/exp4_18cpp.sce
new file mode 100755
index 000000000..4679827c3
--- /dev/null
+++ b/416/CH4/EX4.18/exp4_18cpp.sce
@@ -0,0 +1,18 @@
+clc
+clear
+disp("example 4 18")
+v=11 //line voltage
+f=50//line frequency
+l=400 //load of alternator
+pf=0.8 //power factor
+e=0.85//efficiency
+p=l/pf
+lo=l+p*sind(acosd(pf))*%i
+disp("a")
+printf("when pf is rased to 1 the alternator can supply %dkW for the same value of armture current hence it can supply %dKW to synchronous motor",p,p-l)
+disp("b")
+printf("b.h.p =%.2fHP",100*e/0.746)
+kvam=p-lo
+td=atand(imag(kvam)/real(kvam))
+pff=cosd(td)
+printf("\ncosd=%.3fleading",pff) \ No newline at end of file
diff --git a/416/CH4/EX4.18/exp4_18cpp.txt b/416/CH4/EX4.18/exp4_18cpp.txt
new file mode 100755
index 000000000..733c6370e
--- /dev/null
+++ b/416/CH4/EX4.18/exp4_18cpp.txt
@@ -0,0 +1,8 @@
+
+ example 4 18
+
+ a
+when pf is rased to 1 the alternator can supply 500kW for the same value of armture current hence it can supply 100KW to synchronous motor
+ b
+b.h.p =113.94HP
+cosd=0.316leading \ No newline at end of file
diff --git a/416/CH4/EX4.19/exp4_19c.sce b/416/CH4/EX4.19/exp4_19c.sce
new file mode 100755
index 000000000..a324e87da
--- /dev/null
+++ b/416/CH4/EX4.19/exp4_19c.sce
@@ -0,0 +1,15 @@
+clc
+clear
+kw=100 //let kw=100kw
+pf=0.6 //power foctor
+pf2=0.8 //power factor
+kvar=kw*tand(acosd(pf))
+kvar2=kw*tand(acosd(pf2))
+ckar=((kvar-kvar2))/10
+ck=round(ckar)*10
+disp("example 4 19")
+printf("capacitor kVAR required for %dkW\n load for same power factor improvement %dKVAR",round(ckar),ck)
+pff=0.95:-0.05:0.4
+pff=200*pff
+n=size(pff)
+z=zeros(1,n(2))
diff --git a/416/CH4/EX4.19/exp4_19c.txt b/416/CH4/EX4.19/exp4_19c.txt
new file mode 100755
index 000000000..19bdb98b0
--- /dev/null
+++ b/416/CH4/EX4.19/exp4_19c.txt
@@ -0,0 +1,4 @@
+
+ example 4 19
+capacitor kVAR required for 6kW
+ load for same power factor improvement 60KVAR \ No newline at end of file
diff --git a/416/CH4/EX4.2/exp4_2c.sce b/416/CH4/EX4.2/exp4_2c.sce
new file mode 100755
index 000000000..9fefa66c3
--- /dev/null
+++ b/416/CH4/EX4.2/exp4_2c.sce
@@ -0,0 +1,12 @@
+clc
+clear
+disp('example 4 2')
+l=100;//connected load
+md=80;//maximum demand
+wt=0.6; //working time
+c=6000; //constant cost
+t=700; //cost on per kW
+re=1.8;//rate
+ec=l*wt*8760//electricity consumption per year
+teb=c+md*t+re*ec //total electricity bill per year
+printf(" energy consumption %dkWh \n total electricity bill per year Rs%d",ec,teb) \ No newline at end of file
diff --git a/416/CH4/EX4.2/exp4_2c.txt b/416/CH4/EX4.2/exp4_2c.txt
new file mode 100755
index 000000000..de797234a
--- /dev/null
+++ b/416/CH4/EX4.2/exp4_2c.txt
@@ -0,0 +1,4 @@
+
+ example 4 2
+ energy consumption 525600kWh
+ total electricity bill per year Rs1008080 \ No newline at end of file
diff --git a/416/CH4/EX4.20/ans4_20.txt b/416/CH4/EX4.20/ans4_20.txt
new file mode 100755
index 000000000..4e4a9f6a9
--- /dev/null
+++ b/416/CH4/EX4.20/ans4_20.txt
@@ -0,0 +1,4 @@
+example 4 20
+ required capacitor kVAR 54KVAR
+ overall power factor 0.75
+ it is seen that point d is on 0.75 line \ No newline at end of file
diff --git a/416/CH4/EX4.20/example4_20.sce b/416/CH4/EX4.20/example4_20.sce
new file mode 100755
index 000000000..4dbf62235
--- /dev/null
+++ b/416/CH4/EX4.20/example4_20.sce
@@ -0,0 +1,10 @@
+clc
+clear
+disp("example 4 20")
+p=160 //kva for transformer
+pf=0.6 //power factor
+el=96 //effective load
+eli=120 //effective load increase
+rc=eli*(tand(acosd(pf))-tand(acosd(eli/p)))
+opf=eli/p
+printf(" required capacitor kVAR %dKVAR \n overall power factor %.2f \n it is seen that point d is on %.2f line",rc,opf,opf) \ No newline at end of file
diff --git a/416/CH4/EX4.21/ans4_21.txt b/416/CH4/EX4.21/ans4_21.txt
new file mode 100755
index 000000000..d57cfa1f7
--- /dev/null
+++ b/416/CH4/EX4.21/ans4_21.txt
@@ -0,0 +1,12 @@
+
+ example 4 21
+ initial kVA 1131.54kVA
+ initial annual fixed charges Rs90523.2
+ after installation of synchronous motor reactive power of induction motor 800kVars
+ active power input of synchrounous motor 148.59kW
+ reactive power input to synchrounous motor -89.15KVAR
+ total kW 948.59KW
+ total kVars 710.85kVARS
+ total kVA 1185.38kVA
+ increase in KVA demand 53.84kVA
+ increase in annual fixed charges Rs4306.9 \ No newline at end of file
diff --git a/416/CH4/EX4.21/example4_21.sce b/416/CH4/EX4.21/example4_21.sce
new file mode 100755
index 000000000..b33dad1b7
--- /dev/null
+++ b/416/CH4/EX4.21/example4_21.sce
@@ -0,0 +1,20 @@
+clc
+clear
+disp("example 4 21")
+md=800 //maximum demand
+pf=0.707 //power factor
+c=80 //cost
+p=200 //power
+e=0.99//efficiency
+pff=0.8 //fulload pf
+ikva=md/pf
+iafc=(round(ikva*100)*(c)/100)
+rsm=ikva*pf
+act=p*(0.7355)/e
+at=-act*sind(acosd(pff))
+tkw=rsm+act
+tkvr=rsm+at
+tkva=(tkw^2+tkvr^2)^0.5
+ikvad=tkva-ikva
+infc=ikvad*c
+printf(" initial kVA %.2fkVA \n initial annual fixed charges Rs%.1f \n after installation of synchronous motor reactive power of induction motor %dkVars\n active power input of synchrounous motor %.2fkW\n reactive power input to synchrounous motor %.2fKVAR \n total kW %.2fKW \n total kVars %.2fkVARS \n total kVA %.2fkVA \n increase in KVA demand %.2fkVA\n increase in annual fixed charges Rs%.1f ",ikva,iafc,rsm,act,at,tkw,tkvr,tkva,ikvad,infc)
diff --git a/416/CH4/EX4.22/exp4_22cpp.sce b/416/CH4/EX4.22/exp4_22cpp.sce
new file mode 100755
index 000000000..dcd5b91fa
--- /dev/null
+++ b/416/CH4/EX4.22/exp4_22cpp.sce
@@ -0,0 +1,30 @@
+clc
+clear
+disp("example 4 22")
+t=16//working time
+d=300 //working days
+hv=1;hvmd=50 //tariff on high voltage
+lv=1.1;lvmd=60 //tariff on low voltage
+al=250//avarage load
+pf=0.8//power factor
+md=300 //maximum demand
+hvec=500//cost of hv equipment
+l=0.05 //loss of hv equipment
+id=0.12 //interest and deprecistion
+ter=al*md*t
+mdv=md/pf
+printf(" total energy requirement %2.2ekWH \n maximum demand %dKVA",ter,mdv)
+disp("(a)HV supply")
+chv=mdv*hvec
+idc=chv*id
+ere=ter/(1-l)
+dch=mdv*hvmd
+ech=round(ere*hv/1000)*1000
+tanc=ech+dch+idc
+printf(" cost of HV equipment Rs%e\n interest and depreciation charges Rs%d \n energy received %ekWh\n demand charges Rs%d \n energy charges Rs%2e \n total annual cost Rs%d",chv,idc,ere,dch,ech,tanc)
+disp("(b) LV supply")
+lvdc=mdv*lvmd
+lvec=ter*lv
+lvtac=lvec+lvdc
+lvdac=lvtac-tanc
+printf(" demand charges Rs%d \n energy charges Rs%2.e \n total annual cost Rs%d \n difference in annual cost Rs%d",lvdc,lvec,lvtac,lvdac) \ No newline at end of file
diff --git a/416/CH4/EX4.22/exp4_22cpp.txt b/416/CH4/EX4.22/exp4_22cpp.txt
new file mode 100755
index 000000000..80b10d514
--- /dev/null
+++ b/416/CH4/EX4.22/exp4_22cpp.txt
@@ -0,0 +1,16 @@
+
+ example 4 22
+ total energy requirement 1.20e+006kWH
+ maximum demand 375KVA
+ (a)HV supply
+ cost of HV equipment Rs1.875000e+005
+ interest and depreciation charges Rs22500
+ energy received 1.263158e+006kWh
+ demand charges Rs18750
+ energy charges Rs1.263000e+006
+ total annual cost Rs1304250
+ (b) LV supply
+ demand charges Rs22500
+ energy charges Rs1e+006
+ total annual cost Rs1342500
+ difference in annual cost Rs38250 \ No newline at end of file
diff --git a/416/CH4/EX4.3/exp4_3pp.sce b/416/CH4/EX4.3/exp4_3pp.sce
new file mode 100755
index 000000000..375f5009d
--- /dev/null
+++ b/416/CH4/EX4.3/exp4_3pp.sce
@@ -0,0 +1,40 @@
+clc
+clear
+disp('example 4 3')
+md=160;lff=0.7;dfc=1.7//maximum demand //load factor//diversity factor bt consumers
+ic=200;//installed capacity
+ccp=30000//capital cost of plant per kW
+ctds=1800*10^6 //capital cost of transmission and distribution
+idi=0.11 //interest,depreciation insurance and taxes on capital investiment
+fmc=30*10^6 //fixed managerial and general maintanance cost
+ol=236*10^6 //operating labour,maintanance and suppies
+cm=90*10^6 //cost of metering,billing and collection
+eca=0.05 //energy consumed by auxillary
+el=0.15//energy loss and maintanance
+p=0.25
+lf=0.8//load factor
+ap=0.5 //addition energy for profit
+disp('a')
+printf(" capital cost of plant Rs%e \n total capital cost Rs%e\n interest,depereiation system Rs%e ",ccp*ic*10^3,ccp*ic*10^3+ctds,(ccp*ic*10^3+ctds)*idi)
+printf("\n sum of maximum demand of consumers energy prodused %dMW \n energy produced %ekWh \n energy consumed by auxilliries %ekWh\n energy output %ekWH \n energy sold to consumer %ekWh\n",md*dfc,md*8760*lff*10^3,md*8760*lff*eca*10^3,md*8760*lff*10^3*(1-eca),md*8760*lff*10^3*(1-eca)*(1-el))
+disp('(b)fixed cost')
+idetc=(ccp*ic*10^3+ctds)*idi
+tot=idetc+fmc;
+printf(" interest, deprecition etc Rs%e per year\n managerial and maintence Rs%.eper year \n total \t Rs%e ",idetc,fmc,tot)
+pro=p*tot
+gtot=tot+pro
+printf("\n profit@%d \tRs%eper year \n grand total Rs%e per year",p*100,pro,gtot)
+disp('Operating cost')
+tot2=ol+cm
+pro2=tot2*p
+gtot2=tot2+pro2
+printf(" Operating labour,supplies maintenance etc Rs.%eper year \n metering,billing etc Rs%eper year\n total\t\tRs%e per year\n profit \t Rs%eper year \n grand total \t Rs%e per year",ol,cm,tot2,pro2,gtot2)
+disp('tariff')
+co=gtot/(md*dfc*1000)
+es=md*8760*lff*10^3*(1-eca)*(1-el)
+cs=gtot2/es
+printf(" cost per kW \tRs%e \n cost per kWh \tRs%e",co,cs)
+disp('(b)')
+ep=md*1000*8760*lf
+printf(" energy produced %ekWh \n energy consumed by auxiliaries %ekWh/year \n energy output of plant %ekWh \n energy sold to consumer %ekWh",ep,ep*eca,ep*(1-eca),ep*(1-eca)*(1-el))
+estc=ep*(1-eca)*(1-el)
diff --git a/416/CH4/EX4.3/exp4_3pp.txt b/416/CH4/EX4.3/exp4_3pp.txt
new file mode 100755
index 000000000..df643c719
--- /dev/null
+++ b/416/CH4/EX4.3/exp4_3pp.txt
@@ -0,0 +1,33 @@
+
+ example 4 3
+
+ (a)
+ capital cost of plant Rs6.000000e+009
+ total capital cost Rs7.800000e+009
+ interest,depereiation system Rs8.580000e+008
+ sum of maximum demand of consumers energy prodused 272MW
+ energy produced 9.811200e+008kWh
+ energy consumed by auxilliries 4.905600e+007kWh
+ energy output 9.320640e+008kWH
+ energy sold to consumer 7.922544e+008kWh
+
+ (b)fixed cost
+ interest, deprecition etc Rs8.580000e+008 per year
+ managerial and maintence Rs3e+007per year
+ total Rs8.880000e+008
+ profit@25 Rs2.220000e+008per year
+ grand total Rs1.110000e+009 per year
+ Operating cost
+ Operating labour,supplies maintenance etc Rs.2.360000e+008per year
+ metering,billing etc Rs9.000000e+007per year
+ total Rs3.260000e+008 per year
+ profit Rs8.150000e+007per year
+ grand total Rs4.075000e+008 per year
+ tariff
+ cost per kW Rs4.080882e+003
+ cost per kWh Rs5.143550e-001
+ (b)
+ energy produced 1.121280e+009kWh
+ energy consumed by auxiliaries 5.606400e+007kWh/year
+ energy output of plant 1.065216e+009kWh
+ energy sold to consumer 9.054336e+008kWh \ No newline at end of file
diff --git a/416/CH4/EX4.4/ans4_4.txt b/416/CH4/EX4.4/ans4_4.txt
new file mode 100755
index 000000000..ccf131094
--- /dev/null
+++ b/416/CH4/EX4.4/ans4_4.txt
@@ -0,0 +1,8 @@
+
+ example 4 4
+ energy corresponding to maximum demand 552kWh
+ cost of above energy Rs1932
+ remaining energy 1468kWh
+ cost of reamaining energy Rs2642.4
+ total monthly bill Rs.4574.4
+ avarage tariff Rs2.265per kWh \ No newline at end of file
diff --git a/416/CH4/EX4.4/example4_4.sce b/416/CH4/EX4.4/example4_4.sce
new file mode 100755
index 000000000..2aedc306b
--- /dev/null
+++ b/416/CH4/EX4.4/example4_4.sce
@@ -0,0 +1,12 @@
+clc
+clear
+disp('example 4 4')
+v=230;ec=2020;//voltage //energy consumption
+i=40;pf=1;t=2;c=3.5;rc=1.8;mon=30;//current/power factor/time/cost/reamining cost/month
+ecd=v*i*pf*t*mon/1000 //energy corresponding to maximum demand
+cost=ecd*c
+ren=ec-ecd
+rcost=ren*rc
+tmb=cost+rcost
+at=tmb/ec
+printf(" energy corresponding to maximum demand %dkWh \n cost of above energy Rs%d \n remaining energy %dkWh \n cost of reamaining energy Rs%.1f \n total monthly bill Rs.%.1f\n avarage tariff Rs%.3fper kWh",ecd,cost,ren,rcost,tmb,at)
diff --git a/416/CH4/EX4.5/exp4_5c.sce b/416/CH4/EX4.5/exp4_5c.sce
new file mode 100755
index 000000000..34be7b2ac
--- /dev/null
+++ b/416/CH4/EX4.5/exp4_5c.sce
@@ -0,0 +1,7 @@
+clc
+clear
+disp('example 4 5')
+t1=3000;t11=0.9 //cost equation
+t2=3; //rate
+x=t1/(t2-t11)
+printf("if energy consumption per month is more than %.1fkWh,\ntariff is more suitable",x)
diff --git a/416/CH4/EX4.5/exp4_5c.txt b/416/CH4/EX4.5/exp4_5c.txt
new file mode 100755
index 000000000..5f5e4fc80
--- /dev/null
+++ b/416/CH4/EX4.5/exp4_5c.txt
@@ -0,0 +1,5 @@
+
+
+ example 4 5
+if energy consumption per month is more than 1428.6kWh,
+tariff is more suitable \ No newline at end of file
diff --git a/416/CH4/EX4.6/exp4_6c.sce b/416/CH4/EX4.6/exp4_6c.sce
new file mode 100755
index 000000000..8632855f8
--- /dev/null
+++ b/416/CH4/EX4.6/exp4_6c.sce
@@ -0,0 +1,24 @@
+clc
+clear
+disp("example 4 6")
+aec=201500 //annual energy consumption
+lf=0.35//load factor constnt
+t=4000//tariff
+tmd=1200//tariff for maximum demand
+t3=2.2
+lfb=0.55 //load factor improved
+ecd=0.25//energy consumption reduced
+md=aec/(8760*lf)
+yb=t+md*tmd+t3*aec
+mdb=aec/(8760*lfb)
+ybb=t+mdb*tmd+t3*aec
+ne=aec*(1-ecd)
+md3=ne/(8760*lf)
+ybc=t+md3*tmd+t3*ne
+aeca=yb/aec
+aecb=ybb/aec
+aecc=ybc/ne
+disp('a')
+printf("maximum demand %.2fkW \n yearly bill Rs.%d per year \n(b)\n maximum demand %.2fkW \n yearly bill Rs.%dper year",md,yb,mdb,ybb)
+disp("c")
+printf(" new energy %dkWh \n maximum demand %.2fkW \n yearly bill Rs.%dper year \n average energy cost in case a Rs%.4fper kWh \n average energy cost in case b Rs%.3fper kWh\n average energy cost in case c Rs%.3fper kWh ",ne,md3,ybc,aeca,aecb,aecc) \ No newline at end of file
diff --git a/416/CH4/EX4.6/exp4_6c.txt b/416/CH4/EX4.6/exp4_6c.txt
new file mode 100755
index 000000000..7c69dedd4
--- /dev/null
+++ b/416/CH4/EX4.6/exp4_6c.txt
@@ -0,0 +1,16 @@
+
+ example 4 6
+
+ a
+maximum demand 65.72kW
+ yearly bill Rs.526164 per year
+(b)
+ maximum demand 41.82kW
+ yearly bill Rs.497486per year
+ c
+ new energy 151125kWh
+ maximum demand 49.29kW
+ yearly bill Rs.395623per year
+ average energy cost in case a Rs2.6112per kWh
+ average energy cost in case b Rs2.469per kWh
+ average energy cost in case c Rs2.618per kWh \ No newline at end of file
diff --git a/416/CH4/EX4.7/exp4_7c.sce b/416/CH4/EX4.7/exp4_7c.sce
new file mode 100755
index 000000000..59164ed53
--- /dev/null
+++ b/416/CH4/EX4.7/exp4_7c.sce
@@ -0,0 +1,29 @@
+clc
+clear
+disp('example 4 7')
+pl1=20;pf1=0.8;t1=2000//load in MVA //power factor //duration
+pl2=10;pf2=0.8;t2=1000//load in MVA //power factor //duration
+pl3=2;pf3=0.8;t3=500//load in MVA //power factor //duration
+pt=20 ///transformar power rating
+fte=0.985;ste=0.99 ///full load efficiency for first and second transformer
+ftl=120;stl=90 //core loss inKW for first and second transformer
+cst=200000;//cost of second transformer with compared with first transformer
+aid=0.15;//annual interest and depreciation
+ce=0.8 //cost of energy
+tfl=pt*(1-fte)*1000//total full load
+fle=tfl-ftl //full load copper loss
+elc=fle*t1+(fle*t2/(pt/pl2)^2)+(fle*t3/(pt/pl3)^2) //energy loss due to copper loss
+eli=ftl*(t1+t2+t3)//energy loss due to iron loss
+celo=(elc+eli)*ce //cost of energy loss
+disp(" first transformer")
+printf(" total full load losses %dkW \n full load copper losses %dkW \n energy loss due to copper losses %dkWh/year\n energy loss due to iron losses %dkWh/year \n cost of energy losses Rs%dper year",tfl,fle,elc,eli,celo)
+stfl=pt*(1-ste)*1000//total full load
+sle=stfl-stl//full load copper loss
+selc=sle*t1+(sle*t2/(pt/pl2)^2)+(sle*t3/(pt/pl3)^2)//energy loss due to copper loss
+seli=stl*(t1+t2+t3)//energy loss due to iron loss
+scelo=(selc+seli)*ce//cost of energy loss
+disp(" second transformer")
+printf(" total full load losses %dkW \n full load copper losses %dkW \n energy loss due to copper losses %dkWh/year\n energy loss due to iron losses %dkWh/year \n cost of energy losses Rs%dper year",stfl,sle,selc,seli,scelo)
+aidc=stfl*aid*1000
+tybc=aidc+scelo
+printf("additional interest and depreciation due to higher cost of second transformer Rs%d \n total yearly charges for second transformer Rs%d per year",aidc,tybc) \ No newline at end of file
diff --git a/416/CH4/EX4.7/exp4_7c.txt b/416/CH4/EX4.7/exp4_7c.txt
new file mode 100755
index 000000000..6a0c42968
--- /dev/null
+++ b/416/CH4/EX4.7/exp4_7c.txt
@@ -0,0 +1,16 @@
+
+ example 4 7
+
+ first transformer
+ total full load losses 300kW
+ full load copper losses 180kW
+ energy loss due to copper losses 405900kWh/year
+ energy loss due to iron losses 420000kWh/year
+ cost of energy losses Rs660720per year
+ second transformer
+ total full load losses 200kW
+ full load copper losses 110kW
+ energy loss due to copper losses 248050kWh/year
+ energy loss due to iron losses 315000kWh/year
+ cost of energy losses Rs450440per yearadditional interest and depreciation due to higher cost of second transformer Rs30000
+ total yearly charges for second transformer Rs480440 per year \ No newline at end of file
diff --git a/416/CH4/EX4.8/exp4_8c.sce b/416/CH4/EX4.8/exp4_8c.sce
new file mode 100755
index 000000000..5f26bb646
--- /dev/null
+++ b/416/CH4/EX4.8/exp4_8c.sce
@@ -0,0 +1,14 @@
+clc
+clear
+disp('example 4 8')
+p=500 //load
+pf=0.8//power factor
+t=400 //tariff
+md=100 //maximum demand tariff
+ccb=600 //cost of capacitor bank
+id=0.11//interest and deprecistion
+sd=ccb*id/t//sin(ph2)
+d2=asind(sd)
+pf2=cosd(d2)
+kva=p*(tand(acosd(pf))-tand(d2))
+printf(" the most economic power factor %.3f lagging \n kvar requirement %.2fkVAR",pf2,kva) \ No newline at end of file
diff --git a/416/CH4/EX4.8/exp4_8c.txt b/416/CH4/EX4.8/exp4_8c.txt
new file mode 100755
index 000000000..8f528db5a
--- /dev/null
+++ b/416/CH4/EX4.8/exp4_8c.txt
@@ -0,0 +1,4 @@
+
+ example 4 8
+ the most economic power factor 0.986 lagging
+ kvar requirement 291.35kVAR \ No newline at end of file
diff --git a/416/CH4/EX4.9/exp4_9cpp.sce b/416/CH4/EX4.9/exp4_9cpp.sce
new file mode 100755
index 000000000..7828e1caf
--- /dev/null
+++ b/416/CH4/EX4.9/exp4_9cpp.sce
@@ -0,0 +1,16 @@
+clc
+clear
+disp("example 4 9")
+l1=300;//load and power factor for three different loads
+pf1=1;
+l2=1000;
+pf2=0.9;
+l3=1500;
+pf3=0.8
+printf(" for %dkW unit power factor load \n power factor angle %.f\n reactive power %.fkvr",l1,acosd(pf1),l1*(tand(acosd(pf1))))
+printf(" \nfor %dkW unit power factor load \n power factor angle %.2f\n reactive power %.2fkvr",l2,acosd(pf2),l2*(tand(acosd(pf2))))
+printf(" \nfor %dkW unit power factor load \n power factor angle %.2f\n reactive power %.2fkvr",l3,acosd(pf3),l3*(tand(acosd(pf3))))
+tl=l1+l2+l3
+tt=l3*(tand(acosd(pf3)))+l2*(tand(acosd(pf2)))+l1*(tand(acosd(pf1)))
+printf("\n total kW \t%dkW\n total kVAR %.1fkVAR \n total kVA %.2fkVA \n overall power factor %.3flagging",tl,tt,(tl^2+tt^2)^0.5,tl/(tl^2+tt^2)^0.5)
+printf("\n the maximum unity power factor load which yhe station can supply is equal to the kVA i.e.%.2fkVR",(tl^2+tt^2)^0.5) \ No newline at end of file
diff --git a/416/CH4/EX4.9/exp4_9cpp.txt b/416/CH4/EX4.9/exp4_9cpp.txt
new file mode 100755
index 000000000..8df08c323
--- /dev/null
+++ b/416/CH4/EX4.9/exp4_9cpp.txt
@@ -0,0 +1,16 @@
+
+ example 4 9
+ for 300kW unit power factor load
+ power factor angle 0
+ reactive power 0kvr
+for 1000kW unit power factor load
+ power factor angle 25.84
+ reactive power 484.32kvr
+for 1500kW unit power factor load
+ power factor angle 36.87
+ reactive power 1125.00kvr
+ total kW 2800kW
+ total kVAR 1609.3kVAR
+ total kVA 3229.54kVA
+ overall power factor 0.867lagging
+ the maximum unity power factor load which yhe station can supply is equal to the kVA i.e.3229.54kVR \ No newline at end of file
diff --git a/416/CH5/EX5.1/5_1anspp.txt b/416/CH5/EX5.1/5_1anspp.txt
new file mode 100755
index 000000000..c011224fb
--- /dev/null
+++ b/416/CH5/EX5.1/5_1anspp.txt
@@ -0,0 +1,8 @@
+
+ solution of exp 5.1
+depreciation rate 0.024393
+ total fixed rate =0.139393
+annual fixed cost of a is Rs37636089 fuel cost of plan a is Rs18000000 and total cost of a is Rs56095689
+annual fixed cost of b is Rs43908771 fuel cost of plan b is Rs15750000 and total cost of b is Rs60118371
+annual fixed cost of c is Rs50181453 fuel cost of plan c is Rs13500000 and total cost of c is Rs64141053
+annual cost of purchasing electricty from utility is Rs600x25000+0.3x1.0e+008 is Rs45000000 \ No newline at end of file
diff --git a/416/CH5/EX5.1/exp5_1pp.sce b/416/CH5/EX5.1/exp5_1pp.sce
new file mode 100755
index 000000000..15c35a0d3
--- /dev/null
+++ b/416/CH5/EX5.1/exp5_1pp.sce
@@ -0,0 +1,44 @@
+clear
+clc
+disp("solution of exp 5.1")
+aerpe=100*10^6
+md=25*10^3
+function [u]=ucc(dd,e)
+ u=600*dd+0.3*e //rs per kW
+ endfunction
+sc=30*10^3
+
+a.cci=9000//per kW
+a.shr=4000
+b.cci=10500
+b.shr=3500
+c.cci=12000
+c.shr=3000
+salc=3000
+sal=2280
+sh=10
+tax=0.04
+ins=0.5*10^-2
+cir=0.07
+hv=5000//l cal per kg
+fuc=225//rs per ton
+acsnm=150000//for each plan
+pl=20
+dr=cir/((cir+1)^pl-1)
+tfcr=cir+dr+tax+ins
+printf("depreciation rate %f \n total fixed rate =%f",dr,tfcr)
+a.ci=a.cci*sc;b.ci=b.cci*sc;c.ci=c.cci*sc
+a.afca=a.ci*tfcr;b.afca=b.ci*tfcr;c.afca=c.ci*tfcr
+a.afuc=a.shr*fuc*10^8/(hv*10^3)
+b.afuc=b.shr*fuc*10^8/(hv*10^3)
+c.afuc=c.shr*fuc*10^8/(hv*10^3)
+ass=12*(salc+sh*sal)
+tota=a.afca+ass+a.afuc+acsnm
+totb=b.afca+ass+b.afuc+acsnm
+totc=c.afca+ass+c.afuc+acsnm
+ printf("\nannual fixed cost of a is Rs%d fuel cost of plan a is Rs%d and total cost of a is Rs%d",a.afca,a.afuc,tota)
+printf("\nannual fixed cost of b is Rs%d fuel cost of plan b is Rs%d and total cost of b is Rs%d",b.afca,b.afuc,totb)
+printf("\nannual fixed cost of c is Rs%d fuel cost of plan c is Rs%d and total cost of c is Rs%d",c.afca,c.afuc,totc)
+
+ppt=ucc(md,aerpe)
+printf("\nannual cost of purchasing electricty from utility is Rs600x%d+0.3x%.1e is Rs%d",md,aerpe,ppt)
diff --git a/416/CH5/EX5.2/5_2anspp.txt b/416/CH5/EX5.2/5_2anspp.txt
new file mode 100755
index 000000000..f64bf12f8
--- /dev/null
+++ b/416/CH5/EX5.2/5_2anspp.txt
@@ -0,0 +1,33 @@
+
+ example 5.2
+persent of worth factor is 0.094393
+annual cost excludinding interest and
+depreciation of a Rs30609600
+persent worth factor 0.094393
+present worth annual cost of a is Rs324278538
+ investement of a is Rs270000000
+ total persent worth of a is 594278538
+
+ annual cost excludinding interest and
+depreciation of b Rs30384600
+persent wort factor 0.094393
+present worth annual cost of b is Rs321894885
+ investement of b is Rs315000000
+ total persent worth of b is 636894885
+
+annual cost excludinding interest and
+depreciation of c Rs30159600
+persent wort factor 0.094393
+present worth annual cost of c is Rs319511232
+ investement of c is Rs360000000
+ total persent worth of c is 679511232
+
+annual cost excludinding interest and
+depreciation of utility service Rs45000000
+persent wort factor 0.094393
+present worth annual cost of utility service is Rs476730641
+ investement of utility service is nill
+ total persent worth of utility service is 476730641
+
+ since the present worth of the utility service is the minimum,it is the obvious choice
+out of the other plans,plan A is the best since it has the lowest present worth \ No newline at end of file
diff --git a/416/CH5/EX5.2/exp5_2pp.sce b/416/CH5/EX5.2/exp5_2pp.sce
new file mode 100755
index 000000000..7fa5a2dbb
--- /dev/null
+++ b/416/CH5/EX5.2/exp5_2pp.sce
@@ -0,0 +1,47 @@
+clear
+clc
+disp("example 5.2")
+aer=100*10^6
+md=25*10^3
+function [u]=ucc(dd,e)
+ u=600*dd+0.3*e //rs per kW
+ endfunction
+p=30*10^3
+ap=9000//per kW
+ahr=4000
+bp=10500
+bhr=3500
+cp=12000
+chr=3000
+salc=3000
+sal=2280
+sh=10
+t=0.04
+i=0.5*10^-2
+r=0.07
+hv=5000//l cal per kg
+fuc=225//rs per ton
+mc=150000//for each plan
+n=20
+dr=r/((r+1)^n-1)
+pwf=r/(1-(r+1)^(-n))
+printf("persent of worth factor is %f",pwf)
+afc=ahr*fuc*10^8/(hv*10^3)
+bfc=bhr*fuc*10^8/(hv*10^3)
+cfc=chr*fuc*10^8/(hv*10^3)
+ass=12*(salc+sh*sal)
+aaoc=ass+mc+afc
+baoc=ass+mc+bfc
+caoc=ass+mc+cfc
+ai=ap*p;bi=bp*p;ci=cp*p
+atac=(t+i)*ap*p+aaoc
+btac=(i+t)*bp*p+baoc
+ctac=(i+t)*cp*p+caoc
+uts=ucc(md,aer)
+apw=atac/pwf;bpw=btac/pwf;cpw=ctac/pwf;utss=uts/pwf
+ta=apw+ai;tb=bpw+bi;tc=cpw+ci
+printf("\nannual cost excludinding interest and \ndepreciation of a \t\tRs%d \npersent worth factor \t\t %f \npresent worth annual cost of a is Rs%d \n investement of a is \tRs%d \n total persent worth of a is \t%d",atac,pwf,apw,ai,ta)
+printf("\n\n annual cost excludinding interest and \ndepreciation of b \t\tRs%d \npersent wort factor \t\t%f \npresent worth annual cost of b is Rs%d \n investement of b is \tRs%d \n total persent worth of b is \t%d",btac,pwf,bpw,bi,tb)
+printf("\n \nannual cost excludinding interest and \ndepreciation of c \t\tRs%d \npersent wort factor \t\t%f \npresent worth annual cost of c is Rs%d \n investement of c is \tRs%d \n total persent worth of c is \t%d",ctac,pwf,cpw,ci,tc)
+printf("\n \nannual cost excludinding interest and \ndepreciation of utility service \tRs%d \npersent wort factor \t\t\t%f \npresent worth annual cost of utility service is Rs%d \n investement of utility service is \t\t nill \n total persent worth of utility service is %d",uts,pwf,utss,utss)
+printf("\n\n\tsince the present worth of the utility service is the minimum,it is the obvious choice \nout of the other plans,plan A is the best since it has the lowest present worth") \ No newline at end of file
diff --git a/416/CH5/EX5.3/5_3ans.txt b/416/CH5/EX5.3/5_3ans.txt
new file mode 100755
index 000000000..ed977720f
--- /dev/null
+++ b/416/CH5/EX5.3/5_3ans.txt
@@ -0,0 +1,9 @@
+example 5.3
+
+ plan A is Rs.801366999
+ plan B is Rs.858833880
+ planC is Rs.916300760
+utility services is Rs642887142
+ the utility service has the lowest capitalized cost and is the obvious choice. Out of the other pl
+ ans,plan A is the best
+ \ No newline at end of file
diff --git a/416/CH5/EX5.3/exp5_3.sce b/416/CH5/EX5.3/exp5_3.sce
new file mode 100755
index 000000000..b15983c14
--- /dev/null
+++ b/416/CH5/EX5.3/exp5_3.sce
@@ -0,0 +1,41 @@
+clear
+clc
+disp("example 5.3")
+aer=100*10^6 //from example 5.1
+md=25*10^3
+function [u]=ucc(dd,e)
+ u=600*dd+0.3*e //rs per kW
+ endfunction
+p=30*10^3
+ap=9000//per kW
+ahr=4000
+bp=10500
+bhr=3500
+cp=12000
+chr=3000
+salc=3000
+sal=2280
+sh=10
+t=0.04
+i=0.5*10^-2
+r=0.07
+hv=5000//l cal per kg
+fuc=225//rs per ton
+mc=150000//for each plan
+n=20
+dr=r/((r+1)^n-1)
+pwf=r/(1-(r+1)^(-n))
+uts=ucc(md,aer)
+afc=ahr*fuc*10^8/(hv*10^3)
+bfc=bhr*fuc*10^8/(hv*10^3)
+cfc=chr*fuc*10^8/(hv*10^3)
+ass=12*(salc+sh*sal)
+aaoc=ass+mc+afc
+baoc=ass+mc+bfc
+caoc=ass+mc+cfc
+aw=([[dr+t+i]*ap*p+aaoc]/r)+ap*p
+bw=([[dr+t+i]*bp*p+baoc]/r)+bp*p
+cw=([[dr+t+i]*cp*p+caoc]/r)+cp*p
+utt=uts/r+p
+printf("\n plan A is \t\tRs.%d \n plan B is \t\tRs.%d \n planC is \t\tRs.%d \nutility services is \tRs%d",aw,bw,cw,utt)
+disp("the utility service has the lowest capitalized cost and is the obvious choice. Out of the other plans,plan A is the best") \ No newline at end of file
diff --git a/416/CH5/EX5.4/5_4anspp.txt b/416/CH5/EX5.4/5_4anspp.txt
new file mode 100755
index 000000000..8516b010c
--- /dev/null
+++ b/416/CH5/EX5.4/5_4anspp.txt
@@ -0,0 +1,24 @@
+
+ for (a)
+total annual cost Rs.30609600
+investement Rs.270000000
+annuity Rs35390400
+ratio of a and b 0.131076
+rate of return 11.4percent
+ for (b)
+total annual cost Rs.30384600
+investement Rs.315000000
+annuity Rs35615400
+ratio of a and b 0.113065
+rate of return 8.9percent
+ for (c)
+total annual cost Rs.30159600
+investement Rs.360000000
+annuity Rs35840400
+ratio of a and b 0.099557
+rate of return 7.6percent
+saving in annual cost excluding interest and depreciation B over A 225000 C over A 225000
+additional investement P is B over A 45000000 C over A 45000000
+rate of saving to investement AoverB 0.005000 BoverC 0.005000
+rate of return on capital investement
+ evidently plan A is the best A over B Negative B over C Negative \ No newline at end of file
diff --git a/416/CH5/EX5.4/exp5_4pp.sce b/416/CH5/EX5.4/exp5_4pp.sce
new file mode 100755
index 000000000..53c2848f1
--- /dev/null
+++ b/416/CH5/EX5.4/exp5_4pp.sce
@@ -0,0 +1,81 @@
+clear
+clc
+disp("example 5.4")
+aer=100*10^6
+md=25*10^3
+utse=6600*10^4
+p=30*10^3
+ap=9000//per kW
+ahr=4000
+bp=10500
+bhr=3500
+cp=12000
+chr=3000
+salc=3000
+sal=2280
+sh=10
+t=0.04
+i=0.5*10^-2
+r=0.07
+hv=5000//l cal per kg
+fuc=225//rs per ton
+mc=150000//for each plan
+n=20
+dr=r/((r+1)^n-1)
+pwf=r/(1-(r+1)^(-n))
+afc=ahr*fuc*10^8/(hv*10^3)
+bfc=bhr*fuc*10^8/(hv*10^3)
+cfc=chr*fuc*10^8/(hv*10^3)
+ass=12*(salc+sh*sal)
+aaoc=ass+mc+afc
+baoc=ass+mc+bfc
+caoc=ass+mc+cfc
+
+sol.a.totalannualcost=(t+i)*ap*p+aaoc
+sol.b.totalannualcost=(i+t)*bp*p+baoc
+sol.c.totalannualcost=(i+t)*cp*p+caoc
+
+sol.a.pinvestement=ap*p;sol.b.pinvestement=bp*p;sol.c.pinvestement=cp*p
+
+sol.a.annuity=utse-sol.a.totalannualcost;
+sol.b.annuity=utse-sol.b.totalannualcost;
+sol.c.annuity=utse-sol.c.totalannualcost;
+
+sol.a.ratioaandp=sol.a.annuity/sol.a.pinvestement;
+sol.b.ratioaandp=sol.b.annuity/sol.b.pinvestement;
+sol.c.ratioaandp=sol.c.annuity/sol.c.pinvestement;
+function [R]=alt(r)
+ R=abs(r/(1-wr))
+endfunction
+ra=round((sol.a.ratioaandp)*100)
+ rb=round((sol.b.ratioaandp)*100)
+ rc=round((sol.c.ratioaandp)*100)
+for x=-0.12:0.001:-0.07 //for itration
+ wr=(1+x)^n
+ re=alt(x)
+ re=(round(re*100))
+ if re==ra then
+ sol.a.return=(abs(x)*100)
+ end
+ if re==rb then
+ sol.b.return=(abs(x)*100)
+ end
+ if re==rc then
+ sol.c.return=(abs(x)*100)
+ end
+ end
+ disp("for (a)")
+printf("total annual cost Rs.%d\ninvestement Rs.%d\nannuity Rs%d \nratio of a and b %f \nrate of return %.1fpercent",sol.a.totalannualcost,sol.a.pinvestement,sol.a.annuity,sol.a.ratioaandp,sol.a.return)
+disp("for (b)")
+printf("total annual cost Rs.%d\ninvestement Rs.%d\nannuity Rs%d \nratio of a and b %f \nrate of return %.1fpercent",sol.b.totalannualcost,sol.b.pinvestement,sol.b.annuity,sol.b.ratioaandp,sol.b.return)
+disp("for (c)")
+printf("total annual cost Rs.%d\ninvestement Rs.%d\nannuity Rs%d \nratio of a and b %f \nrate of return %.1fpercent",sol.c.totalannualcost,sol.c.pinvestement,sol.c.annuity,sol.c.ratioaandp,sol.c.return)
+sb=sol.b.annuity-sol.a.annuity
+sc=sol.c.annuity-sol.b.annuity
+ib=sol.b.pinvestement-sol.a.pinvestement
+ic=sol.b.pinvestement-sol.a.pinvestement
+rcb=sb/ib;rcc=sc/ic;
+printf("\nsaving in annual cost excluding interest and depreciation B over A \t %d C over A \t %d",sb,sc)
+printf("\nadditional investement P is \t\t\t\tB over A \t %d C over A \t %d",ib,ic)
+printf("\nrate of saving to investement \t\t\t\tAoverB \t\t %f BoverC \t%f",rcb,rcc)
+printf("\nrate of return on capital investement\n evidently plan A is the best \t\t\t\tA over B \tNegative B over C \tNegative") \ No newline at end of file
diff --git a/416/CH7/EX7.1/7_1ans.txt b/416/CH7/EX7.1/7_1ans.txt
new file mode 100755
index 000000000..949c98428
--- /dev/null
+++ b/416/CH7/EX7.1/7_1ans.txt
@@ -0,0 +1,6 @@
+
+ exanple7.1
+energy output in 1 hour is 3.600000e+011Watt.sec
+energy input in one hour is 1.304348e+012joules Watt.sec
+ energy input in 1 hour is 3.117391e+008kcal.
+ coal required is 48709.239kg per hour \ No newline at end of file
diff --git a/416/CH7/EX7.1/exp7_1.sce b/416/CH7/EX7.1/exp7_1.sce
new file mode 100755
index 000000000..015bb67c2
--- /dev/null
+++ b/416/CH7/EX7.1/exp7_1.sce
@@ -0,0 +1,16 @@
+clear
+clc
+disp("exanple7.1")
+pow=100*10^6
+calv=6400
+threff=0.3
+elceff=0.92
+kcal=0.239*10^-3
+eo=pow*3600
+ei=eo/(threff*elceff)
+eikc=ei*kcal
+colreq=eikc/6400
+printf("energy output in 1 hour is %eWatt.sec ",eo);
+printf("\nenergy input in one hour is %ejoules Watt.sec\n",ei)
+printf(" energy input in 1 hour is %ekcal.",eikc);
+printf("\n coal required is %.3fkg per hour",colreq);
diff --git a/416/CH8/EX8.1/exp8_1c.sce b/416/CH8/EX8.1/exp8_1c.sce
new file mode 100755
index 000000000..e0e584f90
--- /dev/null
+++ b/416/CH8/EX8.1/exp8_1c.sce
@@ -0,0 +1,8 @@
+clear
+clc
+disp("example 8.1")
+h=100 //given height
+q=200 //discharge
+e=0.9 //efficiency
+p=(735.5/75)*q*h*e
+printf("\npower developed by hydro plant is %ekW",p) \ No newline at end of file
diff --git a/416/CH8/EX8.1/exp8_1c.txt b/416/CH8/EX8.1/exp8_1c.txt
new file mode 100755
index 000000000..29b0941a2
--- /dev/null
+++ b/416/CH8/EX8.1/exp8_1c.txt
@@ -0,0 +1,4 @@
+
+ example 8.1
+
+power developed by hydro plant is 1.765200e+005kW \ No newline at end of file
diff --git a/416/CH8/EX8.2/exp8_2.png b/416/CH8/EX8.2/exp8_2.png
new file mode 100755
index 000000000..a322d0658
--- /dev/null
+++ b/416/CH8/EX8.2/exp8_2.png
Binary files differ
diff --git a/416/CH8/EX8.2/exp8_2.sce b/416/CH8/EX8.2/exp8_2.sce
new file mode 100755
index 000000000..c0c10f53c
--- /dev/null
+++ b/416/CH8/EX8.2/exp8_2.sce
@@ -0,0 +1,27 @@
+clear
+clc
+disp("example 8.2")
+flow=[0 1000 800 600 400 400 1200 2400 2400 1000 400 400 1000] //flow in matrix from in the order of months
+y=0:12
+h=150
+e=0.85
+avg=sum(flow)/12
+printf("\naverage rate of inflow is %dcu-m/sec",avg)
+p=(735.5/75)*avg*h*e
+printf("\npower developed is %fkW",p)
+plot2d2(y,flow)
+
+xtitle('hydrograph','months','run in cu-m/sec')
+disp("hydrograph is ploted in figure")
+for x=1:12
+ t=flow(1,x)
+ a=avg
+ if t<a|t==avg then
+ t=0
+ else
+ t=t-1000
+ end
+ flow1(1,x)=t;
+ end
+sto=sum(flow1)
+printf("\nstorage capacity of given plant is %dsec-m-month",sto) \ No newline at end of file
diff --git a/416/CH8/EX8.2/exp8_2.txt b/416/CH8/EX8.2/exp8_2.txt
new file mode 100755
index 000000000..18338e0c2
--- /dev/null
+++ b/416/CH8/EX8.2/exp8_2.txt
@@ -0,0 +1,8 @@
+
+ example 8.2
+
+average rate of inflow is 1000cu-m/sec
+power developed is 1250350.000000kW
+ hydrograph is ploted in figure
+
+storage capacity of given plant is 3000sec-m-month \ No newline at end of file
diff --git a/416/CH8/EX8.3/exp8_3.png b/416/CH8/EX8.3/exp8_3.png
new file mode 100755
index 000000000..333035caf
--- /dev/null
+++ b/416/CH8/EX8.3/exp8_3.png
Binary files differ
diff --git a/416/CH8/EX8.3/exp8_3.sce b/416/CH8/EX8.3/exp8_3.sce
new file mode 100755
index 000000000..edb133dbe
--- /dev/null
+++ b/416/CH8/EX8.3/exp8_3.sce
@@ -0,0 +1,36 @@
+clear
+clc
+disp("example 8.3")
+flow=[1500 1000 500 500 500 1200 2900 2900 1000 400 600 1600]
+cod=1000//constant demand
+plot2d2(flow)
+xtitle('hydrograph for exp 8.3','months','run off in m^3/sec')
+avg=sum(flow)/12
+if cod<avg then
+ for x=1:6
+ t=flow(1,x)
+ if t>cod|t==avg then
+
+ t=0
+ else
+ t=cod-t
+ end
+ flow1(1,x)=t;
+ end
+
+ else
+ for x=1:12
+ t=flow(1,x)
+ a=cod
+ if t>a|t==avg then
+ t=0
+ else
+ t=t-cod
+ end
+ flow1(1,x)=t;
+ end
+end
+
+sto=sum(flow1)
+printf("storage capacity of plant is %dsec-m-month",sto)
+
diff --git a/416/CH8/EX8.3/exp8_3.txt b/416/CH8/EX8.3/exp8_3.txt
new file mode 100755
index 000000000..1ac449a5e
--- /dev/null
+++ b/416/CH8/EX8.3/exp8_3.txt
@@ -0,0 +1,3 @@
+
+ example 8.3
+storage capacity of plant is 1500sec-m-month
diff --git a/416/CH8/EX8.4/exp8_4ff.jpg b/416/CH8/EX8.4/exp8_4ff.jpg
new file mode 100755
index 000000000..25b4c698a
--- /dev/null
+++ b/416/CH8/EX8.4/exp8_4ff.jpg
Binary files differ
diff --git a/416/CH8/EX8.4/exp8_4ff.sce b/416/CH8/EX8.4/exp8_4ff.sce
new file mode 100755
index 000000000..ce00a5d6b
--- /dev/null
+++ b/416/CH8/EX8.4/exp8_4ff.sce
@@ -0,0 +1,41 @@
+clear
+clc
+disp("example 8.4")
+flow=[1500 1000 500 500 500 1200 2900 2900 1000 400 600 1600]
+cod=1000//constant demand
+[m n]=size(flow)
+mf(1)=1500
+for i=2:n
+ mf(i)=mf(i-1)+flow(i)
+end
+plot(mf)
+dd=1:cod:mf(n)
+avg=sum(flow)/12
+if cod<avg then
+ for x=1:6
+ t=flow(1,x)
+ if t>cod|t==avg then
+
+ t=0
+ else
+ t=cod-t
+ end
+ flow1(1,x)=t;
+ end
+
+ else
+ for x=1:12
+ t=flow(1,x)
+ a=cod
+ if t>a|t==avg then
+ t=0
+ else
+ t=t-cod
+ end
+ flow1(1,x)=t;
+ end
+end
+
+sto=sum(flow1)
+printf("storage capacity of plant is %dsec-m-month",sto)
+
diff --git a/416/CH8/EX8.4/exp8_4ff.txt b/416/CH8/EX8.4/exp8_4ff.txt
new file mode 100755
index 000000000..5ba271806
--- /dev/null
+++ b/416/CH8/EX8.4/exp8_4ff.txt
@@ -0,0 +1,3 @@
+
+ example 8.4
+storage capacity of plant is 1500sec-m-month \ No newline at end of file
diff --git a/416/CH8/EX8.5/exp8_5.png b/416/CH8/EX8.5/exp8_5.png
new file mode 100755
index 000000000..7af136164
--- /dev/null
+++ b/416/CH8/EX8.5/exp8_5.png
Binary files differ
diff --git a/416/CH8/EX8.5/exp8_5.sce b/416/CH8/EX8.5/exp8_5.sce
new file mode 100755
index 000000000..cef53b622
--- /dev/null
+++ b/416/CH8/EX8.5/exp8_5.sce
@@ -0,0 +1,34 @@
+clear
+clc
+disp("solution of 8.5")
+flow=[80 50 40 20 0 100 150 200 250 120 100 80]
+h=100;e=80
+subplot(211)
+plot2d2(flow)
+xtitle('hydrograph','months','run off,millon m^3/month' )
+fd=gsort(flow)
+subplot(212)
+plot2d2(fd)
+xtitle('flow duretion','months','run off')
+
+t=1:12
+for x=2:10
+ d=fd(1,x)
+ ad=fd(1,(x-1))
+ if d==ad then
+ t(1,x)=[]
+ t(1,x-1)=t(1,x-1)+1
+ fd(1,x)=[]
+ end
+end
+ffw=[fd;t]
+disp("load duration data is as under")
+disp(ffw)
+mf=sum(flow)*10^6/(30*24*3600)
+disp("(a)")
+printf("meanflow is %fm^3-sec",mf)
+disp("(b)")
+p=(735.5/75)*mf*h*e
+printf("power delevered in %dkW=%.3fMW",p,p/1000)
+
+
diff --git a/416/CH8/EX8.5/exp8_5.txt b/416/CH8/EX8.5/exp8_5.txt
new file mode 100755
index 000000000..6b2562e0e
--- /dev/null
+++ b/416/CH8/EX8.5/exp8_5.txt
@@ -0,0 +1,11 @@
+solution of 8.5
+
+ load duration data is as under
+
+ 250. 200. 150. 120. 100. 80. 50. 40. 20. 0.
+ 1. 2. 3. 4. 6. 8. 9. 10. 11. 12.
+
+ (a)
+meanflow is 459.104938m^3-sec
+ (b)
+power delevered in 36018312kW=36018.313MW \ No newline at end of file
diff --git a/416/CH8/EX8.6/exp8_6c.sce b/416/CH8/EX8.6/exp8_6c.sce
new file mode 100755
index 000000000..b2c405027
--- /dev/null
+++ b/416/CH8/EX8.6/exp8_6c.sce
@@ -0,0 +1,24 @@
+clear
+clc
+disp("example 8.6")
+mh=205//mean height
+a=1000*10^6//in miters
+r=1.25//annual rain fall
+er=0.8//efficiency
+lf=0.75//load factor
+hl=5//head loss
+et=0.9//efficiency of turbine
+eg=0.95//efficiency of generator
+wu=a*r*er/(365*24*3600)
+printf("\nwater used is \t\t%fm^3/sec",wu)
+eh=mh-hl
+printf("\neffective head is \t%dm",eh)
+p=(735.5/75)*(wu*eh*et*eg)
+printf("\npower generated is \t%fkW =\t%fMW",p,p/1000)
+pl=p/lf
+printf("\npeak load is \t\t%fMw \ntherefore the MW rating of station is \t%fMW",pl/1000,pl/1000)
+if eh<=200 then
+printf("\nfor a head above 200m pelton turbine is suitable,\nfrancis turbine is suitable in the range of 30m-200m.,\nhowever pelton is most suitable")
+else
+ printf("only pelton turbine is most suitable")
+end
diff --git a/416/CH8/EX8.6/exp8_6c.txt b/416/CH8/EX8.6/exp8_6c.txt
new file mode 100755
index 000000000..ead379fc3
--- /dev/null
+++ b/416/CH8/EX8.6/exp8_6c.txt
@@ -0,0 +1,11 @@
+
+ example 8.6
+
+water used is 31.709792m^3/sec
+effective head is 200m
+power generated is 53175.418569kW = 53.175419MW
+peak load is 70.900558Mw
+therefore the MW rating of station is 70.900558MW
+for a head above 200m pelton turbine is suitable,
+francis turbine is suitable in the range of 30m-200m.,
+however pelton is most suitable \ No newline at end of file
diff --git a/416/CH9/EX9.1/9_1ans.txt b/416/CH9/EX9.1/9_1ans.txt
new file mode 100755
index 000000000..cc4c0000a
--- /dev/null
+++ b/416/CH9/EX9.1/9_1ans.txt
@@ -0,0 +1,3 @@
+
+ example 9.1
+energy equivalent of 1 gram is 25000000kWh \ No newline at end of file
diff --git a/416/CH9/EX9.1/exp9_1.sce b/416/CH9/EX9.1/exp9_1.sce
new file mode 100755
index 000000000..f3de3abe9
--- /dev/null
+++ b/416/CH9/EX9.1/exp9_1.sce
@@ -0,0 +1,8 @@
+clear
+clc
+disp("example 9.1")
+m=1*10^-3//mass of 1 grm in kgs
+c=3*10^8
+e=m*c^2;
+E=e/(1000*3600)
+printf("energy equivalent of 1 gram is %dkWh",E)
diff --git a/416/CH9/EX9.2/9_2ans.txt b/416/CH9/EX9.2/9_2ans.txt
new file mode 100755
index 000000000..1d85368bd
--- /dev/null
+++ b/416/CH9/EX9.2/9_2ans.txt
@@ -0,0 +1,4 @@
+example 9.2
+energy evalent in joules is 1.494000e-010joules
+ energy equvalent in Mev is 932MeV
+ hense shown \ No newline at end of file
diff --git a/416/CH9/EX9.2/exp9_2.sce b/416/CH9/EX9.2/exp9_2.sce
new file mode 100755
index 000000000..a5f40fa12
--- /dev/null
+++ b/416/CH9/EX9.2/exp9_2.sce
@@ -0,0 +1,9 @@
+clear
+clc
+disp("example 9.2")
+amu=1.66*10^-27//mass equvalent in kgs
+c=3*10^8
+j=6.242*10^12
+e=amu*c^2
+E=e*j;
+printf("energy evalent in joules is %ejoules \n energy equvalent in Mev is %dMeV \n hense shown",e,E) \ No newline at end of file
diff --git a/416/CH9/EX9.3/9_3ans.txt b/416/CH9/EX9.3/9_3ans.txt
new file mode 100755
index 000000000..c27e71714
--- /dev/null
+++ b/416/CH9/EX9.3/9_3ans.txt
@@ -0,0 +1,14 @@
+
+ example 9.3
+ (a)
+ mass defect is for hydrogen 0.002390amu
+ total binding energy for hydrogens 2.225090Mev
+ average binding energy for hydrogen is 1.112545MeV
+ (b)
+ mass defect is for nickel 0.553515amu
+ total binding energy for nickel is 515.322465Mev
+ average binding energy for nickelis 8.734279MeV
+ (c)
+ mass defect of uranium is 1.915095amu
+ total binding energy uranium is 1782.953445Mev
+ average binding energy uranium is 7.587036MeV \ No newline at end of file
diff --git a/416/CH9/EX9.3/exp9_3.sce b/416/CH9/EX9.3/exp9_3.sce
new file mode 100755
index 000000000..827205301
--- /dev/null
+++ b/416/CH9/EX9.3/exp9_3.sce
@@ -0,0 +1,18 @@
+clear
+clc
+disp("example 9.3")
+hm=2.0141
+hp=1.007825
+hn=1.008665
+nm=58.9342
+np=28
+nn=59
+um=235.0439
+up=92
+un=235
+hmd=hp+hn-hm;nmd=np*hp+(nn-np)*hn-nm;umd=up*hp+(un-up)*hn-um;
+hbe=931*hmd;nbe=931*nmd;ube=931*umd;
+ahbe=hbe/2;anbe=nbe/nn;aube=ube/un;
+printf("\t(a)\n mass defect is for hydrogen %famu \n total binding energy for hydrogens %fMev \n average binding energy for hydrogen is %fMeV",hmd,hbe,ahbe)
+printf("\n\t(b)\n mass defect is for nickel %famu \n total binding energy for nickel is %fMev \n average binding energy for nickelis %fMeV",nmd,nbe,anbe)
+printf("\n\t(c)\n mass defect of uranium is %famu \n total binding energy uranium is %fMev \n average binding energy uranium is %fMeV",umd,ube,aube) \ No newline at end of file
diff --git a/416/CH9/EX9.4/9_4ans.txt b/416/CH9/EX9.4/9_4ans.txt
new file mode 100755
index 000000000..f9f9e0a55
--- /dev/null
+++ b/416/CH9/EX9.4/9_4ans.txt
@@ -0,0 +1,5 @@
+
+ example 9.4
+(lamda) disintegrations per sec is 3.095054e-017bq
+ initial activity is lamda*na is 5.261592e+007bq
+ final number of atoms is 6.405500e+023atoms \ No newline at end of file
diff --git a/416/CH9/EX9.4/exp9_4.sce b/416/CH9/EX9.4/exp9_4.sce
new file mode 100755
index 000000000..c32798ec7
--- /dev/null
+++ b/416/CH9/EX9.4/exp9_4.sce
@@ -0,0 +1,11 @@
+clear
+clc
+disp("example 9.4")
+no=1.7*10^24
+hl=7.1*10^8
+t=10*10^8
+lm=0.693/(hl)
+lmda=lm/(8760*3600)
+ia=lmda*no
+n=no*(exp(-lm*t))
+printf("(lamda) disintegrations per sec is %ebq \n initial activity is lamda*na is %ebq \n final number of atoms is %eatoms",lmda,ia,n)
diff --git a/416/CH9/EX9.5/9_5ans.txt b/416/CH9/EX9.5/9_5ans.txt
new file mode 100755
index 000000000..2c786b89c
--- /dev/null
+++ b/416/CH9/EX9.5/9_5ans.txt
@@ -0,0 +1,4 @@
+ example 9.5
+1 watt power requvires 2.678400e+015fussions per day
+ number of atoms in 5 gram is 1.281489e+022atoms
+ power is 4.784533e+006MW \ No newline at end of file
diff --git a/416/CH9/EX9.5/exap9_5.sce b/416/CH9/EX9.5/exap9_5.sce
new file mode 100755
index 000000000..c1fe05176
--- /dev/null
+++ b/416/CH9/EX9.5/exap9_5.sce
@@ -0,0 +1,10 @@
+clear
+clc
+disp("example 9.5")
+um=5
+owp=2.6784*10^15
+an=6.023*10^23
+na1g=an/235
+na5g=an*5/235
+p=na5g/owp
+printf("1 watt power requvires %efussions per day \n number of atoms in 5 gram is %eatoms \n power is %eMW ",owp,na5g,p) \ No newline at end of file
diff --git a/416/CH9/EX9.6/9_6ans.txt b/416/CH9/EX9.6/9_6ans.txt
new file mode 100755
index 000000000..513054466
--- /dev/null
+++ b/416/CH9/EX9.6/9_6ans.txt
@@ -0,0 +1,5 @@
+ example 9.6
+total energy input 7.410960e+015Watt sec
+ energy input is 2.245745e+016Watt-sec
+ total number of fissions required is 6.961811e+026fissions
+ fuel required is 2.716274e+005 grams 271kg \ No newline at end of file
diff --git a/416/CH9/EX9.6/exp9_6.sce b/416/CH9/EX9.6/exp9_6.sce
new file mode 100755
index 000000000..c48db4719
--- /dev/null
+++ b/416/CH9/EX9.6/exp9_6.sce
@@ -0,0 +1,13 @@
+clear
+clc
+disp("example 9.6")
+pp=235
+pe=0.33
+lf=1
+teo=pp*8760*3600*10^6
+ei=teo/pe
+nfr=3.1*10^10//fessions required
+tnfr=nfr*ei
+t1gu=2.563*10^21 //total uranium atoms in 1 grm
+fure=tnfr/t1gu
+printf("total energy input %eWatt sec \n energy input is %eWatt-sec\n total number of fissions required is %efissions \n fuel required is %e grams %dkg",teo,ei,tnfr,fure,fure/1000)
diff --git a/416/CH9/EX9.7/9_7ans.txt b/416/CH9/EX9.7/9_7ans.txt
new file mode 100755
index 000000000..513054466
--- /dev/null
+++ b/416/CH9/EX9.7/9_7ans.txt
@@ -0,0 +1,5 @@
+ example 9.6
+total energy input 7.410960e+015Watt sec
+ energy input is 2.245745e+016Watt-sec
+ total number of fissions required is 6.961811e+026fissions
+ fuel required is 2.716274e+005 grams 271kg \ No newline at end of file
diff --git a/416/CH9/EX9.7/exp9_7.sce b/416/CH9/EX9.7/exp9_7.sce
new file mode 100755
index 000000000..368fff300
--- /dev/null
+++ b/416/CH9/EX9.7/exp9_7.sce
@@ -0,0 +1,13 @@
+clear
+clc
+disp("example 9.7")
+en=3*10^6
+a=12
+fen=0.1
+Es=2/(12+2/3)
+re=exp(Es)
+printf("(a)\nratio of energies per collision is %f",re)
+rietf=en/fen
+ldie=log(rietf)
+nc=ldie/Es
+printf("(b)\npatio of iniial to final energies is %e \n logarithemic decrement in energy is %f \n number of collisions is %d",rietf,ldie,nc)