tuple_intersectiontuple_intersectionTupleIntersectionTupleIntersection (Operator)
Name
tuple_intersectiontuple_intersectionTupleIntersectionTupleIntersection
— Berechnet die Schnittmenge von zwei Tupeln.
Signatur
Beschreibung
tuple_intersectiontuple_intersectionTupleIntersectionTupleIntersectionTupleIntersection
liefert die Schnittmenge von
Set1Set1Set1Set1set1
und Set2Set2Set2Set2set2
in IntersectionIntersectionIntersectionIntersectionintersection
zurück. Der
Schnitt von [0,1,3,3,5] und [2,3,5,10] ist zum Beispiel [3,5].
Elemente unterschiedlichen Typs werden als unterschiedliche Elemente
betrachtet, das heißt, 1.0 und 1 sind nicht gleich. Wenn Set1Set1Set1Set1set1
und Set2Set2Set2Set2set2
unterschiedliche Elementtypen enthalten, kann ihre
Schnittmenge leer sein. So ist zum Beispiel der Schnitt von [2.0,5.0,0,10]
und [2,5,3] leer.
Sonderfall: Leere Eingabetupel
Falls eines oder beide der Eingabetupel leer sind, gibt der Operator ein
leeres Tupel zurück.
HDevelop Inline-Operation
HDevelop unterstützt eine Inline-Operation für tuple_intersectiontuple_intersectionTupleIntersectionTupleIntersectionTupleIntersection
,
die innerhalb eines Ausdrucks in der folgenden Syntax verwendet werden
kann:
Intersection := intersection(Set1, Set2)
Ausführungsinformationen
- Multithreading-Typ: independent (läuft parallel auch zu exklusiven Operatoren).
- Multithreading-Bereich: global (kann von jedem Thread aufgerufen werden).
- Automatisch parallelisiert auf interner Datenebene.
Parameter
Set1Set1Set1Set1set1
(input_control) tuple(-array) →
HTupleHTupleHtuple (integer / real / string / handle) (int / long / double / string / HHandle) (Hlong / double / HString / HHandle) (Hlong / double / char* / handle)
Eingabe-Tupel.
Set2Set2Set2Set2set2
(input_control) tuple(-array) →
HTupleHTupleHtuple (integer / real / string / handle) (int / long / double / string / HHandle) (Hlong / double / HString / HHandle) (Hlong / double / char* / handle)
Eingabe-Tupel.
IntersectionIntersectionIntersectionIntersectionintersection
(output_control) tuple(-array) →
HTupleHTupleHtuple (integer / real / string / handle) (int / long / double / string / HHandle) (Hlong / double / HString / HHandle) (Hlong / double / char* / handle)
Die Schnittmenge aus den zwei Eingabe-Tupeln.
Ergebnis
Sind die Parameterwerte korrekt, dann liefert tuple_intersectiontuple_intersectionTupleIntersectionTupleIntersectionTupleIntersection
den Wert 2 (H_MSG_TRUE).
Alternativen
tuple_uniontuple_unionTupleUnionTupleUnionTupleUnion
Siehe auch
tuple_differencetuple_differenceTupleDifferenceTupleDifferenceTupleDifference
,
tuple_symmdifftuple_symmdiffTupleSymmdiffTupleSymmdiffTupleSymmdiff
,
tuple_uniontuple_unionTupleUnionTupleUnionTupleUnion
Modul
Foundation