Hari Sundar | 1 Mar 19:22
Picon
Gravatar

tikz messing up figure labels ?

Hi,

I have a bunch of figures in a paper that I am writing, and two of them use tikz for drawing figures. The others simply include pdf files. For some reason, when I use labels with these figures, figs 1 and 2 (with tikz) are listed as 2,3 in the body of the paper. The labels for the non-tikz figures are labeled correctly.

Any clues ?

~Hari

--
1 (215) 662 7501 (w)
1 (215) 614 0266 (f)
1 (732) 672 1094 (m)

http://www.seas.upenn.edu/~hsundar/

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
pgf-users mailing list
pgf-users <at> lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/pgf-users
Kjell Magne Fauske | 1 Mar 19:43
Picon

Re: tikz messing up figure labels ?

On 3/1/07, Hari Sundar <hsundar <at> gmail.com> wrote:
> Hi,
>
> I have a bunch of figures in a paper that I am writing, and two of them use
> tikz for drawing figures. The others simply include pdf files. For some
> reason, when I use labels with these figures, figs 1 and 2 (with tikz) are
> listed as 2,3 in the body of the paper. The labels for the non-tikz figures
> are labeled correctly.

Where have you placed your labels? TeX sometimes get confused if you
don't place your \label close enough to  \caption. The safest is to
place the label inside the caption like this:

\caption{My figure caption\label{fig:myfig}}

Regards,
Kjell Magne Fauske

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
Michael Chen | 2 Mar 20:06
Picon

computation inside tikz environment?

hi, I searched the manual and mailing list archive and didn't see any
clue. Can we use arithmetic computation among variables defined in
\foreach statement?
\x + \y
\x - \y
\x ** 2 (square)
\x / 2
 It seems that + and / have been reserved in tikz.

what do you do when you need index computation? Thanks.

--

-- 
Michael Chen

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
Kjell Magne Fauske | 2 Mar 21:23
Picon

Re: computation inside tikz environment?

On 3/2/07, Michael Chen <vancouver.michael <at> gmail.com> wrote:
> clue. Can we use arithmetic computation among variables defined in
> \foreach statement?
> \x + \y
> \x - \y
> \x ** 2 (square)
> \x / 2
>  It seems that + and / have been reserved in tikz.
>
> what do you do when you need index computation? Thanks.
>

You can do index computations in different ways. Here are a few examples:
http://www.fauskes.net/pgftikzexamples/combinatorial-graphs/
http://www.fauskes.net/pgftikzexamples/radix2fft/
You can also use the calc package:
http://www.ctan.org/tex-archive/help/Catalogue/entries/calc.html

Regards,
Kjell Magne Fauske

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
Michael Chen | 2 Mar 22:32
Picon

illegal unit of measure

hi, I often get error messege 'illegal unit of measure' in many
innocent situation. For example,

 \foreach \x  in {1,2,3}
 \draw (0,0) circle (\x+1);

Note than I am trying to use simple calculation in "\x + 1", and get
this error of illegal of measure. Manual says 'cm' is the default
unit. But in many other situations, I just can not omit it neither.

Probably this is due to "\x + 1". However the example in the
"combinatorical graphs" uses "(\x-10:3)" without getting any error.
how can I understand these?

Thanks.

Michael Chen

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
Michael Chen | 3 Mar 02:31
Picon

would value list in \foreach statement accept variables?

hi, in the last line of my code, the value list of \foreach statement
is provided via  variables. And the code doesn't run. Error messege is
'illegal unit of measure'. Could anybody explain to me whether or not
the value list accepts variables?  And why I see this error messege?
Thanks in advance.

Michael Chen

----------------------------------------------------------------------------------
%% draw hierarchical basis functions

