Engineering Tools: Scientific Writing with LaTeX and ... · LaTeX and Vector Graphics Fabian Rast...

38
Marc Siegenthaler Yves Schär Engineering Tools: Scientific Writing with LaTeX and Vector Graphics Fabian Rast Part 3: Figures, Bibliographies, and Additional Hints ETH Zürich | 19. September 2019 [email protected]

Transcript of Engineering Tools: Scientific Writing with LaTeX and ... · LaTeX and Vector Graphics Fabian Rast...

Page 1: Engineering Tools: Scientific Writing with LaTeX and ... · LaTeX and Vector Graphics Fabian Rast Part 3: Figures, Bibliographies, and Additional Hints ETH Zürich | 19. September

Marc SiegenthalerYves Schär

Engineering Tools: Scientific Writing with LaTeX and Vector Graphics

Fabian Rast

Part 3: Figures, Bibliographies, and Additional Hints

ETH Zürich | 19. September 2019

[email protected]

100 101−20

−15

−10

−5

0

5

10

15

20

25

Magn

itude (

dB)

Bode Diagram

Frequency (Hz)

Page 2: Engineering Tools: Scientific Writing with LaTeX and ... · LaTeX and Vector Graphics Fabian Rast Part 3: Figures, Bibliographies, and Additional Hints ETH Zürich | 19. September

19. September 2019 Rehabilitation Engineering Laboratory | ETH Zurich

Today: Figures

Export & edit vector graphics

Insert vector elements into a non-vector graphic

Page 3: Engineering Tools: Scientific Writing with LaTeX and ... · LaTeX and Vector Graphics Fabian Rast Part 3: Figures, Bibliographies, and Additional Hints ETH Zürich | 19. September

19. September 2019 Rehabilitation Engineering Laboratory | ETH Zurich

Today: Bibliography

3

Page 4: Engineering Tools: Scientific Writing with LaTeX and ... · LaTeX and Vector Graphics Fabian Rast Part 3: Figures, Bibliographies, and Additional Hints ETH Zürich | 19. September

19. September 2019 Rehabilitation Engineering Laboratory | ETH Zurich

Today: Additional Hints

� 2009 Microchip Technology Inc. Preliminary DS39940C

PIC24FJ64GB004 FamilyData Sheet

28/44-Pin, 16-Bit,Flash Microcontrollers

with USB On-The-Go (OTG)and nanoWatt XLP Technology

� 2009 Microchip Technology Inc. Preliminary DS39940C-page 1

PIC24FJ64GB004 FAMILY

Universal Serial Bus Features:_ USB v2.0 On-The-Go (OTG) Compliant_ Dual Role Capable f can act as either Host or Peripheral_ Low-Speed (1.5 Mb/s) and Full-Speed (12 Mb/s) USB

Operation in Host mode_ Full-Speed USB Operation in Device mode_ High-Precision PLL for USB_ 0.25% Accuracy using Internal Oscillator f No External

Crystal Required_ Internal Voltage Boost Assist for USB Bus Voltage

Generation_ Interface for Off-Chip Charge Pump for USB Bus

Voltage Generation_ Supports up to 32 Endpoints (16 bidirectional):

- USB module can use any RAM location on the device as USB endpoint buffers

_ On-Chip USB Transceiver_ Interface for Off-Chip USB Transceiver_ Supports Control, Interrupt, Isochronous and Bulk Transfers_ On-Chip Pull-up and Pull-Down Resistors

High-Performance CPU:_ Modified Harvard Architecture_ Up to 16 MIPS Operation @ 32 MHz _ 8 MHz Internal Oscillator with 0.25% Typical Accuracy:

- 96 MHz PLL- Multiple divide options

_ 17-Bit x 17-Bit Single-Cycle Hardware Fractional/integer Multiplier

_ 32-Bit by 16-Bit Hardware Divider_ 16 x 16-Bit Working Register Array_ C Compiler Optimized Instruction Set Architecture:

- 76 base instructions- Flexible addressing modes

_ Linear Program Memory Addressing up to 12 Mbytes_ Linear Data Memory Addressing up to 64 Kbytes_ Two Address Generation Units for Separate Read and

Write Addressing of Data Memory

Power Management Modes:_ Selectable Power Management modes with nanoWatt

XLP Technology for Extremely Low Power:- Deep Sleep mode allows near total power-down

(20 nA typical and 500 nA with RTCC or WDT), along with the ability to wake-up on external triggers or self-wake on programmable WDT or RTCC alarm

- Extreme low-power DSBOR for Deep Sleep, LPBOR for all other modes

