The spectral problem
−
⟨
∇
,
D
(
x
)
∇
ψ
⟩
=
λ
ψ
-\langle \nabla ,D(x)\nabla \psi \rangle = \lambda \psi
in a bounded two-dimensional domain
Ω
\Omega
is considered, where
D
(
x
)
D(x)
is a smooth function positive inside the domain and zero on the boundary whose gradient is different from zero on the boundary. This problem arises in the study of long waves trapped by the shore and by bottom irregularities. For its asymptotic solutions as
λ
→
∞
\lambda \rightarrow \infty
, explicit formulas are given when
D
(
x
)
D(x)
has a special form that guarantees the complete integrability of the Hamiltonian system corresponding to the Hamiltonian
H
(
x
,
p
)
=
D
(
x
)
p
2
H(x,p)=D(x)p^2
. Since the problem is degenerate, the relevant Liouville tori are not in the standard phase space
T
∗
Ω
T^*\Omega
, but in the “extended” phase space
Φ
⊃
T
∗
Ω
\mathbf {\Phi }\supset T^*\Omega
, while their restrictions to
T
∗
Ω
T^*\Omega
are not compact and “go to infinity” with respect to momenta near the boundary of
Ω
\Omega
. As a result, nonstandard caustics emerge, formed by the boundary or its part, near which asymptotic eigenfunctions are expressed in terms of a Bessel function of composite argument. Standard caustics (within the domain) may also appear, which yield Airy functions in the asymptotics.