Measuring Active power through current sensors
find the power factor through comparing the signals of the V and I


Hmmm...


  is the total algorithm right or there are problems?


Finding power factor by comparing V and I waveforms is really problematic. Consider the load taken by a typical electronic appliance: -



This is the sort of current shape taken by a bridge rectifier when connected to a reservoir capacitor and load. Cutrrent only passes as the capacitor gets "topped-up" with charge. Using some form of zero cross measurement strategy will not work because of the highly distorted waveform.

If you want to measure power, instantaneously multiply v and i samples then average - this will give you real power into the appliance. But also you need to oversample the fundamental frequency of your AC by a good amount to account the for at least the ninth harmonic. A half decent power measurement device might sample at 1 kHz and sample both v and i simultaneously.


  What are the considerations for the current sensor?


A current transformer (CT) is pretty normal. Hall effect sensors too. No specific recommendations.


  do they produce an AC voltage exactly proportional to the waveform of
  the current?


CT's do when used with the correct burden resistor but, as always, the data in the specific data sheet will always give a better idea.