- Sleep mode shuts down peripherals and core for substantial power reduction, fast wake-up

- Idle mode shuts down the CPU and peripherals for significant power reduction, down to 4.5 �A typical

- Doze mode enables CPU clock to run slower than peripherals

- Alternate Clock modes allow on-the-fly switching to a lower clock speed for selective power reduction during Run mode down to 15 �A typical

Special Microcontroller Features:_ Operating Voltage Range of 2.0V to 3.6V_ Self-Reprogrammable under Software Control_ 5.5V Tolerant Input (digital pins only)_ High-Current Sink/Source (18 mA/18 mA) on All I/O Pins_ Flash Program Memory:

- 10,000 erase/write cycle endurance (minimum)- 20-year data retention minimum- Selectable write protection boundary

_ Fail-Safe Clock Monitor Operation:- Detects clock failure and switches to on-chip

FRC oscillator _ On-Chip 2.5V Regulator_ Power-on Reset (POR), Power-up Timer (PWRT)

and Oscillator Start-up Timer (OST)_ Two Flexible Watchdog Timers (WDT) for Reliable

Operation:- Standard programmable WDT for normal operation- Extreme low-power WDT with programmable

period of 2 ms to 26 days for Deep Sleep mode_ In-Circuit Serial Programmingm (ICSPm) and

In-Circuit Debug (ICD) via 2 Pins_ JTAG Boundary Scan Support

PIC24FJDevice Pi

ns

Prog

ram

Mem

ory

(Byt

es)

SRA

M(B

ytes

)

Remappable Peripherals

I2 CS

10-B

it A

/D(c

h)

Com

para

tors

PMP/

PSP

RTC

C

CTM

U

USB

OTG

Rem

appa

ble

Pin

s

Tim

ers

16-

Bit

Cap

ture

Inpu

t

Com

pare

/PW

MO

utpu

t

UA

RT

w/

IrDA

®

SPI

32GB002 28 32K 8K 15 5 5 5 2 2 2 9 3 Y Y Y Y64GB002 28 64K 8K 15 5 5 5 2 2 2 9 3 Y Y Y Y32GB004 44 32K 8K 25 5 5 5 2 2 2 13 3 Y Y Y Y64GB004 44 64K 8K 25 5 5 5 2 2 2 13 3 Y Y Y Y

28/44-Pin, 16-Bit, Flash Microcontrollers with USB On-The-Go (OTG) and nanoWatt XLP Technology

PIC24FJ64GB004 FAMILY

DS39940C-page 2 Preliminary � 2009 Microchip Technology Inc.

Analog Features:_ 10-Bit, up to 13-Channel Analog-to-Digital (A/D)

Converter:- 500 ksps conversion rate- Conversion available during Sleep and Idle

_ Three Analog Comparators with Programmable Input/Output Configuration

_ Charge Time Measurement Unit (CTMU):- Supports capacitive touch sensing for touch

screens and capacitive switches- Provides high-resolution time measurement and

simple temperature sensing

Peripheral Features:_ Peripheral Pin Select:

- Allows independent I/O mapping of many peripherals- Up to 25 available pins (44-pin devices)- Continuous hardware integrity checking and safety

interlocks prevent unintentional configuration changes_ 8-Bit Parallel Master Port (PMP/PSP):

- Up to 16-bit multiplexed addressing, with up to 11 dedicated address pins on 44-pin devices

- Programmable polarity on control lines- Supports legacy Parallel Slave Port

_ Hardware Real-Time Clock/Calendar (RTCC):- Provides clock, calendar and alarm functions- Functions even in Deep Sleep mode

_ Two 3-Wire/4-Wire SPI modules (support 4 Frame modes) with 8-Level FIFO Buffer

_ Two I2Cm modules support Multi-Master/Slave mode and 7-Bit/10-Bit Addressing

_ Two UART modules:- Supports RS-485, RS-232 and LIN/J2602- On-chip hardware encoder/decoder for IrDA®

- Auto-wake-up on Start bit- Auto-Baud Detect (ABD)- 4-level deep FIFO buffer

_ Five 16-Bit Timers/Counters with Programmable Prescaler

_ Five 16-Bit Capture Inputs, each with a Dedicated Time Base

_ Five 16-Bit Compare/PWM Outputs, each with a Dedicated Time Base

_ Programmable, 32-Bit Cyclic Redundancy Check (CRC) Generator

_ Configurable Open-Drain Outputs on Digital I/O Pins_ Up to 3 External Interrupt Sources

Pin Diagrams

28-Pin SPDIP, SOIC(1)