\foreach \h / \b in {0.5/0, 0.25/-1, 0.125/-2, 0.0625/-3}
{
\foreach \t in {0.6}
%%interval length \h, baseline height \b, triangle height \t 0.6
{
\path[draw] (0 cm,\b cm) -- (1 cm, \b cm);
\path[draw] (0 cm ,\b cm) \foreach \x in {\h, \h + \h,.., 1- \h}
{--(\x, \b + \t)--(\x + \h,\b)};
}
}

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
Alain Matthes | 3 Mar 08:50
Picon
Gravatar

Re: would value list in \foreach statement accept variables?


Le 3 mars 07 à 02:31, Michael Chen a écrit :

> %% draw hierarchical basis functions
>
> \foreach \h / \b in {0.5/0, 0.25/-1, 0.125/-2, 0.0625/-3}
> {
> \foreach \t in {0.6}
> %%interval length \h, baseline height \b, triangle height \t 0.6
> {
> \path[draw] (0 cm,\b cm) -- (1 cm, \b cm);
> \path[draw] (0 cm ,\b cm) \foreach \x in {\h, \h + \h,.., 1- \h}
> {--(\x, \b + \t)--(\x + \h,\b)};
> }
> }
hi,

good is

\foreach \x in {1,2,3}
{\foreach \y in {-\x,\x}
{\draw (0,\x)--(\x cm,\x cm +\y cm);}
}

remark  : ... and not .. and x cm +\y cm because + needs lengths

for your code
with  \usepackage{fp} in the preambule

\foreach \h / \b in {0.5/0, 0.25/-1, 0.125/-2, 0.0625/-3}
{%
\foreach \t in {0.6}
{%
\path[draw] (0 cm,\b cm) -- (1 cm, \b cm);
\FPadd{\hh}{\h}{\h}
\FPadd{\hm}{1}{-\h}
\foreach \x in {\h, \hh,...,\hm}
{\path[draw] (0 cm ,\b cm)--(\x cm, \b cm + \t cm)--(\x cm + \h cm,\b  
cm);}
}
}

expl : \FPadd{\hh}{\h}{\h} here \h is not yet a length

(\x cm, \b cm + \t cm)--(\x cm + \h cm,\b cm)

here \b + \t is impossible you need length for  + of calc
  so b cm + \t cm

I hope this help

Alain Matthes
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
Alain Matthes | 3 Mar 08:54
Picon
Gravatar

Re: illegal unit of measure


Le 2 mars 07 à 22:32, Michael Chen a écrit :

> hi, I often get error messege 'illegal unit of measure' in many
> innocent situation. For example,
>
>  \foreach \x  in {1,2,3}
>  \draw (0,0) circle (\x+1);
>

idem (see other mail)

\foreach \x  in {1,2,3}
{ \draw (0,0) circle (\x cm + 1 cm);}

looks fine (see calc manual )

Alain Matthes
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
Alain Matthes | 5 Mar 18:08
Picon
Gravatar

tikzdeclarecoordinatesystem

Hello

I've some difficulties with this macro.

It is possible with this code

\documentclass[]{article}
\usepackage{tikz,fullpage}
\begin{document}

\begin{tikzpicture}
	\path[coordinate]
	(0,0) coordinate (a)
         (5,3) coordinate (c)
         (-3,5) coordinate (e)
	coordinate (b) at (a |- c)
         coordinate (d) at (a -| c);

% now i would like to use a new coordinate system based
% with a vector ac and vector ae.

% is it possible with tikzdeclarecoordinatesystem ?

\end{tikzpicture}
\end{document}

Greetings Alain

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
Hari Sundar | 6 Mar 15:12
Picon
Gravatar

Compatibility with Acrobat 5.0

Hi,

I recently discovered that some figures I created using pgf/tikz do not render correctly (rather completely) when viewed using Acrobat 5.0.

Is there anyway in which I can ensure that the resulting pdf will be compatible with Acrobat 5.0 ?

thanks,
~Hari

--
1 (215) 662 7501 (w)
1 (215) 614 0266 (f)
1 (732) 672 1094 (m)

http://www.seas.upenn.edu/~hsundar/

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
pgf-users mailing list
pgf-users <at> lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/pgf-users

Gmane