如何在x轴上显示π符号? [英] How to show π symbol on x axis?

查看:86
本文介绍了如何在x轴上显示π符号?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我无法在x轴上添加简单的π"符号时感到沮丧.我搜索了很多解决方案,有什么用:

Feel frustrated when I cannot add a simple "π" symbol on x axis. I searched lots of solution and there is what I use:

set terminal postscript eps enhanced
set output "test.eps"
set xrange [-2*pi:2*pi]
set sample 600
set xtics pi
set mxtics 2
set xtics ("-2{/Symbol P}" -2*pi, "-{/Symbol P}" -pi, "0" 0, "{/Symbol P}" pi, "2{/Symbol P}" 2*pi)

x轴上没有π"!我的代码有错吗?还是我错过了任何可能的包裹?请参阅下面的xlabel:

There is no "π" on the x axis! Am I wrong with any codes? or I missed any possible packages? Please see the xlabel below:

更新:我尝试了许多方法,包括设置终端增强功能,但仍然无法正常工作.而且我只是发现我的mac Preview(pdf查看器)不能正确显示字符(如下图所示).我相信这就是原因,我仍在努力.

Update: I tried lots of methods including set terminal enhanced, but still doesn't work. And I just find that my mac Preview (pdf viewer) doesnt show character correctly (pic below). I believe that's the reason and I m still working on it.

在此处输入图片描述

推荐答案

我遇到了同样的问题,并找到了解决方法.如果我从Inkscape中的gnuplot中打开生成的eps文件,然后再次将其另存为eps文件,则pi字符将按原样呈现.我只是使用基本导入,而不是Poppler,但是这两者都值得尝试.如果然后使用预览"打开新的eps文件,则pi字符在那里.

I experience the same problem and found a workaround. If I open the resulting eps file from gnuplot in Inkscape and save it as eps file again, the pi character renders as it should. I just use the basic import, not the Poppler, but it's worthy experimenting with both. If I then open the new eps file with Preview, the pi characters are there.

这篇关于如何在x轴上显示π符号?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