Legend: RPn represents remappable peripheral pins.Note 1: Gray shading indicates 5.5V tolerant input pins.

2: Alternative multiplexing for SDA1 and SCL1 when the I2C1SEL bit is set.

PIC24FJXXG

B002

MCLR

VSS

VDD

PGED3/AN0/C3INC/VREF+/ASDA1(2)/RP5/PMD7/CTED1/VBUSVLD/VCMPST1/CN2/RA0PGEC3/AN1/C3IND/VREF-/ASCL1(2)/RP6/PMD6/CTED2/SESSVLD/VCMPST2/CN3/RA1

VDDVSS

PGED1/AN2/C2INB/DPH/RP0/PMD0/CN4/RB0

VBUS

SOSCO/SCLKI/T1CK/C2INC/PMA1/CN0/RA4SOSCI/C2IND/RP4/PMBE/CN1/RB4

DISVREGOSCO/CLKO/PMA0/CN29/RA3OSCI/CLKI/C1IND/PMCS1/CN30/RA2 VCAP/VDDCORE

TDI/RP7/PMD5/INT0/CN23/RB7

TDO/SDA1/RP9/PMD3/RCV/CN21/RB9TCK/USBOEN/SCL1/RP8/PMD4/CN22/RB8

AN5/C1INA/DMLN/RTCC/SCL2/RP3/PMWR/CN7/RB3AN4/C1INB/DPLN/SDA2/RP2/PMD2/CN6/RB2

PGEC1/AN3/C2INA/DMH/RP1/PMD1/CN5/RB1

1234567891011121314

2827262524232221201918171615

AN9/C3INA/VBUSCHG/RP15/VBUSST/CN11/RB15AN10/C3INB/CVREF/VCPCON/VBUSON/RP14/CN12/RB14AN11/C1INC/RP13/PMRD/REFO/SESSEND/CN13/RB13VUSB

PGED2/D+/VPIO/RP10/CN16/RB10PGEC2/D-/VMIO/RP11/CN15/RB11

TMS/USBID/CN27/RB5

� 2009 Microchip Technology Inc. Preliminary DS39940C-page 3

PIC24FJ64GB004 FAMILYPin Diagrams

28-Pin QFN(1,3)

Legend: RPn represents remappable peripheral pins.Note 1: Gray shading indicates 5.5V tolerant input pins.

2: Alternative multiplexing for SDA1 and SCL1 when the I2C1SEL bit is set.3: The back pad on QFN devices should be connected to VSS.

10 11

23

6

1

18192021

22

12 13 1415

87

1617

232425262728

9

PIC24FJXXGB00254

MC

LR

VSS

VDD

PGED

3/AN

0/C

3IN

C/V

RE

F+/A

SD

A1(2

) /RP5

/PM

D7/

CTE

D1/

VBU

SVLD

/VC

MPS

T1/C

N2/

RA

0PG

EC3/

AN1/

C3I

ND

/VR

EF-

/ASC

L1(2

) /RP6

/PM

D6/

CTE

D2/

SESS

VLD

/VC

MPS

T2/C

N3/

RA1

VDD

VSS

PGED1/AN2/C2INB/DPH/RP0/PMD0/CN4/RB0

VB

US

SO

SCO

/SC

LKI/T

1CK/

C2I

NC

/PM

A1/C

N0/

RA

4SO

SCI/C

2IN

D/R

P4/P

MBE

/CN

1/R

B4

DISVREGOSCO/CLKO/PMA0/CN29/RA3

OSCI/CLKI/C1IND/PMCS1/CN30/RA2VCAP/VDDCORE

TDI/R

P7/P

MD

5/IN

T0/C

N23

/RB7

TDO/SDA1/RP9/PMD3/RCV/CN21/RB9

TCK

/USB

OE

N/S

CL1

/RP8

/PM

D4/

CN

22/R

B8

AN5/C1INA/DMLN/RTCC/SCL2/RP3/PMWR/CN7/RB3AN4/C1INB/DPLN/SDA2/RP2/PMD2/CN6/RB2

PGEC1/AN3/C2INA/DMH/RP1/PMD1/CN5/RB1

AN9/

C3I

NA

/VBU

SC

HG

/RP1

5/VB

US

ST/C

N11

/RB

15AN

10/C

3IN

B/C

VRE

F/VC

PC

ON

/VB

USO

N/R

P14/

CN

12/R

B14

AN11/C1INC/RP13/PMRD/REFO/SESSEND/CN13/RB13VUSB

PGED2/D+/VPIO/RP10/CN16/RB10PGEC2/D-/VMIO/RP11/CN15/RB11

TMS/

US

BID

//CN

