Simultaneous estimation of b-values and detection rates of earthquakes for the application to aftershock probability forecasting