Applications of the ScientificConstants Package
Initialization
restart
with⁡ScientificConstants:
Molecular Weight
How many molecules of acetone are in a 10 gram sample?
The chemical formula for acetone is C3⁢H6⁢O . Thus, the molecular weight is:
3⁢⋅ ElementC,atomicweight+6⁢ElementH,atomicweight+ElementO,atomicweight
3⁢Element⁡C,atomicweight+6⁢Element⁡H,atomicweight+Element⁡O,atomicweight
evalf⁡
9.644274675×10−26
which, in the current default system of units SI, is measured in kilograms (kg). To convert a measurement between units, use the convert/units function.
convert⁡,units,kg,amu
58.07914000
By definition, the number of atomic mass units per molecule is equal to the number of grams per mole. Hence, divide 10 by the above result.
10.
0.1721788580
which is the number of moles in the sample.
To calculate the number of molecules, multiply the above result by Avogadro's constant.
⋅⁢evalfConstant⁡N'A'
1.036885335×1023
Geostationary Orbit
Find the radius of a geostationary orbit.
The expression for circular orbital velocity around a spherically symmetric body is:
vCirc:=G⁢MR
vCirc≔G⁢MR
where G is the gravitational constant, M is the mass of the body, and R is the radius of orbit.
Now, for geostationary orbit, an orbital velocity of 2⁢π⁢R meters per day is required, which in meters per second is:
convert⁡2⁢π⁢R,units,md,ms
π⁢R43200
Equate this to vCirc.
eqn1≔vCirc=
eqn1≔G⁢MR=π⁢R43200
Solve for R. To disregard non-real solutions, use the RealDomain package.
useRealDomaininrGeo:=solve⁡eqn1,Rend use
rGeo≔720⁢513⁢G⁢M13π23
Replace G with its value and M with the mass of the Earth and then evaluate.
evalfevalrGeo, G=ConstantG, M=ConstantMEarth
4.224068226×107
convert⁡,units,m,km
42240.68226
The result is the radius in kilometers (km) of a geostationary orbit.
Geostationary Orbit, with units
Find the radius of a geostationary orbit. We proceed in a manner analogous to the previous section, but with the intent of substituting values with units attached for G and M, and obtaining a value for R with units attached.
convert⁡2⁢π⁢Rday,units,1s
π⁢R43200⁢1s
eqn1≔G⁢MR=π⁢R43200⁢1s
rGeo≔720⁢513⁢G⁢M13π23⁢s23
combineevalfevalrGeo, G=ConstantG, units, M=ConstantMEarth, units, units
4.224068226×107⁢m
convert⁡,units,km
42240.68226⁢km
Periodicity of Ionization Energy
Plot the ionization energies in electronvolts of the elements of the periodic table ordered by increasing atomic number.
ionEn:=map⁡an→an,evalf⁡Elementan,ionizationenergy,GetElements⁡ionizationenergy,output=atomicnumbers:
plotspointplotionEn,style=line,labels=atomic number,eV
Decay Activity
The expression for the activity is:
A≔A__0 ⅇ−λ⁢t
A≔A__0⁢ⅇ−λ⁢t
where A__0 is the initial activity, λ is the decay constant of the isotope, and t is the elapsed time.
The decay constant is related to the half-life by λ=ln⁡2H.
λ:=evalf⁡ln⁡2evalfElementI131,halflife
λ≔1.000353731×10−6
Plot with A__0=1.
A__0≔1;plot⁡A,t=0..6.⁢106,labels=time (s),Activity
A__0≔1
Simple Chart of Nuclides
#all isotopesisos ≔ map i → i2−i1,i1, GetIsotopes output=atomicnumbers :nops isos
2957
#stable isotopesisos_stable ≔ map i → i2−i1,i1, GetIsotopes abundance, output=atomicnumbers :nops isos_stable
288
#unstable isotopesisos_unstable ≔ isos minus isos_stable:
isos_st_p≔plotspointplotisos_stable,color=green,legend=stable:
isos_unst_p≔plotspointplotisos_unstable,color=grey,legend=unstable:
plotsdisplay⁡isos_st_p,isos_unst_p,symbol=CROSS,labels=neutron number,atomic number,labeldirections=HORIZONTAL,VERTICAL
Binding Energy per Nucleon
Plot the average binding energy per nucleon as a function of mass number.
Selecting odd-even nuclei (i.e. A odd) that are stable:
bindEn ≔ map i → i2, convert evalf Element i, bindingenergy , units, J, MeV /i2, select j → type j2, odd , GetIsotopes abundance, bindingenergy, output=atomicnumbers :nopsbindEn
111
plotspointplot bindEn, symbol=CIRCLE, symbolsize=5, labels=mass number, MeV per nucleon, labeldirections=HORIZONTAL,VERTICAL, view=0..220, 7.5..9 ;
Return to ScientificConstants
Return to Index for Example Worksheets
Download Help Document