  Star formation estimates based on the counting of YSOs is commonly applied to
nearby star-forming regions in the Galaxy. With this method, the SFRs are
measured using the counts of YSOs in a particular protostellar Class, a typical
protostellar mass, and the lifetime associated with this Class. However, the
assumptions underlying the validity of the method such as that of a constant
star formation history (SFH) and whether the method is valid for all
protostellar Classes has never been fully tested. In this work, we use Monte
Carlo models to test the validity of the method. We build synthetic clusters in
which stars form at times that are randomly drawn from a specified SFH. The
latter is either constant or time-dependent with a burst like behavior. The
masses of the protostars are randomly drawn from an IMF which can be either
similar to that of the Milky Way field or be variable . For each star in every
cluster, the lifetimes associated with the different protostellar classes are
also randomly drawn from Gaussian distribution functions centered around their
most likely value as suggested by the observations. We find that only the SFR
derived using the Class 0 population can reproduce the true SFR at all epochs,
and this is true irrespective of the shape of the SFH. For a constant SFH, the
SFR derived using the more evolved populations of protostars (Classes I, F, II,
and III) reproduce the real SFR only at later epochs which correspond to epochs
at which their numbers have reached a steady state. For a time-dependent
burst-like SFH, all SFR estimates based on the number counts of the evolved
populations fail to reproduce the true SFR. We also show how the offsets
between Class I and Class II based SFRs and the true SFR plotted as a function
of the number ratios of Class I and Class II versus Class III YSOs can be used
in order to constrain the SFH of observed molecular clouds.
