mirror of
https://github.com/Smaug123/agdaproofs
synced 2025-10-11 22:58:40 +00:00
Better structure of Rationals (#15)
This commit is contained in:
@@ -13,5 +13,17 @@ open import FieldOfFractions
|
|||||||
|
|
||||||
module Rationals where
|
module Rationals where
|
||||||
|
|
||||||
ℚ : Field'
|
ℚ : Set
|
||||||
ℚ = encapsulateField (fieldOfFractions ℤIntDom)
|
ℚ = fieldOfFractionsSet ℤIntDom
|
||||||
|
|
||||||
|
_+Q_ : ℚ → ℚ → ℚ
|
||||||
|
a +Q b = fieldOfFractionsPlus ℤIntDom a b
|
||||||
|
|
||||||
|
_*Q_ : ℚ → ℚ → ℚ
|
||||||
|
a *Q b = fieldOfFractionsTimes ℤIntDom a b
|
||||||
|
|
||||||
|
ℚRing : Ring (fieldOfFractionsSetoid ℤIntDom) _+Q_ _*Q_
|
||||||
|
ℚRing = fieldOfFractionsRing ℤIntDom
|
||||||
|
|
||||||
|
ℚField : Field ℚRing
|
||||||
|
ℚField = fieldOfFractions ℤIntDom
|
||||||
|
Reference in New Issue
Block a user