Concept:
For the general second-degree equation
\[
Ax^2+Bxy+Cy^2+\cdots=0,
\]
the angle \(\theta\) through which the axes must be rotated to eliminate the \(xy\)-term is given by
\[
\tan 2\theta=\frac{B}{A-C}.
\]
Step 1: Identify the coefficients.
Given equation
\[
ax^2+bxy+y^2=0.
\]
Comparing with
\[
Ax^2+Bxy+Cy^2=0,
\]
we have
\[
A=a,
\qquad
B=b,
\qquad
C=1.
\]
Step 2: Use the condition for removal of the \(xy\)-term.
The axes are rotated through
\[
\theta=\frac{\pi}{8}.
\]
Therefore,
\[
2\theta=\frac{\pi}{4}.
\]
Using
\[
\tan 2\theta=\frac{B}{A-C},
\]
we get
\[
\tan\frac{\pi}{4}
=
\frac{b}{a-1}.
\]
\[
1=\frac{b}{a-1}.
\]
\[
a-1=b.
\]
\[
a=b+1.
\]
Step 3: Write the final answer.
\[
\boxed{a=b+1}
\]