27/R

B5

Insert existing PDFsinto documents

Page 5: Engineering Tools: Scientific Writing with LaTeX and ... · LaTeX and Vector Graphics Fabian Rast Part 3: Figures, Bibliographies, and Additional Hints ETH Zürich | 19. September

19. September 2019 Rehabilitation Engineering Laboratory | ETH Zurich

1. Figures

Page 6: Engineering Tools: Scientific Writing with LaTeX and ... · LaTeX and Vector Graphics Fabian Rast Part 3: Figures, Bibliographies, and Additional Hints ETH Zürich | 19. September

19. September 2019 Rehabilitation Engineering Laboratory | ETH Zurich

Exporting Figures from Matlab

Vector graphic (*.pdf) Raster graphic (*.jpg)

100 101−20

−15

−10

−5

0

5

10

15

20

25

Mag

nitu

de (d

B)

Bode Diagram

Frequency (Hz)

Page 7: Engineering Tools: Scientific Writing with LaTeX and ... · LaTeX and Vector Graphics Fabian Rast Part 3: Figures, Bibliographies, and Additional Hints ETH Zürich | 19. September

19. September 2019 Rehabilitation Engineering Laboratory | ETH Zurich

Exporting Figures from Matlab• It’s a good idea to export images

as vector graphics (e.g. *.pdf):

ü Plots can be scaled without loss of quality

ü Plots can be edited later in a vector graphics editor (Inkscape [freeware]), Illustrator [payware])

ü Keeps file size low

Page 8: Engineering Tools: Scientific Writing with LaTeX and ... · LaTeX and Vector Graphics Fabian Rast Part 3: Figures, Bibliographies, and Additional Hints ETH Zürich | 19. September

19. September 2019 Rehabilitation Engineering Laboratory | ETH Zurich

Exporting figures from Matlab1) Adjust Font Size:

File à Export Setup

• Under Fonts, enter fixed font size (12-14 pt)

• Click Apply to Figure, then click OK

2) Export Plot: File à Save As or click Export in setup window

• Select file format: PDF

• Name the figure and save it

Page 9: Engineering Tools: Scientific Writing with LaTeX and ... · LaTeX and Vector Graphics Fabian Rast Part 3: Figures, Bibliographies, and Additional Hints ETH Zürich | 19. September

19. September 2019 Rehabilitation Engineering Laboratory | ETH Zurich

Adjust PDF paper size

1) In Export Setup, input size of the output you want,

e.g. Width: 15 cm, Height: 12 cm. Then click Apply to Figure.

2) Don't close Export Setup window.

Go to File à Print Preview, input same size in the Width and Height options of the paper size à Refresh

3) Click Close in Print Preview window. Go back to the Export Setup window,

click Export, then select PDF format and save it.

Side note to Mac users:

optional export as *.eps, then open in Preview and save as *.pdf

(but you can also save directly to .pdf)

Page 10: Engineering Tools: Scientific Writing with LaTeX and ... · LaTeX and Vector Graphics Fabian Rast Part 3: Figures, Bibliographies, and Additional Hints ETH Zürich | 19. September

19. September 2019 Rehabilitation Engineering Laboratory | ETH Zurich

… or simply use an export script

• Get current figure size

Quick test:

To save the current Matlab figure as plotXYZ.pdf, type:

figure2pdf(‘plotXYZ’)

Hint: make sure the function path is added in Matlab first!

• Adjust paper size to current figure size

• Export current figure as PDF file

Page 11: Engineering Tools: Scientific Writing with LaTeX and ... · LaTeX and Vector Graphics Fabian Rast Part 3: Figures, Bibliographies, and Additional Hints ETH Zürich | 19. September

19. September 2019 Rehabilitation Engineering Laboratory | ETH Zurich

Edit Vector Graphics with Inkscape

100 101−20

−15

−10

−5

0

5

10

15

20

25

Mag

nitu

de (d

B)

Bode Diagram

Frequency (Hz)

• Edit objects (lines, text)

• Add/remove objects

• Draw lines & shapes

• Change colors (e.g. convert to BW)��

���

����

���

���

��

��

��

��

��

����� ��� �

�� ��������

��������� ����

����

�����

���

���

����

Page 12: Engineering Tools: Scientific Writing with LaTeX and ... · LaTeX and Vector Graphics Fabian Rast Part 3: Figures, Bibliographies, and Additional Hints ETH Zürich | 19. September

19. September 2019 Rehabilitation Engineering Laboratory | ETH Zurich

Inkscape: Vector Graphics Editor

Drawing & Editing Tools

Tool Controls

Status Bar

