วันอาทิตย์ที่ 12 ธันวาคม พ.ศ. 2553

การใส่คำสั่ง plot ลงใน latex บน ubuntu

เนื่องจาก ubuntu รุ่นใหม่มีปัญหาเกี่ยวกับการทำงานระหว่าง pdflatex กับ gnuplot จึงแก้ปัญหาดังนี้
1. กำหนด --shell-escape --enable-write18 ลงในคำสั่ง pdflatex
2. ที่ /usr/share/texmf/tex/generic/pgf/modules/pgfmoduleplot.code.tex ให้แก้บรรทัดที่ 288 จาก
\xdef\pgf@gnuplot@head#1{set terminal table; set output "#1.table"; set format "%.5f"}
ไปเป็น
\xdef\pgf@gnuplot@head#1{set table; set output "#1.table"; set format "%.5f"}
ก็จะสามารถทำงานได้ครับ

ไม่มีความคิดเห็น: