summaryrefslogtreecommitdiff
path: root/2912/CH6/EX6.9/Ex6_9.sce
blob: 0269cc49188e9219784cf70a039cdf25382a5500 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
//chapter 6
//example 6.9
//Calculate average drift velocity of electrons
//page 149
clear;
clc;
//given
I=4; // in A (current in the conductor)
e=1.6E-19; // in C (charge of electron)
A=1E-6; // in m^2 (cross-sectional area)
N_A=6.02E23; // in atoms/gram-atom (Avogadro's number)
p=8.9; // in g/cm^3 (density)
M=63.6; // atomic mass of copper
//calculate
n=N_A*p/M; // Calculation of density of electrons in g/cm^3
printf('\nThe density of copper atoms is \tn=%1.2E atoms/m^3',n);
n=n*1E6; // changing unit from g/cm^3 to g/m^3
printf('\n\t\t\t\t =%1.2E atoms/m^3',n);
v_d=I/(n*A*e);
printf('\n\nThe average drift velocity of free electrons is \tv_d=%1.1E m/s',v_d);