blob: 07a506577cd767265c1d0f160c3a5d6f3a0b1b2b (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
|
//Example 17// Ch 3
clc;
clear;
close;
// given data
E = 5; //electric field in V/m
n_o = 10^11; //ion density in ions/m3
T = 293; // in kelvin
z = 0.02; //distance in meters
e = 1.6*10^-19; //in couloumb
k = 1.38*10^-23; // in m2 kg s-2 K-1
n1 = n_o*exp((-e*E*z)/(k*T));//ion density 0.02m away
n2 = n_o*exp((e*E*z)/(k*T));//ion density -0.02m away
printf("ion density 0.02m away %e ions/m^3 \n",n1)
printf("ion density -0.02m away %e ions/m^3 \n",n2)
|