www.inkscape.org

Page 13: Engineering Tools: Scientific Writing with LaTeX and ... · LaTeX and Vector Graphics Fabian Rast Part 3: Figures, Bibliographies, and Additional Hints ETH Zürich | 19. September

19. September 2019 Rehabilitation Engineering Laboratory | ETH Zurich

Inkscape and Bitmaps

Encoder Brake

Motor

Force Sensor

• Bitmaps can be imported into Inkscape and combined with layers of vector

graphics

• Fonts, lines & arrows are vector based

• Image remains raster image (read: pixels)à use high quality (> 150 dpi)

Encoder Brake

Motor

Force Sensor

Page 14: Engineering Tools: Scientific Writing with LaTeX and ... · LaTeX and Vector Graphics Fabian Rast Part 3: Figures, Bibliographies, and Additional Hints ETH Zürich | 19. September

19. September 2019 Rehabilitation Engineering Laboratory | ETH Zurich

Inkscape: Lines• Draw Line:

• Select the lines tool from the tool box

• Left click to start drawing the line, right click or press Enter to end line tool

• Edit line properties:• With the selection tool active , select the line(s) to edit

(hold shift key to make multiple selections)

• Click the line/shape properties button in the tools control bar

• Edit the line properties in the window on the right (change stroke paint, change stroke style, add arrow heads etc.)

Page 15: Engineering Tools: Scientific Writing with LaTeX and ... · LaTeX and Vector Graphics Fabian Rast Part 3: Figures, Bibliographies, and Additional Hints ETH Zürich | 19. September

19. September 2019 Rehabilitation Engineering Laboratory | ETH Zurich

Inkscape: Text• Create text:

• Select the text tool from the tool box

• Click in the working area where you want to place the text

• Write your text, then exit the text mode with the ESC key

• Edit text properties:• With the selection tool active , select the text filed(s) to edit

(hold shift key to make multiple selections)

• Click the text properties button in the tools control bar

• Edit the text properties in the window on the right (font, size, color etc.)

• Transfer the new properties to the selected text by clicking on

Page 16: Engineering Tools: Scientific Writing with LaTeX and ... · LaTeX and Vector Graphics Fabian Rast Part 3: Figures, Bibliographies, and Additional Hints ETH Zürich | 19. September

19. September 2019 Rehabilitation Engineering Laboratory | ETH Zurich

Inkscape: export *.pdf file• File à Save as

• Name the file

• Select format: *.pdf

• When asked for additional settings:

– Select “Export area is drawing”

(only export area with the drawing; to adjust PDF size to plot)

– If bitmaps were used, adjust “Resolution for rasterization”

to at least 150 dpi

Page 17: Engineering Tools: Scientific Writing with LaTeX and ... · LaTeX and Vector Graphics Fabian Rast Part 3: Figures, Bibliographies, and Additional Hints ETH Zürich | 19. September

19. September 2019 Rehabilitation Engineering Laboratory | ETH Zurich

2. Bibliographies

Page 18: Engineering Tools: Scientific Writing with LaTeX and ... · LaTeX and Vector Graphics Fabian Rast Part 3: Figures, Bibliographies, and Additional Hints ETH Zürich | 19. September

19. September 2019 Rehabilitation Engineering Laboratory | ETH Zurich

BibTeX (.bib)Writing your bibliography by hand is time consuming (both in LaTeX and other word processors)

à Use tools to import and manage your references

Page 19: Engineering Tools: Scientific Writing with LaTeX and ... · LaTeX and Vector Graphics Fabian Rast Part 3: Figures, Bibliographies, and Additional Hints ETH Zürich | 19. September

19. September 2019 Rehabilitation Engineering Laboratory | ETH Zurich

Literature Databases• PubMed/HubMed: www.pubmed.gov

• Google Scholar: scholar.google.com

• IEEE Xplore: http://ieeexplore.ieee.org/Xplore/home.jsp

• Research Collection ETHZ https://www.research-collection.ethz.ch

Page 20: Engineering Tools: Scientific Writing with LaTeX and ... · LaTeX and Vector Graphics Fabian Rast Part 3: Figures, Bibliographies, and Additional Hints ETH Zürich | 19. September

19. September 2019 Rehabilitation Engineering Laboratory | ETH Zurich

PubMed= biomedical literature: find bibtex info with

https://www.bioinformatics.org/texmed/

Page 21: Engineering Tools: Scientific Writing with LaTeX and ... · LaTeX and Vector Graphics Fabian Rast Part 3: Figures, Bibliographies, and Additional Hints ETH Zürich | 19. September

