This may sub-optimal but definitely a start. I would find the zero crossings of each as a vector of 1's and 0's and add them. Then find the sum of them.
x_index = ZeroCrossing(x);
x1_index = ZeroCrossing(x1);
x2_index = ZeroCrossing(x2);
sum_index = x_index+x1_index+ x2_index ;
ZC_index = (sum_index == 3);
function x = ZeroCrossings(x)
x(x>0) = 1;
x(x<0) = 0;
x = abs(diff(x));
Hope that gives you some idea! I am certain others will have better way of doing it!
I think the above code should work, but I haven't tested it!! So, please be advised!