美文网首页
在Mac系统下配置和使用Latex中文

在Mac系统下配置和使用Latex中文

作者: 九天学者 | 来源:发表于2018-09-19 02:08 被阅读2491次

    关注九天学者微信公众号(扫码关注)第一时间获取技术贴更新!


    除了表格之外,本人认为Latex写科技文本比word快的多得多。但是原生Latex不支持中文,需要找一些方法克服这个问题。


    相关网站

    安装MacTex

    下载安装MacTex完整版,总共3Gb有余,需要等很久。

    配置中文

    \usepackage{ctex}
    

    使用

    • 统计Pdf字数:pdftotext myfile.pdf - | wc -w

    扩大Latex内存

    当使用pgfplot的时候,大部分时候回出现内存太小的报错。需要将内存设置大一些。
    sudo vim命令打开/usr/local/texlive/2017/texmf.cnf,然后在后面添加下面的命令,然后保存就好啦。

    main_memory = 230000000 % words of inimemory available; also applies to inimf&mp
    extra_mem_top = 10000000     % extra high memory for chars, tokens, etc.
    extra_mem_bot = 10000000     % extra low memory for boxes, glue, breakpoints, etc.
    save_size = 150000    % for saving values outside current group
    stack_size = 150000    % simultaneous input sources
    % Max number of characters in all strings, including all error messages,
    % help texts, font names, control sequences.  These values apply to TeX and MP.
    %pool_size = 1250000
    % Minimum pool space after TeX/MP’s own strings; must be at least
    % 25000 less than pool_size, but doesn’t need to be nearly that large.
    %string_vacancies = 90000
    % Maximum number of strings.
    %max_strings = 100000
    % min pool space left after loading .fmt
    %pool_free = 47500
    

    关注九天学者微信公众号(扫码关注)第一时间获取技术贴更新!


    相关文章

      网友评论

          本文标题:在Mac系统下配置和使用Latex中文

          本文链接:https://www.haomeiwen.com/subject/drkbnftx.html