author | desharna |
Tue, 11 Jun 2024 10:27:35 +0200 | |
changeset 80345 | 7d4cd57cd955 |
parent 74475 | 409ca22dee4c |
permissions | -rw-r--r-- |
74475
409ca22dee4c
new notion of infinite sums in HOL-Analysis, ordering on complex numbers
eberlm <eberlm@in.tum.de>
parents:
diff
changeset
|
1 |
(* |
409ca22dee4c
new notion of infinite sums in HOL-Analysis, ordering on complex numbers
eberlm <eberlm@in.tum.de>
parents:
diff
changeset
|
2 |
Title: HOL/Library/Complex_Order.thy |
409ca22dee4c
new notion of infinite sums in HOL-Analysis, ordering on complex numbers
eberlm <eberlm@in.tum.de>
parents:
diff
changeset
|
3 |
Author: Dominique Unruh, University of Tartu |
409ca22dee4c
new notion of infinite sums in HOL-Analysis, ordering on complex numbers
eberlm <eberlm@in.tum.de>
parents:
diff
changeset
|
4 |
|
409ca22dee4c
new notion of infinite sums in HOL-Analysis, ordering on complex numbers
eberlm <eberlm@in.tum.de>
parents:
diff
changeset
|
5 |
Instantiation of complex numbers as an ordered set. |
409ca22dee4c
new notion of infinite sums in HOL-Analysis, ordering on complex numbers
eberlm <eberlm@in.tum.de>
parents:
diff
changeset
|
6 |
*) |
409ca22dee4c
new notion of infinite sums in HOL-Analysis, ordering on complex numbers
eberlm <eberlm@in.tum.de>
parents:
diff
changeset
|
7 |
|
409ca22dee4c
new notion of infinite sums in HOL-Analysis, ordering on complex numbers
eberlm <eberlm@in.tum.de>
parents:
diff
changeset
|
8 |
theory Complex_Order |
409ca22dee4c
new notion of infinite sums in HOL-Analysis, ordering on complex numbers
eberlm <eberlm@in.tum.de>
parents:
diff
changeset
|
9 |
imports Complex_Main |
409ca22dee4c
new notion of infinite sums in HOL-Analysis, ordering on complex numbers
eberlm <eberlm@in.tum.de>
parents:
diff
changeset
|
10 |
begin |
409ca22dee4c
new notion of infinite sums in HOL-Analysis, ordering on complex numbers
eberlm <eberlm@in.tum.de>
parents:
diff
changeset
|
11 |
|
409ca22dee4c
new notion of infinite sums in HOL-Analysis, ordering on complex numbers
eberlm <eberlm@in.tum.de>
parents:
diff
changeset
|
12 |
instantiation complex :: order begin |
409ca22dee4c
new notion of infinite sums in HOL-Analysis, ordering on complex numbers
eberlm <eberlm@in.tum.de>
parents:
diff
changeset
|
13 |
|
409ca22dee4c
new notion of infinite sums in HOL-Analysis, ordering on complex numbers
eberlm <eberlm@in.tum.de>
parents:
diff
changeset
|
14 |
definition \<open>x < y \<longleftrightarrow> Re x < Re y \<and> Im x = Im y\<close> |
409ca22dee4c
new notion of infinite sums in HOL-Analysis, ordering on complex numbers
eberlm <eberlm@in.tum.de>
parents:
diff
changeset
|
15 |
definition \<open>x \<le> y \<longleftrightarrow> Re x \<le> Re y \<and> Im x = Im y\<close> |
409ca22dee4c
new notion of infinite sums in HOL-Analysis, ordering on complex numbers
eberlm <eberlm@in.tum.de>
parents:
diff
changeset
|
16 |
|
409ca22dee4c
new notion of infinite sums in HOL-Analysis, ordering on complex numbers
eberlm <eberlm@in.tum.de>
parents:
diff
changeset
|
17 |
instance |
409ca22dee4c
new notion of infinite sums in HOL-Analysis, ordering on complex numbers
eberlm <eberlm@in.tum.de>
parents:
diff
changeset
|
18 |
apply standard |
409ca22dee4c
new notion of infinite sums in HOL-Analysis, ordering on complex numbers
eberlm <eberlm@in.tum.de>
parents:
diff
changeset
|
19 |
by (auto simp: less_complex_def less_eq_complex_def complex_eq_iff) |
409ca22dee4c
new notion of infinite sums in HOL-Analysis, ordering on complex numbers
eberlm <eberlm@in.tum.de>
parents:
diff
changeset
|
20 |
end |
409ca22dee4c
new notion of infinite sums in HOL-Analysis, ordering on complex numbers
eberlm <eberlm@in.tum.de>
parents:
diff
changeset
|
21 |
|
409ca22dee4c
new notion of infinite sums in HOL-Analysis, ordering on complex numbers
eberlm <eberlm@in.tum.de>
parents:
diff
changeset
|
22 |
lemma nonnegative_complex_is_real: \<open>(x::complex) \<ge> 0 \<Longrightarrow> x \<in> \<real>\<close> |
409ca22dee4c
new notion of infinite sums in HOL-Analysis, ordering on complex numbers
eberlm <eberlm@in.tum.de>
parents:
diff
changeset
|
23 |
by (simp add: complex_is_Real_iff less_eq_complex_def) |
409ca22dee4c
new notion of infinite sums in HOL-Analysis, ordering on complex numbers
eberlm <eberlm@in.tum.de>
parents:
diff
changeset
|
24 |
|
409ca22dee4c
new notion of infinite sums in HOL-Analysis, ordering on complex numbers
eberlm <eberlm@in.tum.de>
parents:
diff
changeset
|
25 |
lemma complex_is_real_iff_compare0: \<open>(x::complex) \<in> \<real> \<longleftrightarrow> x \<le> 0 \<or> x \<ge> 0\<close> |
409ca22dee4c
new notion of infinite sums in HOL-Analysis, ordering on complex numbers
eberlm <eberlm@in.tum.de>
parents:
diff
changeset
|
26 |
using complex_is_Real_iff less_eq_complex_def by auto |
409ca22dee4c
new notion of infinite sums in HOL-Analysis, ordering on complex numbers
eberlm <eberlm@in.tum.de>
parents:
diff
changeset
|
27 |
|
409ca22dee4c
new notion of infinite sums in HOL-Analysis, ordering on complex numbers
eberlm <eberlm@in.tum.de>
parents:
diff
changeset
|
28 |
instance complex :: ordered_comm_ring |
409ca22dee4c
new notion of infinite sums in HOL-Analysis, ordering on complex numbers
eberlm <eberlm@in.tum.de>
parents:
diff
changeset
|
29 |
apply standard |
409ca22dee4c
new notion of infinite sums in HOL-Analysis, ordering on complex numbers
eberlm <eberlm@in.tum.de>
parents:
diff
changeset
|
30 |
by (auto simp: less_complex_def less_eq_complex_def complex_eq_iff mult_left_mono mult_right_mono) |
409ca22dee4c
new notion of infinite sums in HOL-Analysis, ordering on complex numbers
eberlm <eberlm@in.tum.de>
parents:
diff
changeset
|
31 |
|
409ca22dee4c
new notion of infinite sums in HOL-Analysis, ordering on complex numbers
eberlm <eberlm@in.tum.de>
parents:
diff
changeset
|
32 |
instance complex :: ordered_real_vector |
409ca22dee4c
new notion of infinite sums in HOL-Analysis, ordering on complex numbers
eberlm <eberlm@in.tum.de>
parents:
diff
changeset
|
33 |
apply standard |
409ca22dee4c
new notion of infinite sums in HOL-Analysis, ordering on complex numbers
eberlm <eberlm@in.tum.de>
parents:
diff
changeset
|
34 |
by (auto simp: less_complex_def less_eq_complex_def mult_left_mono mult_right_mono) |
409ca22dee4c
new notion of infinite sums in HOL-Analysis, ordering on complex numbers
eberlm <eberlm@in.tum.de>
parents:
diff
changeset
|
35 |
|
409ca22dee4c
new notion of infinite sums in HOL-Analysis, ordering on complex numbers
eberlm <eberlm@in.tum.de>
parents:
diff
changeset
|
36 |
instance complex :: ordered_cancel_comm_semiring |
409ca22dee4c
new notion of infinite sums in HOL-Analysis, ordering on complex numbers
eberlm <eberlm@in.tum.de>
parents:
diff
changeset
|
37 |
by standard |
409ca22dee4c
new notion of infinite sums in HOL-Analysis, ordering on complex numbers
eberlm <eberlm@in.tum.de>
parents:
diff
changeset
|
38 |
|
409ca22dee4c
new notion of infinite sums in HOL-Analysis, ordering on complex numbers
eberlm <eberlm@in.tum.de>
parents:
diff
changeset
|
39 |
end |