TEXstudio and MiKTEX 代写-LATEX-03
时间:2022-05-15
Statistics 779 Semester 1, 2022 Worksheet 8
Due: 3pm Monday, 16 May 2022
This week’s worksheet will provide you with practice exercises for the material in the LATEX-03 and
LATEX-04 lecture notes.
IMPORTANT: Carefully check that your rendered PDFs resulting from your compiled LATEX files
are identical to the rendered images in the exercises. Full workshop, assignment and test marks are
only awarded when this is the case. You will not be reminded again.
1. (Inline and display mode equations.) Start TEXstudio and create a new file called Mathematics.tex.
Use the article document class with the default settings. Create the following paragraphs using
LATEX.
The equation representing a straight line in the Cartesian plane is of the form ax+ by+ c = 0,
where a, b, and c are constants.
The equation representing a straight line in the Cartesian plane is of the form
ax+ by + c = 0
where a, b, and c are constants.
2. (Standard delimiters, subscripts, superscripts and spaces.) Add the following paragraphs
to the LATEX document from Q1.
In the seventeenth century, Fermat conjectured that if n > 2, then there are no integers x, y,
z for which
xn + yn = zn.
This was proved in 1994 by Andrew Wiles.
It is easily seen that (xm)n = xmn.
The sequence (xn) defined by
x1 = 1, x2 = 1, xn = xn−1 + xn−2 (n > 2)
is called the Fibonacci sequence.
3. (Limits, integrals, common functions and delimiters.) Add additional commands to Mathematics.tex
to create the following paragraphs. Note: Use \dots to produce ....
For n-tuples of complex numbers (x1, x2, . . . , xn) and (y1, y2, . . . , yn) of complex numbers(
n∑
k=1
|xkyk|
)2

(
n∑
k=1
|xk|
)(
n∑
k=1
|yk|
)
1
Thus limx→∞
∫ x
0
(sinx)/x dx = pi/2 and so by definition,∫ ∞
0
sinx
x
dx =
pi
2
.
4. (Extended features with AMS-LATEX.) Add additional commands to Mathematics.tex to
create the following piecewise function
fX(x) =
 x 0 < x ≤ 12− x 1 < x < 2
0 otherwise
and matrix
Q =

−2 2 0 0 0 0
1 −4 1 1 1 0
0 2 −2 0 0 0
0 2 0 −2 0 0
0 2 0 0 −3 1
0 0 0 0 2 −2
 .
5. (Creating tables using the tabular environment.)
(a) Create a new document called Table.tex with document class article. Add commands to
your Table.tex file to produce the following table using the tabular environment.
Distance from sun
(million km)
Planet Maximum Minimum
Mercury 69.4 46.8
Venus 109.0 107.6
Earth 152.6 147.4
(b) Is there anything about this table which you think is not quite right?
(c) Can you provide an improved table?
Hint: Try using \rule[0pt]{0pt}{10pt}
6. (Creating tables the booktabs package.) Consider the following version of the table in Q5
produced using the booktabs package.
Distance from sun
(million km)
Planet Maximum Minimum
Mercury 69.4 46.8
Venus 109.0 107.6
Earth 152.6 147.4
Add commands to your Table.tex file to produce the above table.
Note: Vertical lines should not be used with the booktabs package.
7. (Including graphics, floats and clickable links.)
(a) Open the file called SampleRH.tex. Add a new section titled Graph which is to appear
immediately before the section titled Lists.
2
(b) In this new Graph section, add the text
Here is a graph taken from the STATS 320 Tutorials.
(c) Add the commands needed to include the graph contained in the file PDF-CDF.pdf. Make
sure:
ˆ Appears immediately after the sentence you inserted in Q7b,
ˆ Is the right way up, and
ˆ Is 11.5 centimetres wide.
Process the file and check that the graph has been included correctly.
(d) Edit the commands you added to SampleRH.tex to include the PDF-CDF graphic, as in-
structed in Q7c, so that it becomes a float. Set the position as tb. Check that your LATEX file
compiles without errors. Note: You can use the graph wizard in TEXstudio for this.
(e) Add the commands need to center the graph, with the caption Graph of pdf and cdf and
the label fig:pdf-cdf. Check the result of this alteration.
(f) Change the placement specification to see the effect of other possible specifications.
(g) Add \usepackage{hyperref} to the preamble of SampleRH.tex.
(h) Add the text
The Statistics Department website is at
\url{www.stat.auckland.ac.nz}
at the end of the file.
(i) Process SampleRH.tex again and check that the link to the web page and also the footnote
in the file have become clickable.
8. (Bibliographies and cross-referencing.)
(a) Pick two references from the file latexbibfile.bib and add references to them in SampleRH.tex.
Then, add the commands needed to create a bibliography using BibTEX.
(b) Process the file to produce the bibliography.
(c) Add a cross-reference to the graph in SampleRH.tex.
9. (Customising LATEX.) Change the formatting of top-level enumerated lists to have bold upper-
case Roman numerals with a following colon by adding the following code to the preamble of
SampleRH.tex.
\renewcommand {\ theenumi }{\ bfseries\Roman{enumi }}
\renewcommand {\ labelenumi }{\ theenumi :}
Process SampleRH.tex to produce SampleRH.pdf and confirm that the list numbering in the Lists
section has changed as specified.
Submission Instructions
Upload to Canvas copies of your Mathematics.tex and Mathematics.pdf, Table.tex and Table.pdf,
and SampleRH.tex and SampleRH.pdf.
3


essay、essay代写