summaryrefslogtreecommitdiff
path: root/Concise_Physics_by_H_Matyaka/1-Basics.ipynb
blob: 6c666dcc5d3e1d2e8c6e41f4c5fe49d391369678 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
{
"cells": [
 {
		   "cell_type": "markdown",
	   "metadata": {},
	   "source": [
       "# Chapter 1: Basics"
	   ]
	},
{
		   "cell_type": "markdown",
		   "metadata": {},
		   "source": [
			"## Example 1.1: Neutral_temperature.sce"
		   ]
		  },
  {
"cell_type": "code",
	   "execution_count": null,
	   "metadata": {
	    "collapsed": true
	   },
	   "outputs": [],
"source": [
"clc\n",
"clear\n",
"//input\n",
"x=(0:50:550)//temperature difference in x axis\n",
"y=[0,0.43,0.79,1.10,1.36,1.54,1.69,1.77,1.80,1.78,1.70,1.54]//emf in y axis\n",
"//calculation\n",
"title('a graph of E vs teta')//setting title for graph\n",
"xlabel('temperature difference teta')//setting x label\n",
"ylabel('emf E')//setting y label\n",
"plot(x,y)//plotting the graph\n",
"printf('from the grapgh it can be determined that neutral temperature is 400deg C')\n",
"x=(50:50:550)//temperature difference in x axis\n",
"y=[8.6,7.9,7.3,6.8,6.2,5.6,5.1,4.5,4.0,3.4,2.8] //E/theta in y axis\n",
"plot(x,y,'+-')//plotting the graph\n",
"title('a graph of E/teta vs teta')//set title\n",
"xlabel('temperature difference teta')//set x label\n",
"ylabel(' E/teta')//set y label\n",
"legend('E Vs Theta','E/theta Vs theta')\n",
"b=-(4.5*10^-6)/400//gradient of graph is b \n",
"a=4.5*10^-6-(b*400)//finding the intercept on y axis by substututing the points(400,4.5) in line equation\n",
"printf('\n the value of b is %3.3e VdegC^-2',b)\n",
"printf('\n the value of a is %3.3e VdegC^-1',a)\n",
"\n",
" "
   ]
   }
],
"metadata": {
		  "kernelspec": {
		   "display_name": "Scilab",
		   "language": "scilab",
		   "name": "scilab"
		  },
		  "language_info": {
		   "file_extension": ".sce",
		   "help_links": [
			{
			 "text": "MetaKernel Magics",
			 "url": "https://github.com/calysto/metakernel/blob/master/metakernel/magics/README.md"
			}
		   ],
		   "mimetype": "text/x-octave",
		   "name": "scilab",
		   "version": "0.7.1"
		  }
		 },
		 "nbformat": 4,
		 "nbformat_minor": 0
}