TeX - LaTeX Asked on February 24, 2021
I have found new ways to optimally create some references to the main equations and therefore to the subequations.
I have so far written about 200 pages of a free student book and I would like to make some changes to the equations and sub equations that I have already written, but this is simpler.
The biggest problem is to change all the references in the part where he writes the explanations to the equations, this puts me in a bad mood. is there a way to automatically change references? I give a small example:
documentclass{article}
usepackage[english,italian]{babel}
usepackage{amsmath}
usepackage[colorlinks]{hyperref}
usepackage{lipsum}
%https://tex.stackexchange.com/questions/101002/interrupting-and-resuming-subequations
%https://tex.stackexchange.com/questions/225517/subequations-with-main-equation-number
makeatletter
defuser@resume{resume}
defuser@intermezzo{intermezzo}
%
newcounter{previousequation}
newcounter{lastsubequation}
newcounter{savedparentequation}
setcounter{savedparentequation}{1}
%
renewenvironment{subequations}[1][]{%
defuser@decides{#1}%
setcounter{previousequation}{value{equation}}%
ifxuser@decidesuser@resume
setcounter{equation}{value{savedparentequation}}%
else
ifxuser@decidesuser@intermezzo
refstepcounter{equation}%
else
setcounter{lastsubequation}{0}%
refstepcounter{equation}%
fifi
protected@edeftheHparentequation{%
@ifundefined {theHequation}theequation theHequation}%
protected@edeftheparentequation{theequation}%
setcounter{parentequation}{value{equation}}%
ifxuser@decidesuser@resume
setcounter{equation}{value{lastsubequation}}%
else
setcounter{equation}{0}%
fi
deftheequation {theparentequation alph{equation}}%
deftheHequation {theHparentequation alph{equation}}%
ignorespaces
}{%
% arabic{equation};arabic{savedparentequation};arabic{lastsubequation}
ifxuser@decidesuser@resume
setcounter{lastsubequation}{value{equation}}%
setcounter{equation}{value{previousequation}}%
else
ifxuser@decidesuser@intermezzo
setcounter{equation}{value{parentequation}}%
else
setcounter{lastsubequation}{value{equation}}%
setcounter{savedparentequation}{value{parentequation}}%
setcounter{equation}{value{parentequation}}%
fifi
% arabic{equation};arabic{savedparentequation};arabic{lastsubequation}
ignorespacesafterend
}
makeatother
begin{document}
begin{center}
textbf{OLD OPTION}
end{center}
In elementary algebra, the quadratic formula is a formula that provides the solution(s) to a quadratic equation. There are other ways of solving a quadratic equation instead of using the quadratic formula, such as factoring (direct factoring, grouping, AC method), completing the square, graphing and others.[1]
Given a general quadratic equation of the form
begin{subequations}
begin{equation}
ax^2+bx+c=0 label{eq10a}
end{equation}
end{subequations}
with x representing an unknown, textit{a}, textit{b} and textit{c} representing constants with $aneq 0$, the quadratic formula is:
begin{subequations}[resume]
begin{equation}
x = frac{-b pm sqrt{b^2 - 4ac}}{2a}label{eq10b}
end{equation}
end{subequations}
Here are some references: eqref{eq10a}, eqref{eq10b}
begin{center}
textbf{NEW OPTION}
end{center}
In elementary algebra, the quadratic formula is a formula that provides the solution(s) to a quadratic equation. There are other ways of solving a quadratic equation instead of using the quadratic formula, such as factoring (direct factoring, grouping, AC method), completing the square, graphing and others.[1]
Given a general quadratic equation of the form
begin{subequations}label{eq10}
begin{equation}
ax^2+bx+c=0 tag{ref{eq10}}
end{equation}
end{subequations}
with x representing an unknown, textit{a}, textit{b} and textit{c} representing constants with $aneq 0$, the quadratic formula is:
begin{subequations}[resume]
begin{equation}
x = frac{-b pm sqrt{b^2 - 4ac}}{2a}label{eq10:a}
end{equation}
end{subequations}
Here are some references: eqref{eq10}, eqref{eq10:a}
end{document}
to change the references I should use the "FIND" and it is too long and cumbersome work, is there a way to have a database of the labels and which can be changed automatically in the written part of the mathematical explanations?
Get help from others!
Recent Questions
Recent Answers
© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP