summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Latex/Latex6/latex_math2beamer.tex6
-rw-r--r--Latex/Latex6/latex_math_biblo_beamer_script.rst53
-rwxr-xr-xTDD/using_python_framework_for_tdd/tdd2_script.rst81
3 files changed, 80 insertions, 60 deletions
diff --git a/Latex/Latex6/latex_math2beamer.tex b/Latex/Latex6/latex_math2beamer.tex
index 4ae4f28..d8ba927 100644
--- a/Latex/Latex6/latex_math2beamer.tex
+++ b/Latex/Latex6/latex_math2beamer.tex
@@ -69,7 +69,8 @@
\label{sec-2}
At the end of this tutorial, you will be able to,
\begin{itemize}
- \item Write and typeset simple mathematical formulae in LaTeX.
+ \item Write simple mathematical formulae in {\LaTeX}.
+ \item Typeset simple mathematical formulae in {\LaTeX}.
\item Write bibliography for a LaTeX document.
\item Make presentations in LaTeX, using beamer.
\end{itemize}
@@ -398,7 +399,8 @@
\label{sec-8}
In this tutorial, we have,
\begin{itemize}
- \item Written and typeset simple math formulae in LaTeX.
+ \item Written simple mathematical formulae in {\LaTeX}.
+ \item Typeset simple mathematical formulae in {\LaTeX}.
\item Written bibliography for a LaTeX document.
\item Made a sample presentations in LaTeX, using beamer.
\end{itemize}
diff --git a/Latex/Latex6/latex_math_biblo_beamer_script.rst b/Latex/Latex6/latex_math_biblo_beamer_script.rst
index 20fe5fb..b98a750 100644
--- a/Latex/Latex6/latex_math_biblo_beamer_script.rst
+++ b/Latex/Latex6/latex_math_biblo_beamer_script.rst
@@ -1,15 +1,20 @@
.. Objectives
.. ----------
-.. By the end of this tutorial, you will be able to
+.. At the end of this tutorial, you will be able to
-.. 1. Write and typeset simple mathematical formulae in LaTeX.
+.. 1. Write simple mathematical formulae in LaTeX.
+.. #. Typeset simple mathematical formulae in LaTeX.
.. #. Write bibliography for a LaTeX document.
.. #. Make presentations in LaTeX, using beamer.
.. Prerequisites
.. -------------
+.. 1. Introduction to LaTeX.
+.. #. Basics of LaTeX and its document structure.
+.. #. Typesetting LaTeX text.
+
.. 1. latex_intro
.. Author : Harish Badrinath < harish [at] fossee [dot] in >
Internal Reviewer :
@@ -36,9 +41,10 @@ formulae, bibliography and presentations, using LaTeX.
.. R2
-.. By the end of this tutorial, you will be able to
+.. At the end of this tutorial, you will be able to
-.. 1. Write and typeset simple mathematical formulae in LaTeX.
+.. 1. Write simple mathematical formulae in LaTeX.
+.. #. Typeset simple mathematical formulae in LaTeX.
.. #. Write bibliography for a LaTeX document.
.. #. Make presentations in LaTeX, using beamer.
@@ -48,32 +54,30 @@ formulae, bibliography and presentations, using LaTeX.
.. R3
-Before beginning this tutorial,we would suggest you complete the tutorials titled
-"Introduction to LaTeX","Basics of LaTeX and its document structure","Basics of
-LaTeX and its documents structure" and "Typesetting LaTeX text".
+Before beginning this tutorial, it is recommended to complete the tutorials
+given in the prerequisite.
.. L4
.. R4
-In general, it is advised to use the AMS-LaTeX bundle to typeset mathematics in
-LaTeX. AMS-LaTeX is a collection of packages and classes for mathematical
+In general, it is advisable to use the AMS-LaTeX bundle to typeset mathematics
+in LaTeX. AMS-LaTeX is a collection of packages and classes for mathematical
typesetting.
-We load amsmath by issuing the \usepackage{amsmath} in the preamble.It must be
-noted that amsmath is included in the base distribution of LaTex, in atleast
+We can load amsmath by issuing the \usepackage{amsmath} in the preamble.It must
+be noted that amsmath is included in the base distribution of LaTex, in atleast
the most recent versions.
-Math formulae can be embedded in two ways. One is inline, and the other way is
- to enclose them in a dedicated environment as and when required.
-The first method is also called text style and second method is also called
-displayed style.
+Math formulae can be embedded in two ways,
+ “inline” or “text style ” method, which is done by enclosing the
+ required command and text within two dollar signs or between an backslash
+ opening bracket and backslash closing bracket.
-In-lining is done by enclosing the required command and text withing two dollar
-signs or between an backslash opening bracket and backslash closing bracket.
+ By enclosing them in a dedicated environment respectively/displayed style.
The most common LaTeX environment used to typeset mathematical formulae is
-from equation family. Its use is given in more detail, further in the tutorial.
+from equation family.
.. L5
@@ -98,8 +102,7 @@ The screen shows the an example, that renders different types of matrices using
LaTeX.
It also shows the two ways in which mathmatical formulae can be embedded into
-LaTeX documents. The second method of embedding mathamtical formula will be
-explained in detail, later in the tutorial.
+LaTeX documents.
Please pause the tutorial and go through the example shown on the screen.
@@ -131,10 +134,9 @@ the sum and int command are specified using the carat and underscore characters
.. R9
-As mention earlier, we can display mathematical formulas in either one of two
-ways. The first was mentioned earlier, now we use the equation environment
-to render mathematical formulae, which are numbered. The equation star
-environment is used to render unnumbered equations.
+We now move onto using the equation environment to render mathematical formulae,
+which are numbered. Another environment called equation star environment renders
+unnumbered equations.
Backslash and opening square bracket and its counterpart the backslash
closing square bracket is a short hand for equation star environment.
@@ -261,7 +263,8 @@ example shown on the screen.
This brings us to the end of this tutorial. In this tutorial, we have,
-.. 1. Written and typeset simple math formulae in LaTeX.
+.. 1. Written simple mathematical formulae in LaTeX.
+.. #. Typeset simple mathematical formulae in LaTeX.
.. #. Written bibliography for a LaTeX document.
.. #. Made a sample presentations in LaTeX, using beamer.
diff --git a/TDD/using_python_framework_for_tdd/tdd2_script.rst b/TDD/using_python_framework_for_tdd/tdd2_script.rst
index ca503f1..d90c5eb 100755
--- a/TDD/using_python_framework_for_tdd/tdd2_script.rst
+++ b/TDD/using_python_framework_for_tdd/tdd2_script.rst
@@ -44,44 +44,44 @@ At the end of this tutorial, you will be able to,
.. R3
-Before beginning this tutorial,we would suggest you to complete the
+Before beginning this tutorial,we suggest you to complete the
tutorial on "Test driven development-part 1".
.. R4
-To test ``fibonacci`` function we have used two test cases.
+To test ``fibonacci`` function, we have used two test cases.
It is inconvenient to repeatedly change the test conditions in
-the fibonacci.py file.Each time a new test case is added it
-introduces a 'if' statement too.
-So it is good practice to write the test cases in a separate file.
-The file will contain multiple lines,each line for separate test case,
-each line consist of two comma separated values,
-first column is the integer value which has to be passed to the function
- and the second column is the return value from the function.
+the fibonacci.py file. Each time a new test case is added, it
+introduces an 'if' statement too.
+So, it is a good practice to write the test cases in a separate file.
+This file contains multiple lines, each line representing a test case.
+Each line consists of two comma separated values in which the
+first column is the integer value that has to be passed to the function.
+ The second column is the return value from the function.
.. L4
-{{{ Switch to slide4 ,Persistent test cases,(after 3 seconds) show the
- fibonacci_testcases.dat file}}}
+{{{ Switch to slide4 ,Persistent test cases, (after 3 seconds) show the
+fibonacci_testcases.dat file}}}
.. R5
-Lets open the same fibonacci.py file which we have used in our
-previous tutorial.Change the code to use fibonacci_testcases.dat
+Let us open the fibonacci.py file which we have used in our
+previous tutorial. Now, change the code to use 'fibonacci_testcases.dat'
file for test cases.
.. L5
{{{ Switch to slide5, Modify fibonacci.py , show the modified
- fibonacci.py file}}}
+fibonacci.py file}}}
.. R6
-Save the fibonacci.py file. Go to terminal and run
+Save the fibonacci.py file. Switch to terminal and run
``python fibonacci.py``. It should pass all the tests.
@@ -95,9 +95,9 @@ Save the fibonacci.py file. Go to terminal and run
.. R7
So far we have used simple repetitive tests.
-Now we will see how ``Python testing frameworks`` can do the
+Now, let us see how ``Python testing frameworks`` does the
same job efficiently.
-Python provides two frameworks for testing code, unittest and
+Python provides two frameworks for testing code: unittest and
doctest.
.. L7
@@ -106,25 +106,25 @@ doctest.
.. R8
-Let us first see how doctest works.
+First, let us see how doctest works.
A docstring is used to document function. Along with the
description, interactive interpretor session's input and
output are also added.
-When executed doctest module pick up all such interactive
+When executed, the doctest module picks up all such interactive
examples, executes them and determines if the code runs
as documented.
.. L8
-{{{switch to slide7 for 3 seconds and move to to slide8,
+{{{switch to slide7 for 3 seconds and move to slide8,
Doctest for fibonacci.py}}}
.. R9
-To initiate doctest we need to import doctest module.
+To initiate doctest, we need to import the doctest module.
Testmod automatically picks all sample sessions, executes
them and compares with the documented output.
-Doctest doesn't give any output when all test pass,
+Doctest doesn't give any output when all the tests pass,
it complains only when any test fails.
.. L9
@@ -133,9 +133,9 @@ it complains only when any test fails.
.. R10
-Let us run doctests by typing ``python fibonacci.py``.
+Let us run doctest by typing ``python fibonacci.py``.
As all tests pass, doctest doesn't give any output.
-For more detailed information we can run with -v argument.
+For detailed information, we may run the file with -v argument.
Run as ``python -v fibonacci.py``.
.. L10
@@ -150,21 +150,23 @@ Run as ``python -v fibonacci.py``.
So far we have seen doctest, which is simple to use. But when
it comes to automate the process, unittest is better.
-Unittest initializes code and data, it aggregate
+Unittest initializes code and data, it aggregates
tests into collections and improves reporting.
.. L11
-{{{ switch to slide-11, Unittest }}}
+{{{ Switch to slide-11, Unittest }}}
.. R12
To run unittest on our fibonacci function let us create a
new file ``test_fibonacci.py``. This new file will host the
-test code. To begin unittesting let us subclass
- the TestCase class in unittest. We need fibonacci.py
- and fibonacci_testcases.py files too.
+test code.
+To begin unittesting let us subclass the TestCase class
+in unittest. We need fibonacci.py and fibonacci_testcases.py
+files too.
+
.. L12
@@ -173,14 +175,27 @@ test code. To begin unittesting let us subclass
.. R13
+The ``setUp`` function will read all the test data and store
+it in a list test_cases. The ``test_fibonacci`` function
+consists the actual test code. And the third function ``tearDown``
+deletes the data from test_cases
+and closes ``fibonacci_testcases.dat`` file.
+
+.. L13
+
+{{{ Show slide13(stay for 3 seconds) and switch to slide14 }}}
+
+
+.. R23
+
This brings us to the end of the tutorial.In this tutorial,
- we have learnt to,
+we have learnt to,
- 1. Undestand the basic steps involved in Test driven development.
+ 1. Understand the basic steps involved in Test driven development.
#. Design a Test driven approach for a given ``fibonacci`` function.
-.. L13
+.. L23
{{{ switch to slide-13,Summary }}}
@@ -213,5 +228,5 @@ Thank you!
.. L16
-{{{ Switch to slide-16, Thankyou}}}
+{{{ Switch to slide-16, Thank you}}}