7171for op ∈ (:* ,:∪ )
7272 @eval begin
7373 @pure $ op (a:: T ,:: Q ) where {T<: VectorBundle{N,M,S} ,Q<: VectorBundle{N,M,S} } where {N,M,S} = a
74- @pure $ op (a:: M ,:: Q ) where Q <: SubManifold{Y,M ,B} where Y where { M<: VectorBundle ,A,B} = a
75- @pure $ op (:: T , b:: M ) where T <: SubManifold {X,M,A} where X where { M<: VectorBundle ,A,B} = b
76- @pure $ op (:: T , :: Q ) where {T <: SubManifold{X,M,A} where X,Q <: SubManifold{Y,M,B} where Y} where {M,A,B} = SubManifold {M} (A| B)
77- @pure function $op (a:: T ,b:: S ) where {T<: VectorBundle{N1,M1,S1} ,S<: VectorBundle{N2,M2,S2} } where {N1,M1,S1,N2,M2,S2}
74+ @pure $ op (a:: M ,:: SubManifold{Y,m ,B} ) where {Y,m, M<: VectorBundle ,A,B} = a∪ m
75+ @pure $ op (:: SubManifold{X,m,A} , b:: M ) where {X,m, M<: VectorBundle ,A,B} = m ∪ b
76+ @pure $ op (:: SubManifold{X,M,A} where X,:: SubManifold{Y,M,B} where Y) where {M,A,B} = SubManifold {M} (A| B)
77+ @pure function $op (a:: T ,b:: S ) where {T<: VectorBundle{N1,M1,S1,V1,d1 } ,S<: VectorBundle{N2,M2,S2,V2,d2 } } where {N1,M1,S1,V1,d1, N2,M2,S2,V2,d2 }
7878 D1,O1,C1 = options_list (a)
7979 D2,O2,C2 = options_list (b)
80- if ((C1≠ C2)&& (C1≥ 0 )&& (C2≥ 0 )) && a== b'
80+ if (M1,S1) == (M2,S2) && (V1,d1) ≠ (V2,d2)
81+ (T<: Signature ? Signature : DiagnoalManifold){max (N1,N2),M1,S1,max (V1,V2),max (d1,d2)}()
82+ elseif ((C1≠ C2)&& (C1≥ 0 )&& (C2≥ 0 )) && a== b'
8183 return C1> 0 ? b⊕ a : a⊕ b
8284 elseif min (C1,C2)< 0 && max (C1,C2)≥ 0
8385 Y = C1< 0 ? b⊆ a : a⊆ b
@@ -92,18 +94,20 @@ for op ∈ (:*,:∪)
9294 end
9395end
9496
95- ∪ (x:: T ) where T<: Manifold = x
96- ∪ (a:: A ,b:: B ,c:: C... ) where {A<: Manifold ,B<: Manifold ,C<: Manifold } = ∪ (a∪ b,c... )
97+ @pure ∪ (x:: T ) where T<: Manifold = x
98+ ∪ (a:: A ,b:: B ,c:: C... ) where {A<: Manifold ,B<: Manifold ,C<: Manifold } = ∪ (a* b,c... )
9799
98100@pure ∩ (a:: T ,:: Q ) where {T<: VectorBundle{N,M,S} ,Q<: VectorBundle{N,M,S} } where {N,M,S} = a
99101@pure ∩ (a:: T ,:: S ) where {T<: VectorBundle{N} ,S<: VectorBundle{N} } where N = V0
100- @pure ∩ (:: M ,b:: Q ) where Q<: SubManifold{Y,M,B} where Y where {M<: VectorBundle ,A,B} = b
101- @pure ∩ (a:: T ,:: M ) where T<: SubManifold{X,M,A} where X where {M<: VectorBundle ,A,B} = a
102+ # @pure ∩(::M,b::Q) where Q<:SubManifold{Y,M,B} where Y where {M<:VectorBundle,A,B} = b
103+ # @pure ∩(a::T,::M) where T<:SubManifold{X,M,A} where X where {M<:VectorBundle,A,B} = a
102104@pure ∩ (:: T ,:: Q ) where {T<: SubManifold{X,M,A} where X,Q<: SubManifold{Y,M,B} where Y} where {M,A,B} = SubManifold {M} (A& B)
103- @pure function ∩ (a:: T ,b:: S ) where {T<: VectorBundle{N1,M1,S1} ,S<: VectorBundle{N2,M2,S2} } where {N1,M1,S1,N2,M2,S2}
105+ @pure function ∩ (a:: T ,b:: S ) where {T<: VectorBundle{N1,M1,S1,V1,d1 } ,S<: VectorBundle{N2,M2,S2,V2,d2 } } where {N1,M1,S1,V1,d1, N2,M2,S2,V2,d2 }
104106 D1,O1,C1 = options_list (a)
105107 D2,O2,C2 = options_list (b)
106- if ((C1≠ C2)&& (C1≥ 0 )&& (C2≥ 0 ))
108+ if (M1,S1) == (M2,S2) && (V1,d1) ≠ (V2,d2)
109+ (T<: Signature ? Signature : DiagnoalManifold){min (N1,N2),M1,S1,min (V1,V2),min (d1,d2)}()
110+ elseif ((C1≠ C2)&& (C1≥ 0 )&& (C2≥ 0 ))
107111 return V0
108112 elseif min (C1,C2)< 0 && max (C1,C2)≥ 0
109113 Y = C1< 0
@@ -122,10 +126,12 @@ end
122126@pure ⊆ (:: M ,b:: Q ) where Q<: SubManifold{Y,M,B} where {M<: VectorBundle ,A,B,Y} = ndims (M) == Y
123127@pure ⊆ (a:: T ,:: M ) where T<: SubManifold{X,M,A} where X where {M<: VectorBundle ,A,B} = true
124128@pure ⊆ (:: T ,:: Q ) where {T<: SubManifold{X,M,A} ,Q<: SubManifold{Y,M,B} where Y} where {M,A,B,X} = count_ones (A& B) == X
125- @pure function ⊆ (a:: T ,b:: S ) where {T<: VectorBundle{N1,M1,S1} ,S<: VectorBundle{N2,M2,S2} } where {N1,M1,S1,N2,M2,S2}
129+ @pure function ⊆ (a:: T ,b:: S ) where {T<: VectorBundle{N1,M1,S1,V1,d1 } ,S<: VectorBundle{N2,M2,S2,V2,d2 } } where {N1,M1,S1,V1,d1, N2,M2,S2,V2,d2 }
126130 D1,O1,C1 = options_list (a)
127131 D2,O2,C2 = options_list (b)
128- if ((C1≠ C2)&& (C1≥ 0 )&& (C2≥ 0 )) || ((C1< 0 )&& (C2≥ 0 ))
132+ if (M1,S1) == (M2,S2) && (V1,d1) ≠ (V2,d2)
133+ V1 ≤ V2 && d1 ≤ d2
134+ elseif ((C1≠ C2)&& (C1≥ 0 )&& (C2≥ 0 )) || ((C1< 0 )&& (C2≥ 0 ))
129135 return false
130136 elseif C2< 0 && C1≥ 0
131137 return (C1> 0 ? a' ⊕ a : a⊕ a' ) == b
0 commit comments