Questions tagged [definition]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
14
votes
2answers
457 views

Trying to understand the definition of \newcommand (complex handling of parameter tokens)

I'm still trying to understand how exactly tex parses documents. This time I'm trying to understand all the parameter-tokens-handling in \newcommand and friends, which looks like black magic to me - ...
3
votes
0answers
68 views

How is TeX/LaTeX parsed?

I have some questions about TeX/LaTeX parser and parsing TeX/LaTeX after reading the following: Limitations when parsing TeX as a context-free grammar This is a PEG parser, which means it ...
2
votes
1answer
33 views

Defining `\subsetcong` and `\subsetsim` via proper tilde over and under `\subset`

I'd like to define a new command \subsetcong that would typeset a tilde over \subseteq to make it look similar to how tilde is over = in \cong. And also, I'd like to define \subsetsim to mean a \...
1
vote
5answers
98 views

Align sentences beneath each other. Like ruler in word!

Essentially, I want to be able align the non-bold sentences underneath each other. In word I would use a ruler. As you would if you ignored all the underlines Canonical Ensemble: System with fixed ...
1
vote
0answers
16 views

Listing theorems or definitions

I followed this Marking the end of a definition to create an specific environment definition for my theorems. Is there any easy way of listing all declared definitions/theorems? I want a list similar ...
0
votes
1answer
42 views

Theorem/Definition/… with individual numbering

I would like to give the theorem/lemma/definition/... environment an individual number. For example: 1 Section Theorem 20.1. (XXX) ... Definiton 21.2.1.: ... Here is the "20.1." and "21.2....
0
votes
1answer
29 views

How do I create multiple definition boxes in Beamer?

I wanted to create a particular slide in beamer. Please find below the pic for the same. How do I do it? Thank you.
2
votes
1answer
71 views

How to delete a counter?

I am trying to delete a counter in my ".sty" file. Right now I have a few ".tex" files that use the same ".sty". They use the same ".sty" file to use \newcommands. However, when I go to make a new ...
0
votes
1answer
53 views

How can I get the Definition and Theorem environment like these in LaTeX package SVMono?

How can I get the Definition and Theorem environment like these in LaTeX package SVMono ?
1
vote
0answers
47 views

How to change the style of an environment

How would I display my definition as Definition 1.1 (Flow map)^1. (^1 is meant to be superscript and denotes a footnote). This is my code \documentclass[11pt,a4paper]{article} \usepackage{amsmath}...
3
votes
1answer
48 views

Editing a word in a sty file

