File: functions_interval_orderings.qbk

package info (click to toggle)
boost1.88 1.88.0-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 576,932 kB
  • sloc: cpp: 4,149,234; xml: 136,789; ansic: 35,092; python: 33,910; asm: 5,698; sh: 4,604; ada: 1,681; makefile: 1,633; pascal: 1,139; perl: 1,124; sql: 640; yacc: 478; ruby: 271; java: 77; lisp: 24; csh: 6
file content (90 lines) | stat: -rw-r--r-- 3,837 bytes parent folder | download | duplicates (12)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
[/
    Copyright (c) 2008-2010 Joachim Faulhaber

    Distributed under the Boost Software License, Version 1.0.
    (See accompanying file LICENSE_1_0.txt or copy at
    http://www.boost.org/LICENSE_1_0.txt)
]


[/ //= Additional Interval Orderings ===================================================================]
[section Additional Interval Orderings]

In addition to the standard orderings `operator <` and rleated `> <= >=` that you will find in the 
[link function_synopsis_table ['*librarie's function synopsis*]], intervals
implement some additional orderings that can be useful.

[table
[[T]                                       [__ch_dsc_itv__] [__ch_cnt_itv__] [__ch_ro_itv__] [__ch_lo_itv__]  [__ch_cl_itv__] [__ch_op_itv__]      ]
[[Interval bounds]                                     [dynamic]  [dynamic]    [static]     [static]     [static]    [static]    ]
[[Form]                                                [ ]        [ ]          [asymmetric] [asymmetric] [symmetric] [symmetric] ]
[[['*Orderings*]]                                      [ ]        [ ]          [ ]          [ ]          [ ]         [ ]         ]
[[`bool exclusive_less(const T&, const T&)`]           [1]        [1]          [1]          [1]          [1]         [1]         ]
[[``
bool lower_less(const T&, const T&)
bool lower_equal(const T&, const T&)
bool lower_less_equal(const T&, const T&)
``]                                                    [1]        [1]          [1]          [1]          [1]         [1]         ]
[[``
bool upper_less(const T&, const T&)
bool upper_equal(const T&, const T&)
bool upper_less_equal(const T&, const T&)
``]                                                 
                                                       [1]        [1]          [1]          [1]          [1]         [1]         ]
]

A central role for the *icl* plays the 
`exclusive_less` ordering, which is used 
in all interval containers.
The other orderings can be useful to simplify
comparison of intervals specifically for 
dynamically bounded ones.

[table
[[['*Orderings*]]                                      [Description]         ]
[[`bool exclusive_less(const T&, const T&)`]           [`exclusive_less(x1, x2)` is true if every element of interval `x1` is less than
                                                         every element of interval `x2` w.r.t. the the intervals `Compare` ordering ]     ]
[[``
bool lower_less(const T&, const T&)
bool lower_equal(const T&, const T&)
bool lower_less_equal(const T&, const T&)
``]                                                    [Compares the beginnings of intervals.
``
lower_less(x,y)  == true; // x begins before y
lower_equal(x,y) == true; // x and y begin at the same element
lower_less_equal(x,y) == lower_less(x,y) || lower_equal(x,y);
``
                                                       ]         ]
[[``
bool upper_less(const T&, const T&)
bool upper_equal(const T&, const T&)
bool upper_less_equal(const T&, const T&)
``]                                                 
                                                       [Compares the endings of intervals.
``
upper_less(x,y)  == true; // x ends before y
upper_equal(x,y) == true; // x and y end at the same element
upper_less_equal(x,y) == upper_less(x,y) || upper_equal(x,y);
``                                                                                          
                                                       ]         ]
]


['*See also . . .*]
[table
[]
[[ __biLEquivsOrderings__ ]]
]


['*Back to section . . .*]
[table
[]
[[[link additional_interval_functions ['*Additional interval functions*]] ]]
[[[link function_synopsis_table ['*Function Synopsis*]]          ]]
[[[link boost_icl.interface ['*Interface*]]                      ]]
]

[endsect][/ Additional Interval Orderings]