808 "box a b \<subseteq> cbox c d \<longleftrightarrow> |
808 "box a b \<subseteq> cbox c d \<longleftrightarrow> |
809 (Re a < Re b \<and> Im a < Im b) \<longrightarrow> Re a \<ge> Re c \<and> Im a \<ge> Im c \<and> Re b \<le> Re d \<and> Im b \<le> Im d" |
809 (Re a < Re b \<and> Im a < Im b) \<longrightarrow> Re a \<ge> Re c \<and> Im a \<ge> Im c \<and> Re b \<le> Re d \<and> Im b \<le> Im d" |
810 "box a b \<subseteq> box c d \<longleftrightarrow> |
810 "box a b \<subseteq> box c d \<longleftrightarrow> |
811 (Re a < Re b \<and> Im a < Im b) \<longrightarrow> Re a \<ge> Re c \<and> Im a \<ge> Im c \<and> Re b \<le> Re d \<and> Im b \<le> Im d" |
811 (Re a < Re b \<and> Im a < Im b) \<longrightarrow> Re a \<ge> Re c \<and> Im a \<ge> Im c \<and> Re b \<le> Re d \<and> Im b \<le> Im d" |
812 by (subst subset_box; force simp: Basis_complex_def)+ |
812 by (subst subset_box; force simp: Basis_complex_def)+ |
|
813 |
|
814 lemma in_cbox_complex_iff: |
|
815 "x \<in> cbox a b \<longleftrightarrow> Re x \<in> {Re a..Re b} \<and> Im x \<in> {Im a..Im b}" |
|
816 by (cases x; cases a; cases b) (auto simp: cbox_Complex_eq) |
|
817 |
|
818 lemma box_Complex_eq: |
|
819 "box (Complex a c) (Complex b d) = (\<lambda>(x,y). Complex x y) ` (box a b \<times> box c d)" |
|
820 by (auto simp: box_def Basis_complex_def image_iff complex_eq_iff) |
|
821 |
|
822 lemma in_box_complex_iff: |
|
823 "x \<in> box a b \<longleftrightarrow> Re x \<in> {Re a<..<Re b} \<and> Im x \<in> {Im a<..<Im b}" |
|
824 by (cases x; cases a; cases b) (auto simp: box_Complex_eq) |
813 |
825 |
814 lemma Int_interval: |
826 lemma Int_interval: |
815 fixes a :: "'a::euclidean_space" |
827 fixes a :: "'a::euclidean_space" |
816 shows "cbox a b \<inter> cbox c d = |
828 shows "cbox a b \<inter> cbox c d = |
817 cbox (\<Sum>i\<in>Basis. max (a\<bullet>i) (c\<bullet>i) *\<^sub>R i) (\<Sum>i\<in>Basis. min (b\<bullet>i) (d\<bullet>i) *\<^sub>R i)" |
829 cbox (\<Sum>i\<in>Basis. max (a\<bullet>i) (c\<bullet>i) *\<^sub>R i) (\<Sum>i\<in>Basis. min (b\<bullet>i) (d\<bullet>i) *\<^sub>R i)" |