Help CenterHelp Center
fixed.Interval
Determine if two fixed.Interval objects overlap
Since R2019b
bool = overlaps(A, B)
example
bool = overlaps(A, B) returns a boolean indicating whether two fixed.Interval objects overlap.
bool
A, B
collapse all
Create two fixed.Interval objects and determine if their ranges overlap.
interval1 = fixed.Interval(-1, 1); interval2 = fixed.Interval(0, 1); overlaps(interval1, interval2)
ans = logical 1
When the ranges of the Interval objects overlap, the overlaps function returns a value of 1, or true.
Interval
overlaps
true
Input fixed.Interval objects, specified as fixed.Interval objects, or arrays of fixed.Interval objects.
Whether the input fixed.Interval objects overlap, returned as a logical value or a vector of logical values.
Introduced in R2019b
fixed.Interval | contains | intersect | setdiff | union | unique
contains
intersect
setdiff
union
unique
Ha hecho clic en un enlace que corresponde a este comando de MATLAB:
Ejecute el comando introduciéndolo en la ventana de comandos de MATLAB. Los navegadores web no admiten comandos de MATLAB.
Select a Web Site
Choose a web site to get translated content where available and see local events and offers. Based on your location, we recommend that you select: .
You can also select a web site from the following list:
Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.
Contact your local office