We have performed smoothed particle hydrodynamics (SPH) simulations to find the response of a gaseous disk to the imposition of moderately strong nonaxisymmetric potentials. The model galaxies are composed of the three stellar components (disk, bulge, and bar) and two dark ones (supermassive black hole and halo) whose gravitational potentials are assumed to be invariant in time in the frame corotating with the bar. We found that the torques alone generated by the moderately strong bar that gives the maximum of the tangential-to-radial force ratio as (FTan/FRad)max=0.3 are not sufficient to drive the gas particles close to the center because of the barrier imposed by the inner Lindblad resonances (ILRs). In order to transport the gas particles toward the nucleus (r<100 pc), a central supermassive black hole (SMBH) and a high sound speed of the gas are required. The former is required to remove the inner inner Lindblad resonance (IILR) that prevents gas inflow close to the nucleus, while the latter provides favorable conditions for the gas particles to lose their angular momentum and to spiral in. Our models that have no IILR show trailing nuclear spirals whose innermost parts reach close to the center in a curling way when the gas sound speed is cs≳15 km/s. They resemble the symmetric two-armed nuclear spirals observed in the central kiloparsec of spiral galaxies. We found that the symmetric two-armed nuclear spirals are formed by hydrodynamic spiral shocks caused by the gravitational torque of the bar in the presence of a central SMBH that can remove IILR when the sound speed of the gas is high enough to drive a large amount of gas inflow deep inside the ILR. However, the detailed morphology of nuclear spirals depends on the sound speed of the gas.