【latex】入门篇

1下载安装

百度搜索“CTex:项目”,下载套装,最近版本是2.9.2

安装完成后,打开WinEdt就可以使用LaTex排版文章了。

2文章排版

/documentclass{article}
/begin{document}
This is the body of the article
/end{document}

3排版例子

1、 如果是中文,将/documentstyle{article}改为 /documentstyle{carticle}

2在文本中插入公式,一般是两种方式,分别为$$ 和 \( \)

 

\documentclass{article}%文档类型

  \author{sereny}  %作者

  \title{Hello World}%标题

  \usepackage{amsmath} %公式

 

 \usepackage{amssymb}  %公式

  \usepackage{graphicx}%图片

\begin{document}   %文档开始

  \maketitle   %标题的位置

  \tableofcontents    %目录

  \section{Hello China}China is in East Asia.

    \subsection{HelloBeijing} Beijing is the capital of China.

      \subsubsection{HelloDongcheng District}

       \paragraph{Tian'anmen Square}is in the center of Beijing

         \subparagraph{Chairman Mao} is in the center of Tian'anmen Square

      \subsection{HelloGuangzhou}

        \paragraph{SunYat-sen University} is the best university in Guangzhou

        %6----\\:换行,,两个空格换行,但是两个空格也可以新段落前面空两格

 Beijing is

  the capital

  of China.

 

  New York is

 

  the capital

 

  of America.

 

  Amsterdam is \\ thecapital \\

  of Netherlands. \\\\\\\\

%7.数学公式

The Newton's first law is F=ma.\\

  The Newton's second lawis $F=ma$.  %公式用$$包含,两个$$ $$表示居中, \[  \]也是居中

  The Newton's third lawis$$F=mb$$\\

  The Newton's forth lawis \[F=mc\]\\

  Greek Letter $\eta$ and$\mu$\\

  Fraction$\frac{a}{b}$  \\

  Power $a^b$ \\

  Subscript $a_b$   $a_{b}$\\

  Derivate $\frac{\partialy}{\partial t} $ $\frac{\partial_{y}}{\partial_{t}}$\\

  Vector $\vec{n}$   \\

  Bold $\mathbf{n}$ \\

  To time differential$\dot{F}$  \\

  Matrix (lcr here meansleft, center or right for each column) %矩阵

 

  $$

    \left[  %左括号

      \begin{array}{lcr}%lcr对齐方式?array

        a1 & b22 &c333 \\

        d444 & e555555& f6

      \end{array}

    \right]

  $$

 

Equations(here \& is the symbol for aligning differentrows)%&是对其标识。bd

\begin{align}%align??

  a+b&=c\\

  d&=e+f+g

\end{align}

 

\[

  \left\{  %大括号

    \begin{aligned}  %aligned??

      &a+b=c\\

      &d=e+f+g

    \end{aligned}

  \right.

\]

 

%%8图片

\includegraphics[height=3.00in]{figure.eps}

%9表格

\begin{tabular}{|c|c|}

    a & b \\

    c & d\\

  \end{tabular}

 

  \begin{tabular}{|c|c|}

    \hline

    a & b \\

    \hline

    c & d\\

    \hline

  \end{tabular}

 

 

%居中

  \begin{center}

    \begin{tabular}{|c|c|}

      \hline

      a & b \\ \hline

      c & d\\

      \hline

    \end{tabular}

  \end{center}

 

 

\begin{figure}

  \centering

  % Requires\usepackage{graphicx}

 \includegraphics[width=5]{figure.eps}\\

  \caption{eps}\label{2}

\end{figure}

 

 

\end{document}

 

 

 


  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值