19. September 2019 Rehabilitation Engineering Laboratory | ETH Zurich

Google Scholar= general literature, incl. most peer-reviewed online academic journals

Note: if you don’t see the BibTeX import option, go to Settings à Search results à Bibliography manager à check box to show link

Page 22: Engineering Tools: Scientific Writing with LaTeX and ... · LaTeX and Vector Graphics Fabian Rast Part 3: Figures, Bibliographies, and Additional Hints ETH Zürich | 19. September

19. September 2019 Rehabilitation Engineering Laboratory | ETH Zurich

IEEE Xplore= engineering literature

Page 23: Engineering Tools: Scientific Writing with LaTeX and ... · LaTeX and Vector Graphics Fabian Rast Part 3: Figures, Bibliographies, and Additional Hints ETH Zürich | 19. September

19. September 2019 Rehabilitation Engineering Laboratory | ETH Zurich

Research Collection= database of publications by ETH members

Page 24: Engineering Tools: Scientific Writing with LaTeX and ... · LaTeX and Vector Graphics Fabian Rast Part 3: Figures, Bibliographies, and Additional Hints ETH Zürich | 19. September

19. September 2019 Rehabilitation Engineering Laboratory | ETH Zurich

@book{bishop2006pattern,Author = {Bishop, C.M. and others},Publisher = {Springer New York:},Title = {Pattern recognition and machine learning},Year = {2006}}

