Lorem ipsum (LI) dolor sit amet, consectetur AE. Donec in ultricies dui, eu aliquet turpis. In non fermentum arcu. Nunc sodales eros sit amet dictum hendrerit. Integer ut lectus velit. Lorem ipsum (LI) pellentesque lacinia. Nulla mauris elit, adipiscing elit (AE) lobortis vitae consequat in, semper et lorem.

I need to find occurrences of abbreviations that are either:

  1. used before their first definition, or
  2. defined more than once

By 'defining an abbreviation', I mean manually adding the abbreviation within parentheses directly after the full phrase (as in Notepad), without any LaTeX methods.

Is there a TeX Live package, or an external script for this?

  • without an example document to test it is very hard to guess an answer, what mechanism are you using to define the acronyms? Commented Mar 12, 2018 at 17:20
  • I edited the question. No LaTeX mechanism is used to define the abbreviations.
    – Orion
    Commented Mar 12, 2018 at 17:32
  • normally such things are done using a macro that automatically handles different presentation of the first use, rather than doing it by hand and then searching for such use. Commented Mar 12, 2018 at 18:22
  • Thanks, I completely agree (e.g., the glossaries package). The question is more relevant when LaTeX is not used in the first place!
    – Orion
    Commented Mar 12, 2018 at 18:31
  • if the question is how to search to find such idioms in a plain text file without any tex markup to mark definitions and use of acronyms, I think it's off topic, I don't see how tex can help at all. You will need perl or python or lua or some other regular expression plain text search tool Commented Mar 12, 2018 at 18:36


You must log in to answer this question.

Browse other questions tagged .