Solution: Use a simple Perl-script.
I outlined in the link above, what should be done, and discussed some alternatives. Please find some specific Perl code here, which will do the required extraction.
Result:

Read, extract, assemble, put out. Done
#!/usr/bin/perl
use strict; use warnings;
~~~ reading the original Latex-doc ~~~~~~~~~
my $in = "latexOrig.tex"; open F, '<', $in or die "can't open $in\n";
my $out = "latexEq.tex";
my @x = <F>;
my $x = join " ", @x;
~~~ finding equation environments ~~~~~~~~~~
my @l = split/begin{equation*?}/, $x; # splits at begin{...
shift @l; # get rid of preamble etc. from this list (= array)
~~~ finding and removing text after \end{equation... ~~~~
for (my $i = 0; $i < @l; $i++) { # each list item
my @s = split/end{equation*?}/, $l[$i]; # now split at end
$l[$i] = $s[0]; # just keep the equation part
}
~~~ assembling output in Latex-format ~~~~~~~
my $s = '';
foreach my $l (@l) {
$s .= "\begin{equation}"; # we removed it above
$s .= $l; # this is the equation part
$s .= "end{equation}\n\n"; # we removed it above, and Perl left some \
}
~~~ put out ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
open G, '>', $out or die "can't open $out\n";
print G $s;
Step 2: run it from the command shell (DOS, bash, ...)
> ...\TEX-forum\4. eq table>perl extractEq.pl
Will write it into $out, which is set to latexEq.tex, and contains just, i.e. stripped-off all other "noise" within the teachers document:
\begin{equation*}\label{formula 1}
\frac{\partial^{2} f}{\partial x \partial y}=\frac{\partial^{2} f}{\partial y \partial x}.
\end{equation*}
\begin{equation}
F(x)=\int_{a}^{x} f(t) d t \label{formula 2}
\end{equation}
\begin{equation}
\int_{a}^{b} f(t) d t=g(b)-g(a) \label{formula 3}
\end{equation}
I.e. just replace the documents content by an \input statement:
\documentclass[12pt,a4papper]{article}
% this all remains unchanged
\usepackage[T1]{fontenc}
\usepackage[spanish]{babel}
\usepackage{titlesec}
\titleformat{\section}[frame]
{\small}{\filcenter\small
\filleft UNIDAD \thesection \ }
{3pt}{\Large\bfseries\filcenter}
\usepackage[left=2.5cm,top=2cm,right=2.5cm,bottom=1.5cm]{geometry}
\usepackage{amsthm} %para usar \theoremstyle
\usepackage{xcolor}
\usepackage{amsmath}
\usepackage{amsfonts}
\usepackage{amssymb}
\usepackage{graphicx}
\usepackage{thmtools}
\declaretheoremstyle[
spaceabove=7pt, spacebelow=7pt,
headfont=\normalfont\bfseries,
notefont=\mdseries\bfseries\itshape, notebraces={(}{)},
bodyfont=\normalfont\itshape,
postheadspace=.5em, %
numberlike=section,
name=Teorema,
thmbox=M,
%shaded={bgcolor={rgb}{1,1,1}},
headformat=\NAME~\NUMBER \NOTE %
%qed=$\blacksquare$
]{Teorema}
\declaretheorem[style=Teorema]{teo}
% here the new thing starts
\begin{document}
\input{latexEq} % <<< <<< <<<
\end{document}
Pecularities:
A ) From experience and watching programmers it's always a good idea to include use strict and use warnings, which require namespacing variables with my: preventive programming, failing early.
B ) Lists start with @ in Perl. Think of a flexible array. E.g. @x is a list of all code lines found in the opened file, accessible by index 0..n, while $x is it's flattend counterpart, i.e. just one long string.
C ) Finding all the \begin or \end parts is done here by using them as pattern to be matched, to break $x again into substrings. Fragments, not needed, are simply discarded. So after a while @l just has, in this case 3, lines, with whatever amount of Latex-lines of equations in it.
Note: split/end\{equation\*?\}/, matches both end{equation} and end{equation*} ... even Perl needs backslashes from time to time.
Note: If you want to extract other environments, this is your place to change keywords, i.e. matching patterns.
D ) For this example I decided to go without numbering of equations. \label{formula XYZ} is still there for reference, but will not be printed, off course. Modify as required.