@conference{gassert20062dof,Author = {Gassert, R. and Dovat, L. and Lambercy, O. and Ruffieux, Y. and Chapuis, D. and Ganesh, G. and BurdetBooktitle = {Proc IEEE International Conference on Robotics and Automation (ICRA). p},Pages = {3825--3831},Title = {A 2-DOF fMRI compatible haptic interface to interact with arm movements},Year = {2006},

@article{oetiker1995not,Author = {Oetiker, T. and Partl, H. and Hyna, I. and Schlegl, E.},Title = {The not so short introduction to LATEX2$\varepsilon$},Year = {1995},

@article{choset2001coverage,Author = {Howie Choset},Journal = {The Journal of Annals of Mathematics and Artificial Intelligence},Owner = {Andreas Breitenmoser},Pages = {113--126},....

Managing Bibliographies

Page 25: Engineering Tools: Scientific Writing with LaTeX and ... · LaTeX and Vector Graphics Fabian Rast Part 3: Figures, Bibliographies, and Additional Hints ETH Zürich | 19. September

19. September 2019 Rehabilitation Engineering Laboratory | ETH Zurich

Managing Bibliographies

• Win/OS X/Linux: JabRef

jabref.sourceforge.net

• OS X: BibDeskbibdesk.sourceforge.net

Page 26: Engineering Tools: Scientific Writing with LaTeX and ... · LaTeX and Vector Graphics Fabian Rast Part 3: Figures, Bibliographies, and Additional Hints ETH Zürich | 19. September

19. September 2019 Rehabilitation Engineering Laboratory | ETH Zurich

BibDesk

Page 27: Engineering Tools: Scientific Writing with LaTeX and ... · LaTeX and Vector Graphics Fabian Rast Part 3: Figures, Bibliographies, and Additional Hints ETH Zürich | 19. September

19. September 2019 Rehabilitation Engineering Laboratory | ETH Zurich

JabRefUse web-search function to import…

Page 28: Engineering Tools: Scientific Writing with LaTeX and ... · LaTeX and Vector Graphics Fabian Rast Part 3: Figures, Bibliographies, and Additional Hints ETH Zürich | 19. September

19. September 2019 Rehabilitation Engineering Laboratory | ETH Zurich

Import Bibliography in LaTeX Report• Save file from BibDesk or JabRef as BibTeX file

(e.g. myreferences.bib).

• The exported bibliography can be included in the report with the command:

\bibliography{myreferences}

• Compile the BibTeX file first, then compile the LaTeX file twice.

• References will appear in the bibliography as soon as they are cited in the report.

• All BibTex items can be listed in the report’s bibliography

(even if they are not cited) by placing the \nocite{ref} command.

Page 29: Engineering Tools: Scientific Writing with LaTeX and ... · LaTeX and Vector Graphics Fabian Rast Part 3: Figures, Bibliographies, and Additional Hints ETH Zürich | 19. September

19. September 2019 Rehabilitation Engineering Laboratory | ETH Zurich

Bibliography style: plain

Page 30: Engineering Tools: Scientific Writing with LaTeX and ... · LaTeX and Vector Graphics Fabian Rast Part 3: Figures, Bibliographies, and Additional Hints ETH Zürich | 19. September

19. September 2019 Rehabilitation Engineering Laboratory | ETH Zurich

Bibliography style: ieeetr

Page 31: Engineering Tools: Scientific Writing with LaTeX and ... · LaTeX and Vector Graphics Fabian Rast Part 3: Figures, Bibliographies, and Additional Hints ETH Zürich | 19. September

19. September 2019 Rehabilitation Engineering Laboratory | ETH Zurich

Bibliography style: apalike

Page 32: Engineering Tools: Scientific Writing with LaTeX and ... · LaTeX and Vector Graphics Fabian Rast Part 3: Figures, Bibliographies, and Additional Hints ETH Zürich | 19. September

19. September 2019 Rehabilitation Engineering Laboratory | ETH Zurich

Can I create .bib files with other reference managers?

32

In short, yes:

Page 33: Engineering Tools: Scientific Writing with LaTeX and ... · LaTeX and Vector Graphics Fabian Rast Part 3: Figures, Bibliographies, and Additional Hints ETH Zürich | 19. September

19. September 2019 Rehabilitation Engineering Laboratory | ETH Zurich

3. Additional hints

Page 34: Engineering Tools: Scientific Writing with LaTeX and ... · LaTeX and Vector Graphics Fabian Rast Part 3: Figures, Bibliographies, and Additional Hints ETH Zürich | 19. September

19. September 2019 Rehabilitation Engineering Laboratory | ETH Zurich

Include an existing PDF

Page 35: Engineering Tools: Scientific Writing with LaTeX and ... · LaTeX and Vector Graphics Fabian Rast Part 3: Figures, Bibliographies, and Additional Hints ETH Zürich | 19. September

19. September 2019 Rehabilitation Engineering Laboratory | ETH Zurich

pdfpages package• Includes *.pdf files in a report

• \includepdf[<key=val>]{<filename>}

• Various options:

– Select pages to import (pages)

– Rotate pages (angle)

– Multiple pages (nup)

– Scale (scale)

– …

Page 36: Engineering Tools: Scientific Writing with LaTeX and ... · LaTeX and Vector Graphics Fabian Rast Part 3: Figures, Bibliographies, and Additional Hints ETH Zürich | 19. September

19. September 2019 Rehabilitation Engineering Laboratory | ETH Zurich

\includepdf

�!"##$!%&'()'*&+!,-'*.)/)01!2.'3 !"#$%&%'(") 456$$7#8

!"#$%&'(%)*++%,&-./012-3-,45663

!"#$$%&'()*+,%-'.)/0123*4'56757(.6700862

9'.3*:;-*<(%=38%>7*?<=>@1(A*(1(7B1..*CD&*=853(707EF

�!"##$!%&'()'*&+!,-'*.)/)01!2.'3 !"#$%&%'(") 456$$7#89+:0-!;

!*+,-./0-1233-4.56*78

9'%:#";($4<#"%($42=;4.#(>="#;?< =5>!?"3#[email protected],*-9A)!B@,AC!8)D+/&:.E< 4F:/!G)/-!8:+:H/-!I!':.!:'E!:J!-&E*-(!K)JE!)(!L-(&+*-(:/< M)N95+--O!B;3P!%HQJC!:.O!RF//95+--O!B;"!%HQJC!=5>!@+-(:E&).!&.!K)JE!D)O-

< RF//95+--O!=5>!@+-(:E&).!&.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.J< R/:J*!L()0(:D!%-D)(1\9 ;#]###!-(:J-QN(&E-!'1'/-!-.OF(:.'-!BD&.&DFDC9 "#91-:(!O:E:!(-E-.E&).!D&.&DFD9 5-/-'E:H/-!N(&E-!+()E-'E&).!H)F.O:(1

< R:&/95:S-!8/)'^!%).&E)(!@+-(:E&).\9 4-E-'EJ!'/)'^!S:&/F(-!:.O!JN&E'*-J!E)!).9'*&+!RG8!)J'&//:E)(!

< @.98*&+!"3PZ!G-0F/:E)(< L)N-(9).!G-J-E!BL@GC]!L)N-(9F+!,&D-(!BLcG,C!:.O!@J'&//:E)(!5E:(E9F+!,&D-(!B@5,C

< ,N)!R/-X&H/-!c:E'*O)0!,&D-(J!Bc4,C!S)(!G-/&:H/-!@+-(:E&).\9 5E:.O:(O!+()0(:DD:H/-!c4,!S)(!.)(D:/!)+-(:E&).9 WXE(-D-!/)N9+)N-(!c4,!N&E*!+()0(:DD:H/-!+-(&)O!)S!" DJ!E)!"[ O:1J!S)(!4--+!5/--+!D)O-

< 2.98&('F&E!5-(&:/!L()0(:DD&.0f!B285LfC!:.O!2.98&('F&E!4-HF0!B284C!?&:!"!L&.J

< g,UA!>)F.O:(1!5':.!5F++)(E!

!*+,-./J#:%F# !%

';

!"EA"(&46#&E")

K2)>#;L

<M56

K2)>#;L

M#&(II(N$#4!#"%IB#"($;

*,+O

P3C2%>45QJ

KFBL

+E&I("(>E";

!6!Q!<!

MR++

+R69

9<24SR1

M#&(II(N$#

4!%';

R%&#";

4P0C2%>

+(I>="#

*'I=>

+E&

I("#Q!T6

S=>I=>

95MR4GQ

*"J5U

<!*

6"A>##" "a 6"d ad ;P P P P " " " $ 6 h h h h[7A>##" "a [7d ad ;P P P P " " " $ 6 h h h h6"A>##7 77 6"d ad "P P P P " " " ;6 6 h h h h[7A>##7 77 [7d ad "P P P P " " " ;6 6 h h h h

$78%%9!/:;,<(9*/3;,&0-=5,>/?@A?A:3@A006@=,B/35,C4*,D:9E569)A,FDE)G,-:H,:-:AI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

"6

[

;

;a;$"#";

""

;" ;6;7;P

ab

;[;b

"6"7"P"["b"a

$

!*+,-./YY1233,P7

%8MG

Z55

Z44

LAW46QUV#Q862V8QZGWRjQU54U;

K,L QM!ZQL%4bQ8,W4;QZ>=5ZM4QZ8%L5,;Q8V"QGU#

LAW86QUV;Q862V4QZGWR9QU58M;K,L QM!0QL%4[Q8,W4"Q5W55ZM4QZ8%L5,"Q8V6QGU;

Z44

Z55

LAW4;QUV"Q8"2V>Q4LKQM!3QL%4#Q8V7QG>#

Z>=5

5@58@Q58Md2Q,;8dQ8"2V8QL%U;Q8V#QGU7

5@582Q8"2V4QM!-QL%>WQ8V;QG>7

425ZGWA@58@Q8Md@QL%U#Q8V"$QGU6

@582Q8Md2Q8;2V4QL%85;Q8V6#QGU"Z8ULQZ448@GW

,42QM![QL%4PQ2V,#Q8V"6QG>b

,4@Q54U;QM!\QL%46QG8ZQ8V";QG>$

,8dQ=5>@WVQ58M;QM!VQL%47Q8V""QG>a

UVPQ8;2VUQ4%MVQG,88Q58M"QM!]QL%cGQ8VbQG>6UV7Q8;2V>Q4LMVQ54U"QM!,QL%4"Q8V[QG>"LAW8;QUV6Q8"2VUQ4%KQM!PQL%4;Q8VPQG>;

UV$Q862VUQZ>=58KAQM!PZQZ>=55,Q8V;;QG>;P

UV;#Q862V>Q8ZGWRQZ8

L8@VQZ>=5@VQM!P-Q8V;"QG>;7

UV;;Q8;2V8QM!P]QL%G4QGWR@Q5W55WV4Q8V;6QG>;6Z=5>

LAW4"Q4jQZL2@QM!P3Q8V;[QG>;#LAW8"Q49QZ%2@QM!PPQ8V;PQG>;;

,%5Q=5>24QQ8V"bQG>P

Page 37: Engineering Tools: Scientific Writing with LaTeX and ... · LaTeX and Vector Graphics Fabian Rast Part 3: Figures, Bibliographies, and Additional Hints ETH Zürich | 19. September

19. September 2019 Rehabilitation Engineering Laboratory | ETH Zurich

Varia

37

Free LaTeX Add-In for PowerPoint:

http://www.jonathanleroux.org/software/iguanatex/“…allows you to insert equations into your PowerPoint presentation”

Overleaf:

https://www.overleaf.com/“Online collaborative editor with integrated real-time preview.”Beware though: free account makes all documents public!

Beamer Templates

https://www.ethz.ch/services/en/service/communication/corporate-design/templates-for-creative-design/presentation.html

Page 38: Engineering Tools: Scientific Writing with LaTeX and ... · LaTeX and Vector Graphics Fabian Rast Part 3: Figures, Bibliographies, and Additional Hints ETH Zürich | 19. September

19. September 2019 Rehabilitation Engineering Laboratory | ETH Zurich

#Erwartungen/Wünsche/Ziele

38