You are on page 1of 3

LYX [Basic] Cheat Sheet

lior.fox@mail.huji.ac.il
November 8, 2014

Basics:

1.1

2
2.1

Document

Function

Preview (PDF)
Enter Math Mode
inline / center math
Insert Title
Insert Author
Section (numbered)
Subsection (numbered)
Insert table
Add row in table
Add column in table
Remove row
Remove column

Math
Basics

Symbol LYX-code shortcut

Keyboard shortcut

6=

Ctrl-r
Ctrl-m
Ctrl-Shift-m
Alt-p-t
Alt-p-Shift-a
Alt-p-2
Alt-p-3
Alt-i-t
Alt-M-w-i
Alt-M-c-i
Alt-M-w-d
Alt-M-c-d

a
b

ab
ab
ab

Pa
Q


...

2.2
1.2

'Pseudocode'

Bold

Emphasis

Underline

noun

\sqrt
\sum
\prod
\int
\infty
\ldots

Sets

Symbol LYX-code

Text

Mode

\neq
\ge
\le
\frac
\cdot

\
4

Shortcut

Insert -> Program Listing


Ctrl-b
Ctrl-e
Ctrl-u
Alt-c-c
1

\cap
\cup
\\
\triangle
\emptyset
\in
\notin
\circ

Alt-m-f
Ctrl-_
Ctrl-^
Alt-m-s
Alt-m-u
Alt-m-i
Alt-m-8

2.3

Logic

Symbol

2.6

Functions

Symbol LYX-code

LYX-code

log
sin
cos
tan
lim
inf
sup
max
min
ker
dim

\neg
\vee
\wedge
\i
\rightarrow
\forall
\exists

2.7
2.4

Greek [only essentials]

Symbol LYX-code
\epsilon
\delta
\Delta
\pi
\varphi
\psi

\log
\sin
\cos
\tan
\lim
\inf
\sup
max
\min
\ker
\dim

Equations

Enter Multiple lines by Ctrl-Enter

shortcut

Alt-m-g-e
Alt-m-g-d
Alt-m-g-D
Alt-m-g-p
Alt-m-g-j
Alt-m-g-y

ac =

bc

a =

Enter Function cases using \cases


(
f (x) =

1 x=1
0 x=
6 1

Enter Matrix by \matrix then edit rows/columns as


in table [see 1.1] [for brackets see 2.8]

a
c
2.5

Special Fonts [examples]


2.8

Symbol
R
C
N
Z
F
F
L
U
P

Useful Misc

Symbol

LYX-code

\mathbb R
\mathbb C
\mathbb N
\mathbb Z
\mathbb F
\mathcal F
\mathcal L
\mathcal U
\mathcal P

{a}
(a)
[a]
hai
|a|
n
k

ab
ab

a text

Shortcut

Alt-m-{
Alt-m-(
Alt-m-[
Alt-m-<
Alt-m-|
\choose
Ctrl-Space
\-Space
Ctrl-m


b
d

Graphs

Macros

Dene your own LYX commands and patterns.


Insert -> Math -> Macro (or the \foo:= icon)
Enter \xymatrix. Add rows/columns like in Matrix Chose macro name, then use 'L X' text box for macro
Y
or Table.
content.
Use \#1, \#2, etc. for macro variables.
3.1

Using XY-Matrix

3.1.1 Frames around elements

Macros are only available in the document after they were dened.

*++[o][F-]\{ELEM}
Where:
Number of + control frame size
[o] makes round-shaped frame
F- means single line [use F= for double line].

These will not be shown in compiled document, so


simply add them on top.

3.1.2 Arrows
Use \ar[direction ] to add arrow in required direction
- denoted in letters u/d/l/r.
For exapmle, \ar[ddl] will add arrow to the element
located 2 rows down and 1 column to the left.
Use \ar@(out,in )[target ] to add curved arrow leaving
current elemnt in out direction, entering to target at
in direction.

3.1.3 Example:
/ v2

v0
W
v1

This is the code used to create the example:


Enter an xymatrix of 2 rows and 3 columns.
The following following code goes in cells (1,1), (1,3),
(2,2) respectively:
*++[o][F-]{v_{0}}\ar[dr]\ar[rr]
*++[F=]{v_{2}}
*++[o][F-]{v_{1}}\ar@(dl,ul)[lu]
3

You might also like