Tex系列: pgfplots安装
2016-06-15 20:59
387 查看
(1) 上网下载最新宏包压缩包
http://sourceforge.net/projects/pgfplots/files/pgfplots/
(2)解压压缩包,把该包下的tex子目录拷贝至D:\texmf\ 下,全部覆盖即可。
(3)重建TeX文件名数据库,执行DOS命令: texhash --admin
用pdflatex编译文档的过程中,可能由于绘图数据过多导致内存使用超出TeX内存大小上限,从而编译失败,解决办法就是指定更大的内存空间,步骤如下:
1. 打开DOS命令窗口
2. 在DOS命令窗口中输入
initexmf --edit-config-file=pdflatex
3. 在自动打开的编辑器中输入
main_memory=20000000
然后存盘文件, 关掉编辑器.
4. 在DOS命令行, 输入
initexmf --dump=pdflatex
注: 同样的办法也适用于latex.
比如编译下面的文档:
[cpp] view plain copy
\documentclass[a4paper]{article}
\usepackage{pgfplots}
\usepgfplotslibrary{colormaps}
\pgfplotsset{compat=newest}
\usepackage[graphics,tightpage,active]{preview}
\setlength{\PreviewBorder}{5pt} \PreviewEnvironment{tikzpicture}
\begin{document}
\begin{tikzpicture}
\begin{axis}[title=$120 \times 120$ Smooth Surface, xlabel=$x$, ylabel=$y$]
\addplot3[surf,samples=120,shader=interp,domain=0:1] {
sin(deg(8*pi*x))* exp(-20*(y-0.5)^2) + exp(-(x-0.5)^2*30-
(y-0.25)^2 - (x-0.5)*(y-0.25))
};
\end{axis}
\end{tikzpicture}
\end{document}
如果TeX内存上限太小,就会导致编译失败。按上述设置可编译通过。结果如下:
from: http://blog.csdn.net/mathsoperator/article/details/6819561
http://sourceforge.net/projects/pgfplots/files/pgfplots/
(2)解压压缩包,把该包下的tex子目录拷贝至D:\texmf\ 下,全部覆盖即可。
(3)重建TeX文件名数据库,执行DOS命令: texhash --admin
用pdflatex编译文档的过程中,可能由于绘图数据过多导致内存使用超出TeX内存大小上限,从而编译失败,解决办法就是指定更大的内存空间,步骤如下:
1. 打开DOS命令窗口
2. 在DOS命令窗口中输入
initexmf --edit-config-file=pdflatex
3. 在自动打开的编辑器中输入
main_memory=20000000
然后存盘文件, 关掉编辑器.
4. 在DOS命令行, 输入
initexmf --dump=pdflatex
注: 同样的办法也适用于latex.
比如编译下面的文档:
[cpp] view plain copy
\documentclass[a4paper]{article}
\usepackage{pgfplots}
\usepgfplotslibrary{colormaps}
\pgfplotsset{compat=newest}
\usepackage[graphics,tightpage,active]{preview}
\setlength{\PreviewBorder}{5pt} \PreviewEnvironment{tikzpicture}
\begin{document}
\begin{tikzpicture}
\begin{axis}[title=$120 \times 120$ Smooth Surface, xlabel=$x$, ylabel=$y$]
\addplot3[surf,samples=120,shader=interp,domain=0:1] {
sin(deg(8*pi*x))* exp(-20*(y-0.5)^2) + exp(-(x-0.5)^2*30-
(y-0.25)^2 - (x-0.5)*(y-0.25))
};
\end{axis}
\end{tikzpicture}
\end{document}
如果TeX内存上限太小,就会导致编译失败。按上述设置可编译通过。结果如下:
from: http://blog.csdn.net/mathsoperator/article/details/6819561
相关文章推荐
- canvas_时钟
- java之修改并选择显示SQL Server数据库中的数据
- Application.DoEvents()的作用
- Android之BroadcastReceiver(二):接收系统广播
- ThinkPHP模板
- pgfplots画二维图真的很方便,多例比较
- 设置div居中
- 摄影
- 编辑距离
- Linux C程序异常退出怎么办——core文件帮你忙
- 【Codewars】判断括号是否有效 validParentheses
- MySQL日志四种日志
- Linux 用户管理之用户管理与组管理
- 解决intellij idea新建maven项目,加载archetype模型很慢
- git当移动文件与更改文件共存Please enter a commit message to explain why this merge is necessary
- Ranklib部分源码分析
- OKHTTP通信使用(三)HTTPS
- Java关键字final、static使用总结
- Maven常用命令
- 傅里叶变换是用来做什么的,具体举例一下应用?