1

Once I had decided to change all the occurrences of the variable 'a' in formulas to 'b'. This was really a pain, because the search (find) tool had no option to limit the search of the letter a to formulas (whatever is between $ or $$ or \( or \[ ...). Which is why I am asking the question that is the title of this post.

7
  • On TeXstudio you can search change your search to whole words, but depending on how you wrote the formulas, this might not work... Dec 23 '19 at 0:46
  • IMHO the best solution is searching for the $ and [ in the document and then look if in the equation finded there is the variable you are looking for. A more powerful, but more complex solution would be to import your .tex file as a string in WolframMathematica and then use the very powerful pattern matching capability of Mathematica.
    – vi pa
    Dec 23 '19 at 12:17
  • Thank you @vipa for your work-arounds. The first one might be what I ended up doing, I don't remember exactly. For the second solution, I can't afford Mathematica. I much would prefer to use an editor which has the option I'm referring to.
    – Arnaud
    Dec 23 '19 at 19:40
  • Thanks @EduardoAlvesdaSilva . Does the whole word option consider _ and ^ as non-characters? Note that I still would get all the words 'a' in the text, and in English there's a lot.
    – Arnaud
    Dec 23 '19 at 19:44
  • @Arnaud yeah, it does not consider, and you're right, it probably would work better the other way around (switching from b's to a's) Dec 23 '19 at 20:51

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.