I have two matrix such as
X1=[0.316227766016838 0.346410161513775
0.509901951359279 0.529150262212918
1.63401346383682 1.63707055437449
2.28035085019828 2.37276210354093
3.24961536185438 4.78330429724056
4.96689037527506 5.00199960015992
5.06655701635736 6.06959636219741
6.07782855960910 9.43292107461946
9.61145150328503 10 ]
X2=[0.223606797749979 0.223606797749979
0.447213595499958 0.458257569495584
2.11423745118660 2.14242852856286
2.22485954612870 2.27815714997890
3.24653661614959 3.24807635378234
3.28329103187640 4.72652091923859
4.91121166312347 4.94064773081425
5.00299910053960 6.06959636219741
6.07865116617165 9.61093127641645
9.78110423214066 10]
I need to know the common ranges between X1 and X2 if it exist. Dimensions of X1 and X2 are not same
For example (3.28329103187640 4.72652091923859) range is common to both X1 and X2
Similarlyand 5.06655701635736 6.06959636219741 and so-on.
Can anybody help me how to do this in matlab?
4 Comments
Direct link to this comment
https://au.mathworks.com/matlabcentral/answers/478661-finding-the-common-range-between-two-ranges#comment_741618
Direct link to this comment
https://au.mathworks.com/matlabcentral/answers/478661-finding-the-common-range-between-two-ranges#comment_741618
Direct link to this comment
https://au.mathworks.com/matlabcentral/answers/478661-finding-the-common-range-between-two-ranges#comment_741620
Direct link to this comment
https://au.mathworks.com/matlabcentral/answers/478661-finding-the-common-range-between-two-ranges#comment_741620
Direct link to this comment
https://au.mathworks.com/matlabcentral/answers/478661-finding-the-common-range-between-two-ranges#comment_741630
Direct link to this comment
https://au.mathworks.com/matlabcentral/answers/478661-finding-the-common-range-between-two-ranges#comment_741630
Direct link to this comment
https://au.mathworks.com/matlabcentral/answers/478661-finding-the-common-range-between-two-ranges#comment_741656
Direct link to this comment
https://au.mathworks.com/matlabcentral/answers/478661-finding-the-common-range-between-two-ranges#comment_741656
Sign in to comment.