Understanding secular equation derivation In many basic derivations of the secular equations for the energy of two molecular orbitals from a linear combination of atomic orbitals, we see the following reasoning which I find confusing.

We have a trial wavefunction $\phi = c_a\psi_a + c_b\psi_b$

The energy of the trial wavefunction is 

$$\begin{align} \langle E\rangle &amp;= \frac{\langle \phi | H | \phi \rangle}{\langle \phi | \phi \rangle}\\
&amp;= \frac{c_a^2H_{aa}+2c_a c_b H_{ab} + c_b^2 H_{bb}}{c_a^2 S_{aa} + 2c_a c_b S_{ab} + c_b^2 S_{bb}} \end{align}$$

Where $S_{aa}$ and $S_{bb}$ equal 1. Now per the variational principle, we take the partial derivatives with respect to the coefficients $c_a$ and $c_b$ and set them equal to zero to find the optimal coefficients to minimize $\langle E \rangle$.

But instead, things follow a different route. We take the equation and move the denominator over:

$$
\langle E \rangle (c_a^2 + 2c_a c_b S_{ab} + c_b^2) = {c_a^2H_{aa}+2c_a c_b H_{ab} + c_b^2 H_{bb}}
$$

And then it's stated that this equation is differentiated with respect to $c_a$ and $c_b$ such that

$$
\langle E \rangle(2c_a + 2c_b S_{ab}) + \frac{\partial\langle E\rangle}{\partial c_a} (c_a^2 + 2c_a c_b S_{ab} + c_b^2) = 2c_a H_{aa} + 2c_b H_{ab}
$$

with a similar expression for differentiation wrt $c_b$.

Now the partial derivatives are set to 0, such that you end up with

$$
c_a(H_{aa}-E) + c_b(H_{ab} - ES_{ab}) = 0 \\
c_a(H_{ab}-ES_{ab}) + c_b(H_{bb} - E) = 0
$$

which then you can solve for E.

Is my understanding correct that we've obtained the minimum energies in a single step by first rearranging the equations and then differentiating? Of course we do not obtain values for the coefficients. How is the approach valid?

THe final equations are called the secular equations, which for linear systems isa way of finding the eigenvalues of the system by $A - \lambda I = 0$. But here we have off-diagonal terms $-ES_{ab}$, so I do not see the connection to linear algebra here.
It doesn't matter how you obtain an expression for the partial derivative, as long as you obtain one, and set the partial derivative to zero. The method you described above is probably easier than differentiating the fraction. All the steps that you did are mathematically valid, so your final result is valid. (The "differentiate both sides" step is valid because the equality holds for all values of $c_a$ and $c_b$.)

If you want to, you can differentiate the fraction and you will end up with the same result (i.e. the secular equations). I actually typed the maths out before, so here you go: https://chemistry.stackexchange.com/a/42636/16683 The notation is a tiny bit different, but you should be able to understand it.



As for the linear algebra parallel, the secular equations are only analogous to $Ax = \lambda x$ if you make the additional assumption that $S_{ab} = 0$, in which case $H-ES$ is directly analogous to $A - \lambda I$ (since the overlap matrix is now equivalent to the identity matrix). In this case, the secular equations reduce to $Hc = Ec$.

If you do not make that assumption, then the secular equations take the form of $Hc = ESc$ and the parallel you should draw is to the generalised eigenvalue equation $Ax = \lambda Bx$. The eigenvectors $x$ are said to be the "eigenvectors of $A$ with respect to $B$". There is a lot more information online if you are interested - simply google "generalised eigenvalue".