I want to edit a word in a .sty file. I'm learning Latex and I don't know if it can be edited by using \makeatletter and \makeatother commands in the preamble. The .sty file (novel-PostLayout, from ...
1
vote
1answer
58 views

Random start of definition?

I'm currently writing my bachelor thesis and suddenly there's this random text "ärbung2.0.14" on the front page...I can't locate where its coming from. Does it look like its a counter for a definition ...
0
votes
2answers
42 views

Definitions for sections, subsections and subsubsections (+chapter?)

I want to change the commands of the article/ book class and want to know how sections, especially in the article class but also in the book class, are defined. I think it is something like this?: \...
3
votes
2answers
193 views

Why \countdef, \dimendef, and alike require custom-named register to be empty before assignment?

Why \dA can't be assigned a value before it is assigned to \dB? \documentclass[varwidth,border=5mm]{standalone} \begin{document} \newdimen\dA \dimendef\dB\dA % ERROR IF PRECEDED BY NEXT LINE \...
4
votes
2answers
143 views

What definition takes up more memory, \def or \chardef (considering \def contains a single character)?

The question is entirely in the title. Let's take \def\testName{a} and \chardef\testName`\a. Which of the definitions requires more memory?
1
vote
1answer
51 views

How does \newcommand work? Making easier color command

I'm trying to write an easier color command \c{} that is shorter and easier to use than \color{}. However, I do not want to overwrite an existing command, so I will use \providecommand{}[]{} to create ...
0
votes
1answer
89 views

How to write to the right of “Definition” and also enumerate within the definition?

The answer here shows how to enumerate within a definition. But what if I want to also write something to the right of Definition? For example, Definition. Let G be a group. (i) .... (ii) .... ...
7
votes
1answer
280 views

How do I get the hue, saturation and brightness values from a color?

I want to define a new colour (myorange) by changing the hue value of a previously given colour (oldcolour), thus maintaining its original saturation and brightness. Is there a way for doing this? I ...
0
votes
2answers
28 views

Define Terminology Within Document

Similar to the \newtheorem*{dfn}{Definition} statement, is there a way to define words in a document in this fashion, but instead of Definition. This is the definition being shown, it will show up ...
3
votes
2answers
69 views

Expand \def in \write18

I have defined the following command: \newcommand{\formatcommand}[1]{ \def\temp{#1} \def\s{\ifx\temp\empty empty\else not empty\fi} echo "\s" } This works correctly: \formatcommand{} \...
0
votes
0answers
7 views

How to add a new glossary, and what do the meta-endings mean?

\documentclass{article} \usepackage{glossaries} \newglossary[what]{type}{what}{what}{\normalsize A Title} \makeglossaries \newglossaryentry{let bob = electron} {type=type, name = name, ...
1
vote
1answer
45 views

Defining command part by part 2

This question is an extension to Defining command part by part thread. Let's say we have a command \foo with 1 argument. Can we produce a command \setfoo{aaa}{<some stuff>} which redefines \foo ...
2
votes
2answers
68 views

How to undefine a command with arguments?

I am trying to define \d as \delta in mathmode, but apparently \d is defined as a dot below and it needs an argument: \d{a} would give an a with a dot below. How can I do this? Here are the packages I ...
1
vote
1answer
634 views

Use of ___ doesn’t match its definition [duplicate]

I am returning to LaTeX after a bit of a hiatus. Currently running Mac OS High Sierra (10.13.16) and TexShop 4.26. In the past, I have used the following definition command % In pre-amble \def\m3{m$...
1
vote
1answer
50 views

Evaluation problem with the label/reference mechanism

I am defining a computation environment which defines a bunch of equations. Each equation has a number and I want to print that number. To generate automatically the correct number, I use the label/...
1
vote
1answer
51 views

Clear xcolor color definition

I'm trying to create a command that creates colour palettes from a partially complete set of defined colours. In order to make sure the palette is complete I use lines like this to use a fallback ...
0
votes
0answers
88 views

“Use of \i doesn't match its definition” on arxiv

I'm trying to submit a preprint to Arxiv. The paper compiles fine on my machine, but when submit it, I get the following error: ! Use of \i doesn't match its definition. \MT@orig@add@accent ...@...
0
votes
1answer
48 views

How can I write a “definition” like this?

The theorem of the picture is written in bold, I mean: Theorem 1.2 (Pythagorean theorem). I want to write a definition with that format. Also, it would be better if it's written with small capitals. ...
1
vote
2answers
59 views

Create definitions of symbols using LateX

I am trying to create legend for fraction some text \[Y = \frac{X_{A}}{X_{AB}}\] $\begin{array}{l l} X_{A}: & \text{Lorem Ipsum is simply dummy text of the printing and typesetting ...
0
votes
0answers
44 views

Validating command with in command

I have planed to create SIunits based macro to support SIunits package in my XML conversion process. In this process i have found few issues while handing the \per command i have tried the following ...
3
votes
1answer
42 views

Second Argument to be set as Options

I have produced the below macros for generating the custom acronym \def\myacro#1[#2]#3{% \newcounter{#1}% \expandafter\edef\csname#1Acrshort\endcsname{#2} \expandafter\edef\csname#1Acrlong\endcsname{#...
1
vote
2answers
59 views

Vertically centering text on all pages of document

I have formatted one page of my document in a particular way. (including alignments) Now I want to have that particular setting for every page of my document. This would have been very easy if the ...
1
vote
1answer
48 views

Definition before \multicolumn or the like?

Is it possible to have definitions take effect at the beginning of the first cell of a tabular row (using array.sty, if relevant), and still leave room for \multicolumn, \hline, etc.? The problem is, ...
7
votes
1answer
70 views

Use of \noexpand in the implementation of \TextOrMath for eTeX

In latexrelease 2015/01/01, there are two implementations of \TextOrMath: one for regular TeX, the other one for eTeX-like engines (more precisely: those which support \protected). My question ...
1
vote
1answer
47 views

How to retain actual input newline/end-of-line (hex 0x0a) in macro definition

I am using filecontents package and want to include it in a macro in order to factorize some complex processing. The problem is that \begin{filecontents} needs be followed by nothing except spaces and ...
1
vote
1answer
48 views

How can I cancel Math-mode, which is inside a function, from the outside?

So the problem is simple. A function takes something and puts it inside math-mode ($$). Can I influence that from the outside? Example: \documentclass{article} \def\mathmod#1{$#1$} \begin{document} ...
1
vote
0answers
3k views

What does \fi means? [duplicate]

I want to know the meaning of \fi in LaTeX. I don't understand the use. And don't find an easy definition online.
0
votes
0answers
31 views

New command and catcode [duplicate]

I have a command that may contain the ampersand charater: &. Sometimes, when I use this command, I want that ampersand interpreted as a space. This is why I wanted to use the TeX command \catcode. ...
0
votes
0answers
89 views

mapsto and function definition / definition environment [duplicate]

Ok, these are 2 questions in one, but they are different. I am trying to define a function f mapping from X to Y. So what i am doing is: open the equation environment and writing: $f:X{\rightarrow}Y$....
5
votes
2answers
142 views

Including default parameter into \def

I'm using the classic thesis style with the \graffito command (example here). How can I modify the command below to add some vertical spacing before the text which is set to a standard value by ...
0
votes
1answer
103 views

clean up definition file

I've got a problem with my custom definitions-file. The file has hundreds of command definitions (with \newcommand or \renewcommand; mainly shortcuts for mathematical terms, programm names,...). I ...
3
votes
3answers
115 views

what .bib files do for bibtex, is there something for \href?

I wasn't even sure how to formulate this question, nor the appropriate tags, so there may be some editing or even deletion if this is a stupid question... But I think it is a feature that people would ...
1
vote
2answers
145 views

Conflict with \fi in figure captions

I have the following preamble: \documentclass[11pt]{book} % PACKAGES % graphics packages \usepackage{graphics} \usepackage[pdftex]{graphicx} % negative phantoms (\nphantom, \nhphantom, \...
4
votes
2answers
207 views

Define macro as wrapper for parameters of a command

I'm trying to define a macro that is a little wrapper to a common parameter of a command. The macro is expanded, but the parameter is not taken into account by the command. The macro, \sp is used ...
1
vote
1answer
41 views

Problem inserting data in table using multiple files with catchfile

I have multiple data from different files that I want to use in the body of tabular environment. I saw a solution here, but the method only works for one such file only. If the following was done \...
0
votes
1answer
333 views

Command with or without parameter

How to define a command \def\hello{Hello world!} that can be called with no parameter: \hello or with a parameter: \hello{3} but that won't be displayed anyway (3 shouldn't be displayed, it's ...
2
votes
1answer
68 views

Include a graphics but without modifying the layout (i.e. add an image behind text)

I'd like to define a command \mark that would add an image mark.png : on the same vertical coordinate than the current text at 1cm from left border without modifying the layout, i.e. if I remove this ...
1
vote
1answer
708 views

What is the difference between \leftmark and \rightmark in fancyhdr?

I am having a hard time trying to figure out the difference between \leftmark and \rightmark in fancyhdr. At page 8 of the documentation, it says The \leftmark contains the Left argument of the ...
3
votes
1answer
451 views

How to make a definition list in TeX

I want to make a list similar to the following in HTML, but in LaTeX: <dl><dt>Foo</dt> <dd>Bar</dd> <dd>Baz</dd> <dt>Things I do</dt> <dd>...
1
vote
1answer
92 views

How to link to the references in the definition?

I want to add a link to the definition to a research from where I have took the definition. I have tried but it is not working. \documentclass[parskip=full, 12pt]{article} \newtheorem{theorem}{...