MATLAB: How to find all the indices (especially of the repeating elements) of an array in terms of another array

ecgindexingintersectrepeating valuessignal processing

I am working on R2016a version. I need to find the indices of an array(smax_PVCuw) in terms of another array(ecg5) in order to mark smax's values on ecg5 signal. I am using intersect for this purpose.
[cc1,cc2,cc3]=intersect(smax_PVCuw,ecg5)
cc3 gives me smax_PVCuw values interms of ecg5 signal(more than 10000). The main problems here is that smax_PVCuw(47 elements) here has 6 repeating elements. Due to this, cc3 has only 42 elements(due to the repetition of an element 6 times,it is considered as one single element) . Can anybody suggest an alternative for intersect ?