7k views

### How to write $\pi_1$ [duplicate]

I am writing an article and I need to write the fundamental group. For that we use $\pi_1\left(X,x_0\right)$. However I am arriving at the following error: Use of \pi doesn't match its definition. ...
735 views

### Can new command end with a number? [duplicate]

Possible Duplicate: \newcommand name cannot include numbers, e.g., \Mycomand123 I am trying to define commands \s1, \s2, etc. Right now the the substitution is very simple but the idea would be ...
313 views

29 views

### How to make a new command for inserting an inline matrix? [duplicate]

I know I will be doing many calculations with the basis vectors (1,0) and (0,1) so I'm trying to define a command so I can write this vector inline. However, I'm getting the following error: "LaTeX ...
26k views

### Defining commands/abbreviations that contain numbers

7k views

I am trying to typeset two different tables in a moderately large document. The data for the tables are written as comma-separated values in two different .csv files. I am including the different ...
510 views

### How to create counters with index?

I need to create counters with names like mycounter1, mycounter2,... Basically this should be a counter-valued data array. The code like \newcounter{index} \newcounter{\csname mycounter\the\value{...
318 views

### How to define a command to make new commands with numbers in the name

I'd like to create a command which is currently beyond my capabilities so I was wondering if anyone around here could help me out. What I'm looking to do is define a new command similar to the ...
439 views

### How to create another styling format like \emph

I read how to change \emph and changed it to \DeclareTextFontCommand{\emph}{\bfseries}. Now I want to create another command like \secondstyleformat which I can configure aswell. Such a format could ...
534 views

### Tables as commands

I have to do a little work but I have to use frequently the same settings for a table and I put the following code \newcommand{\tab41}[4]{\begin{center} \begin{tabular}{|c|l||c|l||c|l||c|l|} \hline (...
88 views

### Workaround that allows the use of digits as part of counter names?

I tried to define indexed counters, such as x1, x2, . . . etc, by defining them like this : \newcount\x1, \newcount\x2, . . . etc, but it didn't work. Is there a workaround for this in TeX or LaTeX ? ...
48 views

### How to define a macro with digits in its name using \def and a counter value?

I need a \def whose name involves a number, with that number being value of a counter. \documentclass[varwidth,border=5mm]{standalone} \begin{document} % COUNTER \newcounter{myC} \addtocounter{myC}{...
105 views

### Use Labels to show equations

I want to be able to create many equations, say $a+b=c$ and $c+d=e$, save the equation as a variable but not have the equation be displayed. I simply want to have the ability to use the label/variable ...