zoukankan      html  css  js  c++  java
  • latex学习

    第一段代码

    documentclass{article}
    usepackage{ctex}
     
    egin{document}
    
    section{文字}
    特可爱模板
    section{数学}
    [
        a^2=b^2+c^2
    ]
    end{document}

     第二段代码

    documentclass[UTF8]{ctexart}
    
    	itle{杂谈勾股定理}
    author{张三}
    date{	oday}
    
    ibliographystyle{plain}
    
    egin{document}
    
    maketitle
    	ableofcontents
    section{勾股定理在古代}
    section{勾股定理的近代形式}
    ibliography{math}
    
    end{document}

     第三段代码

    documentclass[UTF8]{ctexart}
    usepackage{amsmath}
    usepackage{amsfonts}
    usepackage{amsthm}
    usepackage{graphicx}
    usepackage{amssymb}
    usepackage{bm}
    usepackage{titlesec}
    usepackage{graphicx}
    usepackage{booktabs}
    usepackage{multirow}
    usepackage{booktabs}
    usepackage{subfig}
    usepackage{hyperref}
    usepackage{fancyhdr}
    usepackage{pdfpages}
    usepackage{hyperref}
    usepackage{geometry}
    usepackage{CJK}
    
    	itle{杂谈勾股定理}
    author{张三}
    date{	oday}
    
    ibliographystyle{plain}
    
    egin{document}
    
    maketitle
    	ableofcontents
    section{勾股定理在古代}
    section{勾股定理的近代形式}
    
    ibliography{math}
    
    end{document}

     《latex入门》第一章

    documentclass[UTF8]{ctexart}
    
    %导言区开始
    usepackage{graphicx}
    usepackage{float}
    usepackage{amsmath}
    usepackage{geometry}
    %usepackage[format=hang,font=small,textfont=it]{caption}
    
    %geometry{a6paper,centering,scale=0.8}
    
    
    ewtheorem{thm}{定理}%声明
    	itle{heiti 杂谈勾股定理}
    author{kaishu 张三}
    date{	oday}
    
    ibliographystyle{plain}
    
    %导言区结束
    
    egin{document}
    maketitle
    
    egin{abstract}
    这是一篇关于勾股定理的小短文
    end{abstract}
    
    	ableofcontents
    section{勾股定理在古代}
    section{勾股定理的近代形式}
    ibliography{math}
    ......见于欧几里得footnote{欧几里得,约公元前330--275年。}《几何原本》的.....
    
    ......的整数成为emph{勾股数}
    
    ......答周公问:
    egin{quote}
    勾广三,股修四,径隅五。
    end{quote}
    又载陈子(约公元前7--6世纪)答荣方问:
    egin{quote}
    zihao{-5}kaishu 
    若求邪至日者,以日下为沟,日高为股,勾股各自乘,并而开方除之,得邪至日。
    end{quote}
    都较古希腊更早。......
    egin{thm}[勾股定理]
    直角三角形斜边的平方等于两腰的平方和。
    
    可以用符号语言表述为......
    end{thm}
    
    egin{equation}
    a(b+c)=ab+ac
    end{equation}
    
    $angle ACB =pi /2$
    
    egin{equation}
    AB^2=BC^2+AC^2
    end{equation}
    
    $2^{10}=1024$
    $90^circ$
    $A_{5}$
    
    egin{tabular}{|rrr|}
    hline
    直角边$a$&直角边$b$ &斜边$c$ \
    hline
    3 & 4 & 5\
    5 & 12 & 13\
    hline
    end{tabular}
    
    egin{table}[H]%usepackage{float},不浮动
    egin{tabular}{|rrr|}
    hline
    直角边$a$&直角边$b$ &斜边$c$ \
    hline
    3 & 4 & 5\
    5 & 12 & 13\
    hline
    end{tabular}
    qquad
    ($a^2+b^2=c^2$)
    end{table}
    
    egin{equation}label{eq:gougu}
    AB^2=BC^2+AC^2
    end{equation}
    
    
    满足式eqref{eq:gougu}的整数称为emph{勾股数}
    
    café quad Gödel quad Antonín Dvořák
    χα
    
    ``\,`A' or `B?'\,'' he asked.
    
    She $dots$ she got it.
    
    egin{enumerate}
        item 中文
        item English
        item Francais
    end{enumerate}
    
    egin{quote}
    学而时习之,不亦说乎?
    有朋自远方来,不亦乐乎?
    end{quote}
    
    egin{quote}
    学而时习之,不亦说乎?
    有朋自远方来,不亦乐乎?
    end{quote}
    
    egin{itemize}
        item 中文
        item English
        item Francais
    end{itemize}
    
    egin{description}
        item[中文] 中国的语言文字
        item[English] The  language of England
        item[Francais] La lanue de France
    end{description}
    
    end{document}

     第4段

    documentclass[UTF8]{ctexart}
    usepackage{amsmath}
    usepackage{mathdots}
    usepackage{mathtools}
    usepackage{breqn}
    usepackage{amsfonts}
    
    egin{document}
    [ A=
    egin{pmatrix}
    a_{11} & a_{22} & a_{13} \
    0 & a_{22} & a_{23} \
    0 & 0 & a_{33}
    end{pmatrix}
    ]
    
    [ A=egin{bmatrix}
    a_{11} & dots & a_{1n} \
    & ddots & vdots \
    0 & 0 & a_{nn}
    end{bmatrix}_{n	imes n}
    ]
    
    复数$z=(x,y)$也可用矩阵(
    ( egin{smallmatrix}
    x & -y\ y &x
    end{smallmatrix} )
    )来表示
    
    [
    sum_{substack{0<i<n \0<j<i}} A_{ij}
    ]
    
    [
    ordermatrix{
        & 1 & 2 & 3 cr
     1 & A & B & C cr
     2 & D & E & F cr} 
    ]
    
    $e^{pi i}+1=0$
    
    [
    mathcal{F}(x) =sum_{k=0}^infty
         oint_0^1 f_k(x,t) \,mathrm{d}t
    ]
    
    [ int f(x) \,mathrm{d} x ]
    
    
    ewcommanddiff{\,mathrm{d}}
    [ iintlimits_{0<x,y,z<1} f(x,y,z) diff x diff y diff z]
    
    $cos 2x = cos(x+x) = cos^2x -sin^2x$
    
    
    ewcommanddefeq{stackrel{	ext{d}}{=}}  %stackrel产生堆叠的效果
    $f(x) defeq ax^2+bx+c$
    
    [   A xleftarrow{0<x<1} B xrightarrow[x leq 0]{x geq 1} C ]
    \
    $x=y implies x+a=y+a$ \
    $x=y impliedby x+a=y+a$ \
    $x=y iff x le y And x ge y$
    
    [  a mathbin{heartsuit} b = b mathbin{heartsuit} a ]
    
    
    ewcommandvarnotin{%   %这里为什么要加%呢?需要查阅一下,应该是间隔的问题
        mathrel{overline{in}}}
    $forall x$,$forall S$,$xvarnotin S$
    
    
    ewcommand*abs[1]{lvert#1
    vert}
    $abs{x+y} le abs{x} +abs{y}$
    
    [
    partial_x partial_y left[
    frac12 left( x^2+y^2 
    ight)^2 +xy
    
    ight]
    ]
    
    
    [ left.
    int_0^x f(t,lambda) \,mathrm{d}t
        
    ight |_{x=1},qquad
    lambda in
        left[frac12,infty 
    ight).    ]
    [
        Pr left( X>frac12
        middle| Y=0 
    ight)
    = left.
        int_0^1 p(t)\,mathrm{d}t
        middle/ (N^2+1) 
    ight.
    ]
    
    [
    iggl( sum_{i=1}^n A_i iggr) cdot
    iggl( sum_{i=1}^n B_i iggr) >0
    ]
    
    $1+ Bigl( 2-igl(3 	imes (4 div 5) igr) Bigr)$
    [ P= iggl< frac12 iggr>,qquad
    M=left< egin{matrix}
    a&b \ c & d\
    end{matrix} 
    ight> 
    ]
    
    $a:b=ac:bc$
    [ Pr(xcolon g(x)>5) = 0.25,
        qquad gcolon x mapsto x^2 ]
    [ (1,dots,n) qquad 1+dots+n qquad a=dots=z ]
    
    egin{align}
     &(a+b)(a^2-ab+b^2) 
    otag \
     ={} & a^3-a^2b+ab^2+a^2b-ab^2 +b^2 
    otag \
     ={} & a^3 +b^3 
     end{align}
     
     egin{flalign}
     x &= t &x &=2 \
     y &= 2t & y &=4
     end{flalign}
     
     egin{alignat}{2}
     x&=sin t&quad &	ext{水平方向} \
     y&=cos t& &	ext{垂直方向}
     end{alignat}
     
     egin{align*}{2}
    x^2+2x&=-1
    intertext{移项得}
    x^2+2x+1&=0
    end{align*}
    
    设$G$是一个带有运算$*$的集合,则$G$是emph{群},当且仅当:
    egin{subequations}label{eq:group}
    egin{alignat}{2}
    forall a,b,c &in G, &qquad (a*b)*c &=a*(b*c);label{subeq:assoc} \
    exists e, forall a &in G, & 3*a &= a;\
    forall a ,exists b &in G, & b*a&=e.
    end{alignat}
    end{subequations}
    式~eqref{eq:group} 的三个条件中,eqref{subeq:assoc}~又称为结合律
    
    egin{multline}
    a+b+c \
    +d+e+f\
    +g+h+i\
    +j+k+l
    end{multline}
    
    egin{equation}
    egin{split}
    cos 2x &= cos^2x-sin^2x\
    &=2cos^2x-1
    end{split}
    end{equation}
    
    egin{dmath}
    frac12(sin(x+y) +sin(x-y)) =frac12(sin xcos y+cos x sin y)+frac12(sin xcos y-cos xsin y)=sin x cos y)
     end{dmath}
     
     egin{equation}
     D(x)=egin{cases}
     1,& 	ext{if } x in  mathbb{Q};\
     0,& 	ext{if }  x in mathbb{R} setminus mathbb{Q}.
     end{cases}
     end{equation}
     
     [ 
     leftlvert x-frac12 
    ight
    vert
     =egin{dcases}
     x-frac12,& x geq frac12;\
     frac12-x,& x<frac12.
     end{dcases}
     ]
     
    end{document}
  • 相关阅读:
    Git一些简单但非常重要并常用的操作命令
    利用fastjson解析json并通过js&ajax实现页面的无跳转刷新
    利用Graphviz绘制逻辑关系依赖图
    oracle导入.dmp文件
    Linux查找当前目录5天的文件并打包
    Web安全相关(三):开放重定向(Open Redirection)
    Web安全相关(二):跨站请求伪造(CSRF/XSRF)
    Web安全相关(一):跨站脚本攻击(XSS)
    密码学应用(DES,AES, MD5, SHA1, RSA, Salt, Pkcs8)
    行为驱动开发(BDD)实践示例
  • 原文地址:https://www.cnblogs.com/elpsycongroo/p/8451372.html
Copyright © 2011-2022 走看看