summaryrefslogtreecommitdiff
path: root/3845/CH18/EX18.1/Ex18_1.sce
diff options
context:
space:
mode:
Diffstat (limited to '3845/CH18/EX18.1/Ex18_1.sce')
-rw-r--r--3845/CH18/EX18.1/Ex18_1.sce15
1 files changed, 15 insertions, 0 deletions
diff --git a/3845/CH18/EX18.1/Ex18_1.sce b/3845/CH18/EX18.1/Ex18_1.sce
new file mode 100644
index 000000000..eaee3c813
--- /dev/null
+++ b/3845/CH18/EX18.1/Ex18_1.sce
@@ -0,0 +1,15 @@
+//Example 18.1
+r=0.530*10^-10;//Separation (m)
+k=8.99*10^9;//Coulomb's constant (N.m^2/C^2)
+q1=-1.60*10^-19;//Charge of electron (C)
+q2=1.60*10^-19;//Charge of proton (C)
+F=k*abs(q1*q2)/r^2;//Coulomb force (N)
+printf('Electrostatic force = %0.2e N',F)
+G=6.67*10^-11;//Gravitational constant (N.m^2/kg^2)
+m=9.11*10^-31;//Electron mass (kg)
+M=1.67*10^-27;//Proton mass (kg)
+F_G=G*m*M/r^2;//Gravitational force (N)
+printf('\nGravitational force = %0.2e N',F_G)
+printf('\nRatio of electrostatic force to gravitational force = %0.2e',F/F_G)
+//Openstax - College Physics
+//Download for free at http://cnx.org/content/col11406/latest