Skip to main content

Questions tagged [pgfmathparse]

3 votes
2 answers
39 views

This MWE demonstrates the problem: \documentclass{scrartcl} \usepackage{scrlayer-notecolumn} \usepackage{tikz} \begin{document} %Works fine: \pgfmathparse{hex(1020135)}0x\pgfmathresult %...
lAtExFaN's user avatar
  • 1,173
2 votes
0 answers
116 views

I have encountered (sporadically) comments to the effect that \pgfmathparse, \pgfmathsetlength, and so forth should not be used unless absolutely necessary. For example, it is (I am told) preferable ...
karlh's user avatar
  • 2,206
2 votes
1 answer
488 views

I am quite new to using tikz and the pgf package in general, and I'm having a hard time understanding how/when to use pgfmathsetmacro, pgfmathparse and pgfmathresult. I have the following problem: I ...
Pedro Montanari's user avatar
1 vote
1 answer
166 views

As a Dutch teacher my grading scale goes from 1,0 to 10,0. The calculation of the grade depends on three variables: the N-term; the score of the student; the total number of points for the exam. I ...
KenAdams's user avatar
  • 449
0 votes
2 answers
144 views

This could be a very problematic post so sorry in advance. I am trying to draw a figure using tikz for a manuscript and when I used it, the first time it worked very well. But now I have added some ...
Waxler's user avatar
  • 922
1 vote
1 answer
85 views

I am calculating a value with pgfmathparse, pgfmathroundto and pgfmathresult. It works all fine in normal text mode, but when I call the command in a caption, I get an "Incomplete \iffalse; all ...
asbjos's user avatar
  • 43
2 votes
2 answers
150 views

The subtraction of the calculated height of an input via sbox (in this case = 116.43562 pt) and 17.68 pt gives an incorrect result at the 5th floating point. Here is the full tex file \usepackage[T1]{...
Bilal Yilmaz's user avatar
1 vote
1 answer
142 views

I have a .csv file, which contains values interms of milli(m), femto(f) and micro(u)etc. which I want to process it as float value inside pgfmathparse \begin{filecontents*}{mycsv.csv} Device, betaeff, ...
Raja's user avatar
  • 468
1 vote
3 answers
150 views

I am trying to use a foreach statement to print the powers of 2. I start by defining n as 2 then I print n and multiply it by 2 10 times. The code does compile without errors but the only number I see ...
suf2630's user avatar
  • 11
0 votes
1 answer
142 views

I am trying to plot the product between a Heaviside function and a trigonometric function in the domain [-1,1]x[-1,1] using pgfplots. I can use Mathematica to obtain the required result (see image), ...
aaragon's user avatar
  • 3,153
2 votes
1 answer
252 views

I'm trying to plot a complex function and to that end I'm using pgfmathdeclarefunction. Still, I'm unable to get it to work, I get the error: ! Illegal parameter number in definition of \pgfmathNi@. ...
aaragon's user avatar
  • 3,153
1 vote
1 answer
239 views

I could use some help. I am trying to color a bar chart assigning different colors using a foreach loop and pgfmathresult to get a color gradient. Here is a minimal example: \documentclass{minimal} \...
Florian's user avatar
  • 299
4 votes
1 answer
279 views

My initial problem occurred with this code: \def\a{pi/2} \pgfmathparse{\a r}\pgfmathresult output : 89.99937 When I modified the macro \a thus \def\a{pi} I get the error: Package PGF Math Error: ...
Alain Matthes's user avatar
0 votes
1 answer
176 views

Note: this question is very similar to this one, but differs since I am using float values instead of int. I am auto-generating a LaTeX table with a python script which contains times in decimal hour ...
lug_wrench's user avatar
4 votes
1 answer
342 views

I would like to set draw options in tikz depending on some pgfmath calculations. More specifically, I would like to draw or not draw an edge depending on some value in an array. This works fine if ...
user631620's user avatar

15 30 50 per page
1
2 3 4 5