Numerical Method Reviews

Hello,

This note will be a collection of my personally created numerical method reviews. I will be reviewing topics from two books[B1;B2].I have uploaded my PDFs to scribd because I have had hit and miss experience with LaTeX in WordPress. Also, the PDFs can be accessed, downloaded, and printed easily.

I have chosen books [B2; B5] because they are used in courses at MIT that are freely available online. Since I am using Octave, I found a great book for that environment too[B1]. I plan to study both books.

Purpose

Most books have an initial chapter that discusses pertinent topics to be successful for the rest of the book. The topics are briefly discussed, and the authors [B1;B2] really expect the reader to have full knowledge or gain full knowledge of the material before proceeding.

I am entering a learning phase and a review phase. I am reviewing calculus [B3] and algebra[B4], but I am learning linear algebra[B5]. This note will be a place that I categorize my reviews.

I am writing these reviews with LaTeX, so that takes time as well. Still, LaTeX lets me easily write in the language of mathematics once I learn it well.

Numerical Methods Using MATLAB Reviews[B2]

Quote: It is assumed that the reader is familiar with the notation and subject matter covered in undergraduate calculus sequence. This should have included topics of limits, continuity, differentiation, integration, sequences, and series. Throughout the book we refer to the following results.”[B2]

Quote: “Example 1 is about as easy a limit proof can get; most limit proofs require a little more algebraic and logical ingenuity. (sic: read basic knowledge should be well understood.) The reader who finds “δ – ε ” discussions hard going should not become discouraged; the concepts and techniques are intrinsically difficult. In fact, a precise understanding of limits evaded the finest mathematical minds for centuries.”[B3]”[B2,1]

Reviews For Numerical Methods Using MATLAB[B2]:

[B2,1] Harding, Chris. (2015, Dec. 21). Review of Limits. Retrieved (2015, Dec. 21). Available from: https://www.scribd.com/doc/293834966/Review-of-Limits

Scientific Computing With MATLAB And Octave[B1]

Quote: “In this book we will systematically use elementary mathematical concepts which the reader should know already, yet he or she might not recall them immediately.

We will therefore use this chapter to refresh them and we will condense notions which are typical of courses in Calculus, Linear Algebra and Geometry, yet rephrasing them in a way that is suitable for use in Scientific Computing.”[B1]

Reviews For Scientific Computing with MATLAB and Octave[B1]:

[B1,1] Harding, Chris. (2015, Dec. 26). Chapter 1, What Can’t Be Ignored: Section 1.1 To Addition And Multiplication Review Of Matrices.(Octave) Retrieved (2015, Dec. 26). Scribd[online]. Available from: https://www.scribd.com/doc/294069551/Chapter-1-What-Can-t-Be-Ignored-1-Section-1-1-To-Addition-And-Multiplication-Review-Of-Matrices

Books:

[B1] Quarteroni, Alfio; Saleri, Fausto; Gervasio, Paola. Scientific Computing with MATLAB and Octave. Fourth Edition. Retrieved (2015, Dec. 18). Shannon[online]

[B2] Mathews, John H.; Fink, Kurtis, D. (1999). Numerical Methods Using Matlab. (Third Edition). Prentice Hall

[B3] Anton, Howard. Calculus with Analytic Geometry. Fifth Edition.

[B3a] Barker, William H.; Ward, James E. (1995). The Calculus Companion to Accompany Calculus with Analytic Geometry. Fifth Edition by Howard Anton. John Wiley

[B4] Grossman, Stanley I. (1992) Algebra and Trigonometry, Second Edition. Saunders College

[B5] Strang, Gilbert. (2009). Introduction to Linear Algebra. South Asian Edition. Cambridge University Press India Pvt. Ltd.

Limits Review: A Rigorous Approach

Limits Review: A Rigorous Approach

Hello,

LimitAbsValue
Dr. Anton–Calculus Textbook–Quote:
“Example 1 is about as easy a limit proof can get; most limit proofs require a little more algebraic and logical ingenuity. (sic: read basic knowledge should be well understood.) The reader who finds “δ – ε” discussions hard going should not become discouraged; the concepts and techniques are intrinsically difficult. In fact, a precise understanding of limits evaded the finest mathematical minds for centuries.”[3]”[1]

Purpose

I have hopes to learn some Numerical Methods[2] to allow me to contribute to PLOTS (http://publiclab.org). Numerical methods are  often used by engineers to mathematically solve problems that do not have “exact” solutions. In truth, they can be used to solve problems that have exact solutions where the solution is quite difficult as well.

Also, the studying of math and engineering help me mentally by providing the psychotherapy methods of mindfulness and compensatory cognitive training for my schizoaffective disorder (bipolar type).

Here, I have provided my first LaTeX created PDF on this topic– LaTeX is great for writing mathematics and is free–that reviews limits and absolute values. I am writing such documents because it is likely that I will lose focus or be hospitalized since that has happened in the past. I can then read a document I made to provide an understanding to move forward. In this case, one of my numerical methods Books started with a vague and abstract definition of the rigorous limits approach[1;2], and I wanted a better understanding[1].

I plan to do similar PDFs for other “review” topics in Section 1.1[2]. By the way, I picked[2] because MIT has a free course that uses the same textbook.

In my reference[1], I also provide a great book that covers the use of Octave and MATLAB when doing numerical methods.

Great Video and Special Note

This MIT video on the Rigorous approach has great information of absolute values, etc. In fact, I suggest the reader pay particular attention, within the video[3], of the power of a simple absolute value property of “Triangle inequality”

|a + b| \leq |a| + |b|

that is discussed during the problem solving near video time of 35:12 to end at 46 minutes.

The professor is being kind. To be good, one must have an amazing memory and an amazing grasp of the fundamentals of mathematics. Really, I believe one should obviously begin this grasp in each math class, but, if one is intelligent enough to grasp future fundamentals ahead of the curve, then he or she can go back and review past sections as they pertain to the current set of problems. I am not that person, but hope to gain enough of a “working” knowledge that I can be competent and useful in the world of PLOTS. With that said, all the video[Embedded; 3] is important and a good test of one’s knowledge on this topic[1].

 

References:

[1] Harding, Chris. (2015, Dec. 21). Review of Limits. Retrieved (2015, Dec. 21). Available from: https://www.scribd.com/doc/293834966/Review-of-Limits; Google URL: goo.gl/vd5XAe

[2] Mathews, John H.; Fink, Kurtis, D. (1999). Numerical Methods Using Matlab. (Third Edition). Prentice Hall

[3] MIT OpenCourseWare. (2011, May 05). Unit I: Lec 5 | MIT Calculus Revisted: Single Variable Calculus, Unit !: Lecture 5: A More Rigorous Approach to Limits. Retrieved (2015, Dec. 28). youtube[online]. Available from: https://youtu.be/9tYUmwvLyIA?list=PLLEGnvlQMshG_TaCu75GpVOeXHiVe0JP2


Drop Evaporation at 10 degrees C, 1 atmosphere, and 71% relative humidity (January in Iraq and near Baghdad): Sarin (Nerve Agent) versus Water

Note: Sadly, I have noticed that the code of LaTex changes in WordPress. As an example, the text “\textdegree” use to provide the ˚ symbol but now provides “\textdegree“. As such, please be patient and do not blame me for all editor faults! 🙂 It truly is an experiment in progress and I am dependent upon LaTex and WordPress consistency.

Title: Drop Evaporation at 10 degrees C, 1 atmosphere, and 71% relative humidity (January in Iraq and near Baghdad): Sarin (Nerve Agent) versus Water

Conclusion: The molar flux of water is greater than sarin. As such, I assume the evaporation of water is greater than sarin. The latter is supported by a relative volatility (water:sarin) that is 12.6 at the specified conditions. Also, the boiling point of sarin is greater than water.

1991 Gulf War Illness

Before I continue, I would like the reader to know that more than 250,000 United States 1991 Gulf War veterans are suffering from 1991 Gulf War Illnesses. The illness can be psychologically and medically debilitating. For more information and to provide support, please please read the  December 2012 scientific journal articles that connect chemical weapons to potential cause of illnesses[7;8]. Also, I wrote a post about differing hypotheses and 1991 Gulf War Illness[17].

Actual mathematical properties of a potential  drop

Equation: z = 1-\frac{1}{8}(x^2 + y^2)

The base: y = \sqrt{2.3^2 - x^2}

The base radius: 2.3 millimeters; The height: 1 millimeter

Drop volume: Double integration in polar coordinates

Volume = \iint_R z \ \mathrm{d}A = \iint_R f(x,y) \ \mathrm{d}A = \iint_R f(rcos(\theta), rsin(\theta)) \ r \ \mathrm{d}r \ \mathrm{d}\theta

In polar coordinates

r^2 = x^2 + y^2

z = 1 - \frac{1}{8}(x^2 + y^2) = 1 - \frac{1}{8}(r^2)

Volume =\iint_R (1 - \frac{1}{8}(x^2 + y^2)) \mathrm{d}A = \iint_R (1 - \frac{1}{8}(r^2)) \ r\mathrm{d}r \ \mathrm{d}\theta

R is a unit disk in the xy plane and one reason I can use polar coordinates.

(i) For fixed \theta, r range: 0 ≤ r ≤ 2.3 millimeters

(ii) Angle range: 0 ≤ \theta ≤ 2\pi

Volume = \int_0^{2\pi} \int_0^{2.3} (1-\frac{1}{8}(r^2)) \ r\mathrm{d}r \ \mathrm{d}\theta

From TI-92:

Volume = \int_0^{2\pi} [\frac{-(r^2-8)^2}{32}]_{r=0}^{r=2.3} \ \mathrm{d}\theta = \int_0^{2\pi}(1.77) \ \mathrm{d}\theta

Volume = \int_0^{2\pi}(1.77) \ \mathrm{d}\theta = [1.77\theta_{\theta = final} - 1.77\theta_{\theta = initial}]_0^{2\pi} = (1.77(2\pi) - 1.77(0)) =

Drop \ volume = 11.12 \ mm^3

Convert to cubic centimeters for calculations

\frac{1 \ cm}{10 \ mm} \ and \ \frac{1^3 \ cm^3}{10^3 \ mm^3} = \frac{1 \ cm^3}{1000 \ mm^3}

Drop \ volume = 11.12 \ mm^3(\frac{1 \ cm^3}{1000 \ mm^3}) = 0.011 \ cm^3

Density of fluids

Sarin[12-14]: ChemSpider: 1.07; Noblis: 1.096 at 20 deg C; WISER: 1.0887 at 25 deg C

Note: Difficult finding density data on sarin. As such, will assume the density changes little between above values and 10 deg Celsius.

Sarin average: Density \ average =\frac{(1.07+1.096+1.0887)}{3} = 1.09 = 1.1 \ \frac{g}{cm^3}

Water at 10 deg C[3;15]: Perry’s: 999.699; Engineering Tool Box: 999.7

Water average: Density \ average = \frac{(999.699 + 999.7)}{2} = 999.699 \frac{kg}{m^3}

Conversion: (999.699 \frac{kg}{m^3}) (\frac{1 m^3}{100^3cm^3})(\frac{1000 g}{1 kg}) = 1.0 \frac{g}{cm^3}

Water average: Density \ average = 1.0 \ \frac{g}{cm^3}

Evaporation mass: Drop Volume x density

Sarin: Mass = 0.011cm^3(1.1 \frac{g}{cm^3}) = 0.012 \ grams

Water: Mass = 0.011cm^3(1.0 \frac{g}{cm^3}) = 0.011 \ grams

Evaporation moles: Mass divide by molecular weight

Sarin: Moles_{C_4H_{10}FO_2P} = \frac{0.012 \ grams}{(\frac{140.1 \ grams}{mole})} = 8.6 x 10^{-5} \ moles

Water: Moles_{H_2O} = \frac{0.011 \ grams}{\frac{18 \ grams}{mole}} = 6.11 x 10^{-4} \ moles

Mass transfer: Evaporation

Sarin

The moles of sarin evaporated per square centimeter per unit time may be expressed by[1]

N_{A,z} = \frac{cD_{AB}}{(z_2-z_1)} \frac{(y_{A1} - y_{A2})}{y_{B,lm}}

Total molar concentration, c

PV = nRT; c =\frac{n}{V} = \frac{P}{RT} = \frac{cm^3}{mol}

The gas constant “R” will be calculated at standard temperature and pressure, “STP”

Temperature = 273 K; Pressure = 1 atm; Molar \ volume: \ \frac{L}{mol} = 22.4 \frac{L}{mol}

Conversion: 22.4 \frac{L}{mol}(\frac{1000 \ cm^3}{1\ Liters}) = 2.24x10^4 \ \frac{cm^3}{mol}

R = \frac{PV}{nT} = \frac{(1 \ atm)(2.24x10^4\frac{cm^3}{mol})}{273 \ K} = 82.05 \frac{atm \ cm^3}{mol \ K}

c = \frac{moles}{cm^3} = \frac{P}{RT} = \frac{1 \ atm}{(82.05 \frac{atm cm^3}{mol K})(283 \ K)} = 4.31x10^{-5} \ \frac{mol}{cm^3}

Sarin diffusivity in air at 10 deg Celsius and 1 atmosphere[16]

D_{AB} = 0.070 \frac{cm^2}{s}

Assume the gas film

(z_2 - z_1) = 0.5 cm

Mole fraction Sarin

y_{A1} = \frac{p_{A1}}{P_{total}}; y_{A2} = 0

From[13a]:

Sarin vapor pressure:

log \ p_A(Torr) = 9.4(\pm 0.1) - \frac{2700 (\pm 40) }{T(K)} \ from \ 0 \ to \ 147 \ deg \ C

log \ p_A(Torr) = 9.4 - \frac{2700}{283} = -0.1406; 10^{log \ p_A} = 10^{-0.1406} = 0.723 \ Torr

Conversion: 0.723 \ Torr(\frac{1 \ atm}{760 \ Torr}) = 9.51x10^{-4} \ atm

y_{A1} = \frac{9.51x10^{-4} \ atm}{1 \ atm} = 9.51x10{-4}

Assume no sarin in the air at a distance away from drop, y_{A2} = 0

For a binary system

y_{B1} = 1 - y_{A1} = 1 - 9.51x10^{-4} = 0.9991;y_{B2} = 1 - y_{A2} = 1 - 0 = 1

y_{B,lm} = \frac{(y_{B2} - y_{B1})}{ln(\frac{y_{B2}}{y_{B1}})} = \frac{(1-0.9991)}{ln(\frac{1}{0.9991})} = \frac{9.0x10^{-4}}{9.52x10^{-4}} = 0.946

The sarin flux

N_{A,z} = \frac{cD_{AB}}{(z_2-z_1)}\frac{(y_{A1}-y_{A2})}{y_{B,lm}} = \frac{(4.31x10^{-5})(0.070)}{0.5}\frac{(9.51x10^{-4} - 0)}{0.946} =2.18x10^{-5} \frac{mol}{cm^2 \ hr}

Water

The moles of water evaporated per square centimeter per unit time may be expressed by[1]

N_{A,z} = \frac{cD_{AB}}{(z_{2}-z_{1})}\frac{(y_{A1}- y_{A2})}{y_{B,lm}}

Total molar concentration, c

PV = nRT; c = \frac{n}{V} = \frac{P}{RT} = \frac{cm^3}{mol}

As before, the gas constant “R” will be calculated at standard temperature and pressure, “STP”

Temperature = 273K; Pressure = 1atm; Molar \ volume= \frac{L}{mol} = 22.4\frac{L}{mol}

Conversion: 22.4 \frac{L}{mol}(\frac{1000 \ cm^3}{1 \ Liters}) = 2.24x10^4 \frac{cm^3}{mol}

R = \frac{PV}{nT} = \frac{(1 \ atm)(2.24x10^4\frac{cm^3}{mol})}{273 \ K} = 82.05 \frac{atm \ cm^3}{mol \ K}

c = \frac{moles}{cm^3} = \frac{P}{RT} = \frac{1 \ atm}{(82.05 \frac{atm \ cm^3}{mol \ K})(283 \ K)} = 4.31x10^{-5} \ \frac{mol}{cm^3}

Water diffusivity in air at 10 deg Celsius and 1 atmosphere[16]

D_{AB} = 0.193 \frac{cm^2}{s}

Assume the gas film

(z_2-z_1) = 0.5 \ cm

Mole fraction of water

y_{A1} = \frac{p_{A1}}{P_{total}}; y_{A2}= \frac{p_{A2}}{P_{total}}

From[4]:

Water vapor pressure:

log_{10} \ P_{vp} = A - \frac{B}{T + C - 273.15}

Constants A, B, C[Appendix A;4], T in kelvins, and pressure is in bar

log_{10} \ P_{vp} = 5.11564 - \frac{1687.537}{283+230.17-273.15} = -1.91518

P_{vp} = 10^{-191518} = 0.0122 \ bars

Conversion: \frac{1 \ atm}{1.01325 bars}(0.0122 \ bars) = 0.012 \ atm; \frac{760 \ mmHg}{1 \ atm}(0.012 \ atm) = 9.11 mmHg

y_{A1} = \frac{p_{A1}}{P_{total}} = \frac{0.012 \ atm}{1 atm} = 0.012

From[2] and relative humidity of 71% (January weather in Iraq)[9]

Partial pressure of water in flowing stream

Relative humidity[2]:

s_r(h_r) = \frac{p_{v}}{p_v^*(T)}x 100\% = 71\%

At 283 K, previous equation gave: p_v^* = 0.012 \ atm

\frac{71\%}{100}(0.012 \ atm) = p_v = p_{A2} = 0.0085 \ atm

y_{A2} = \frac{p_{A2}}{P_{total}} = \frac{0.0085 \ atm}{1 \ atm} = 0.0085

For a binary system

y_{B1} = 1 - y_{A1} = 1 - 0.012 = 0.988; y_{B2} = 1 - y_{A2} = 1 - 0.0085 = 0.992

y_{B,lm} = \frac{(y_{B2} - y_{B1})}{ln(\frac{y_{B2}}{y_{B1}})} = \frac{(0.992 - 0.988)}{ln(\frac{0.992}{0.988})} = 0.990

Molar flux of water

N_{A,z} = \frac{cD_{AB}}{(z_2-z_1)} \frac{(y_{A1} - y_{A2})}{y_{B,lm}} = \frac{(4.31x10^{-5})(0.193)}{0.5} \frac{(0.012 - 0.0085)}{0.990} = 5.88x10^{-8} \ \frac{mol}{cm^2 \ s}

Conversion:

N_{A,z} = 5.88x10^{-8} \frac{mol}{cm^2 \ s}\frac{3600 \ s}{1 \ hr} = 2.12x10^{-4} \ \frac{mol}{cm^2 \ hr}

Molar Flux: Sarin versus water comparison

Sarin: N_{A,z} = 2.18x10^{-5} \ \frac{mol}{cm^2 \ hr}

Water: N_{A,z} = 2.12x10^{-4} \ \frac{mol}{cm^2 \ hr}

Ratio: \frac{Water}{Sarin} = \frac{2.12x10^{-4}}{2.18x10^{-5}} = 9.71

Although the above is a simple evaluation based on “diffusion through a stagnant gas film”[1] and not the most rigorous, the ratio makes since because the ratio of vapor pressures at 10 deg Celsius, “relative volatility”[18], is

\alpha_{water-sarin} = \frac{p_{H_2O}}{p_{C_4H_{10}FO_2P}} = \frac{0.012 \ atm}{9.51x10^{-4} \ atm} = 12.6

Per US Department of Energy[19]

“The evaporation of a liquid depends upon its vapor pressure — the higher the vapor pressure at a given temperature the faster the evaporation — other condition being equal.

The higher/lower the boiling point the less/more readily will a liquid evaporate.”[19]

The boiling points are:

Sarin[14]: 147 deg Celsius; Water[15a]: 100 deg Celsius

Conclusion:

The evaporation of water is greater than the evaporation of sarin.

References:

[1] Welty, James R.; Wicks, Charles E.; Wilson, Robert E. (1984) Fundamentals of Momentum, Heat, and Mass Transfer, Third Edition. New York: John Wiley & Sons.

[2] Felder, Richard M; Rousseau, Ronald W. (1986) Elementary Principles of Chemical Processes, Second Edition. New York: John Wiley & Sons.

[3] Perry, Robert H; Green, Don W. (1997) Perry’s Chemical Engineers’ Handbook, Seventh Edition. New York. McGraw-Hill.

[4] Poling, Bruce E.; Prausnitz, John M.; O’Connell, John P. (2001) The Properties of Gases and Liquids, Fifth Edition. New York: Mcgraw-Hill.

[5] Anton, Howard. Calculus with Analytic Geometry, Fifth Edition. New York: John Wiley & Sons.

[6] Barker, William H; Ward, James E. (1995) The Calculus Companion. Calculus: Howard Anton, Fifth Edition.

[7] Haley, Robert W.; Tuite, James J. Meteorological and Intelligence Evidence of Long-Distance Transit of Chemical Weapons Fallout from Bombing Early in the 1991 Persian Gulf War, December 2012. karger.com[online]. 2012. vol. 40. pp. 160-177. Available from: http://content.karger.com/ProdukteDB/produkte.asp?Aktion=ShowFulltext&ArtikelNr=345123&Ausgabe=257603&ProduktNr=224263 DOI: 10.1159/000345123

[8] Haley, Robert W.; Tuite, James J. Epidemiologic Evidence of Health Effects from Long-Distance Transit of Chemical Weapons Fallout from Bombing Early in the 1991 Persian Gulf War, December 2012. karger.com[online]. vol. 40. pp. 178-189. Available from: http://content.karger.com/ProdukteDB/produkte.asp?Aktion=ShowFulltext&ArtikelNr=345124&Ausgabe=257603&ProduktNr=224263 DOI: 10.1159/000345124

[9] Wikipedia. Baghdad. en.wikipedia.org[online]. 2013. Available from: http://en.wikipedia.org/wiki/Baghdad#Geography_and_climate

[10] Harding, Byron. Diffusivity of Water versus Sarin (Nerve Agent) in Air at 10 Degrees Celsius (50 Degrees Fahrenheit) and 1 Atmosphere, January 2013. chrisbharding.wordpress.com[online]. 2013. Available from: https://chrisbharding.wordpress.com/2013/01/07/test/

[11] Removed

[12] ChemSpider. The free chemical database. Sarin. chemspider.com[online]. 2013. Available from: http://www.chemspider.com/Chemical-Structure.7583.html

[13] Noblis. Chemistry of GB (Sarin). noblis.org[online]. 2013. Available from: http://www.noblis.org/MissionAreas/nsi/ChemistryofLethalChemicalWarfareAgents/Pages/Sarin.aspx

[13a] Noblis. Parameters for Evaluation of the Fate, Transport, and Environmental Impacts of Chemical Agents in Marine Environments. noblis.org[online]. 2012. Available from: http://pubs.acs.org/doi/pdf/10.1021/cr0780098

[14] Wireless Information System for Emergency Responders. WISER. Sarin, CAS RN: 107-44-8. webwiser.nlm.nih.gov[online]. 2013. Available from: http://webwiser.nlm.nih.gov/getSubstanceData.do?substanceID=151&displaySubstanceName=Sarin&UNNAID=&STCCID=&selectedDataMenuItemID=30

[15] The Engineering ToolBox. Water-Density and Specific Weight. engineeringtoolbox.com[online]. 2013. Available from: http://www.engineeringtoolbox.com/water-density-specific-weight-d_595.html

[15a] The Engineering Toolbox. engineeringtoolbox.com[online]. 2013. Available from: http://www.engineeringtoolbox.com/

[16] Harding, Byron. Diffusivity of Water versus Sarin (Nerve Agent) in Air at 10 Degrees Celsius (50 Degrees Fahrenheit) and 1 Atmosphere, January 2013. chrisbharding.wordpress.com[online]. 2013. Available from: https://chrisbharding.wordpress.com/2013/01/07/test/

[17] Harding, Byron. 1991 Gulf War Illnesses and Differing Hypotheses: Nerve and Brain Death Versus Stress, December 2012. gather.com[online] 2012. Available from: http://www.gather.com/viewArticle.action?articleId=281474981824775

[18] Chopey, Nicholas P. (1994). Handbook of Chemical Engineering Calculations, Second Edition. Boston Massachusetts: Mc Graw Hill.

[19] US Department of Energy. Newton: Ask A Scientist.Evaporation and Vapor Pressure. newton.dep.anl.gov[online]. 2012. Available from: http://www.newton.dep.anl.gov/askasci/phy00/phy00130.htm