/-
Copyright (c) 2020 Yury G. Kudryashov. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Yury G. Kudryashov

! This file was ported from Lean 3 source module linear_algebra.affine_space.ordered
! leanprover-community/mathlib commit 78261225eb5cedc61c5c74ecb44e5b385d13b733
! Please do not edit these lines, except to modify the commit id
! if you have ported upstream changes.
-/
import Mathbin.Algebra.Order.Invertible
import Mathbin.Algebra.Order.Module
import Mathbin.LinearAlgebra.AffineSpace.MidpointZero
import Mathbin.LinearAlgebra.AffineSpace.Slope
import Mathbin.Tactic.FieldSimp

/-!
# Ordered modules as affine spaces

In this file we prove some theorems about `slope` and `line_map` in the case when the module `E`
acting on the codomain `PE` of a function is an ordered module over its domain `k`. We also prove
inequalities that can be used to link convexity of a function on an interval to monotonicity of the
slope, see section docstring below for details.

## Implementation notes

We do not introduce the notion of ordered affine spaces (yet?). Instead, we prove various theorems
for an ordered module interpreted as an affine space.

## Tags

affine space, ordered module, slope
-/

open AffineMap

variable {k E PE : Type _}

/-!
### Monotonicity of `line_map`

In this section we prove that `line_map a b r` is monotone (strictly or not) in its arguments if
other arguments belong to specific domains.
-/

section OrderedRing

variable [OrderedRing k] [OrderedAddCommGroup E] [Module k E] [OrderedSMul k E]

variable {a a' b b' : E} {r r' : k}

/- warning: line_map_mono_left -> lineMap_mono_left is a dubious translation:
lean 3 declaration is
  forall {k : Type.{u1}} {E : Type.{u2}} [_inst_1 : OrderedRing.{u1} k] [_inst_2 : OrderedAddCommGroup.{u2} E] [_inst_3 : Module.{u1, u2} k E (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))] [_inst_4 : OrderedSMul.{u1, u2} k E (OrderedRing.toOrderedSemiring.{u1} k _inst_1) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u1, u2} k E (Semiring.toMonoidWithZero.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (AddZeroClass.toHasZero.{u2} E (AddMonoid.toAddZeroClass.{u2} E (AddCommMonoid.toAddMonoid.{u2} E (OrderedAddCommMonoid.toAddCommMonoid.{u2} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)))))) (Module.toMulActionWithZero.{u1, u2} k E (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)) _inst_3))] {a : E} {a' : E} {b : E} {r : k}, (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) a a') -> (LE.le.{u1} k (Preorder.toLE.{u1} k (PartialOrder.toPreorder.{u1} k (OrderedAddCommGroup.toPartialOrder.{u1} k (OrderedRing.toOrderedAddCommGroup.{u1} k _inst_1)))) r (OfNat.ofNat.{u1} k 1 (OfNat.mk.{u1} k 1 (One.one.{u1} k (AddMonoidWithOne.toOne.{u1} k (AddGroupWithOne.toAddMonoidWithOne.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))))))) -> (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (AffineMap.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (fun (_x : AffineMap.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) => k -> E) (AffineMap.hasCoeToFun.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (AffineMap.lineMap.{u1, u2, u2} k E E (OrderedRing.toRing.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) a b) r) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (AffineMap.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (fun (_x : AffineMap.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) => k -> E) (AffineMap.hasCoeToFun.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (AffineMap.lineMap.{u1, u2, u2} k E E (OrderedRing.toRing.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) a' b) r))
but is expected to have type
  forall {k : Type.{u1}} {E : Type.{u2}} [_inst_1 : OrderedRing.{u1} k] [_inst_2 : OrderedAddCommGroup.{u2} E] [_inst_3 : Module.{u1, u2} k E (OrderedSemiring.toSemiring.{u1} k (OrderedRing.toOrderedSemiring.{u1} k _inst_1)) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2))] [_inst_4 : OrderedSMul.{u1, u2} k E (OrderedRing.toOrderedSemiring.{u1} k _inst_1) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u1, u2} k E (Semiring.toMonoidWithZero.{u1} k (OrderedSemiring.toSemiring.{u1} k (OrderedRing.toOrderedSemiring.{u1} k _inst_1))) (AddMonoid.toZero.{u2} E (AddCommMonoid.toAddMonoid.{u2} E (OrderedAddCommMonoid.toAddCommMonoid.{u2} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2))))) (Module.toMulActionWithZero.{u1, u2} k E (OrderedSemiring.toSemiring.{u1} k (OrderedRing.toOrderedSemiring.{u1} k _inst_1)) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) _inst_3))] {a : E} {a' : E} {b : E} {r : k}, (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) a a') -> (LE.le.{u1} k (Preorder.toLE.{u1} k (PartialOrder.toPreorder.{u1} k (OrderedRing.toPartialOrder.{u1} k _inst_1))) r (OfNat.ofNat.{u1} k 1 (One.toOfNat1.{u1} k (NonAssocRing.toOne.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))))) -> (LE.le.{u2} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (Preorder.toLE.{u2} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (PartialOrder.toPreorder.{u2} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (OrderedAddCommGroup.toPartialOrder.{u2} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) _inst_2))) (FunLike.coe.{max (succ u1) (succ u2), succ u1, succ u2} (AffineMap.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (Ring.toAddCommGroup.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (Ring.toAddGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) _x) (AffineMap.funLike.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (Ring.toAddCommGroup.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (Ring.toAddGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (AffineMap.lineMap.{u1, u2, u2} k E E (OrderedRing.toRing.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) a b) r) (FunLike.coe.{max (succ u1) (succ u2), succ u1, succ u2} (AffineMap.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (Ring.toAddCommGroup.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (Ring.toAddGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) _x) (AffineMap.funLike.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (Ring.toAddCommGroup.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (Ring.toAddGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (AffineMap.lineMap.{u1, u2, u2} k E E (OrderedRing.toRing.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) a' b) r))
Case conversion may be inaccurate. Consider using '#align line_map_mono_left lineMap_mono_leftₓ'. -/
theorem lineMap_mono_left (ha : a ≤ a') (hr : r ≤ 1) : lineMap a b r ≤ lineMap a' b r :=
  by
  simp only [line_map_apply_module]
  exact add_le_add_right (smul_le_smul_of_nonneg ha (sub_nonneg.2 hr)) _
#align line_map_mono_left lineMap_mono_left

/- warning: line_map_strict_mono_left -> lineMap_strict_mono_left is a dubious translation:
lean 3 declaration is
  forall {k : Type.{u1}} {E : Type.{u2}} [_inst_1 : OrderedRing.{u1} k] [_inst_2 : OrderedAddCommGroup.{u2} E] [_inst_3 : Module.{u1, u2} k E (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))] [_inst_4 : OrderedSMul.{u1, u2} k E (OrderedRing.toOrderedSemiring.{u1} k _inst_1) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u1, u2} k E (Semiring.toMonoidWithZero.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (AddZeroClass.toHasZero.{u2} E (AddMonoid.toAddZeroClass.{u2} E (AddCommMonoid.toAddMonoid.{u2} E (OrderedAddCommMonoid.toAddCommMonoid.{u2} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)))))) (Module.toMulActionWithZero.{u1, u2} k E (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)) _inst_3))] {a : E} {a' : E} {b : E} {r : k}, (LT.lt.{u2} E (Preorder.toLT.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) a a') -> (LT.lt.{u1} k (Preorder.toLT.{u1} k (PartialOrder.toPreorder.{u1} k (OrderedAddCommGroup.toPartialOrder.{u1} k (OrderedRing.toOrderedAddCommGroup.{u1} k _inst_1)))) r (OfNat.ofNat.{u1} k 1 (OfNat.mk.{u1} k 1 (One.one.{u1} k (AddMonoidWithOne.toOne.{u1} k (AddGroupWithOne.toAddMonoidWithOne.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))))))) -> (LT.lt.{u2} E (Preorder.toLT.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (AffineMap.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (fun (_x : AffineMap.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) => k -> E) (AffineMap.hasCoeToFun.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (AffineMap.lineMap.{u1, u2, u2} k E E (OrderedRing.toRing.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) a b) r) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (AffineMap.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (fun (_x : AffineMap.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) => k -> E) (AffineMap.hasCoeToFun.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (AffineMap.lineMap.{u1, u2, u2} k E E (OrderedRing.toRing.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) a' b) r))
but is expected to have type
  forall {k : Type.{u1}} {E : Type.{u2}} [_inst_1 : OrderedRing.{u1} k] [_inst_2 : OrderedAddCommGroup.{u2} E] [_inst_3 : Module.{u1, u2} k E (OrderedSemiring.toSemiring.{u1} k (OrderedRing.toOrderedSemiring.{u1} k _inst_1)) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2))] [_inst_4 : OrderedSMul.{u1, u2} k E (OrderedRing.toOrderedSemiring.{u1} k _inst_1) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u1, u2} k E (Semiring.toMonoidWithZero.{u1} k (OrderedSemiring.toSemiring.{u1} k (OrderedRing.toOrderedSemiring.{u1} k _inst_1))) (AddMonoid.toZero.{u2} E (AddCommMonoid.toAddMonoid.{u2} E (OrderedAddCommMonoid.toAddCommMonoid.{u2} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2))))) (Module.toMulActionWithZero.{u1, u2} k E (OrderedSemiring.toSemiring.{u1} k (OrderedRing.toOrderedSemiring.{u1} k _inst_1)) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) _inst_3))] {a : E} {a' : E} {b : E} {r : k}, (LT.lt.{u2} E (Preorder.toLT.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) a a') -> (LT.lt.{u1} k (Preorder.toLT.{u1} k (PartialOrder.toPreorder.{u1} k (OrderedRing.toPartialOrder.{u1} k _inst_1))) r (OfNat.ofNat.{u1} k 1 (One.toOfNat1.{u1} k (NonAssocRing.toOne.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))))) -> (LT.lt.{u2} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (Preorder.toLT.{u2} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (PartialOrder.toPreorder.{u2} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (OrderedAddCommGroup.toPartialOrder.{u2} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) _inst_2))) (FunLike.coe.{max (succ u1) (succ u2), succ u1, succ u2} (AffineMap.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (Ring.toAddCommGroup.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (Ring.toAddGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) _x) (AffineMap.funLike.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (Ring.toAddCommGroup.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (Ring.toAddGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (AffineMap.lineMap.{u1, u2, u2} k E E (OrderedRing.toRing.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) a b) r) (FunLike.coe.{max (succ u1) (succ u2), succ u1, succ u2} (AffineMap.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (Ring.toAddCommGroup.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (Ring.toAddGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) _x) (AffineMap.funLike.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (Ring.toAddCommGroup.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (Ring.toAddGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (AffineMap.lineMap.{u1, u2, u2} k E E (OrderedRing.toRing.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) a' b) r))
Case conversion may be inaccurate. Consider using '#align line_map_strict_mono_left lineMap_strict_mono_leftₓ'. -/
theorem lineMap_strict_mono_left (ha : a < a') (hr : r < 1) : lineMap a b r < lineMap a' b r :=
  by
  simp only [line_map_apply_module]
  exact add_lt_add_right (smul_lt_smul_of_pos ha (sub_pos.2 hr)) _
#align line_map_strict_mono_left lineMap_strict_mono_left

/- warning: line_map_mono_right -> lineMap_mono_right is a dubious translation:
lean 3 declaration is
  forall {k : Type.{u1}} {E : Type.{u2}} [_inst_1 : OrderedRing.{u1} k] [_inst_2 : OrderedAddCommGroup.{u2} E] [_inst_3 : Module.{u1, u2} k E (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))] [_inst_4 : OrderedSMul.{u1, u2} k E (OrderedRing.toOrderedSemiring.{u1} k _inst_1) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u1, u2} k E (Semiring.toMonoidWithZero.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (AddZeroClass.toHasZero.{u2} E (AddMonoid.toAddZeroClass.{u2} E (AddCommMonoid.toAddMonoid.{u2} E (OrderedAddCommMonoid.toAddCommMonoid.{u2} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)))))) (Module.toMulActionWithZero.{u1, u2} k E (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)) _inst_3))] {a : E} {b : E} {b' : E} {r : k}, (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) b b') -> (LE.le.{u1} k (Preorder.toLE.{u1} k (PartialOrder.toPreorder.{u1} k (OrderedAddCommGroup.toPartialOrder.{u1} k (OrderedRing.toOrderedAddCommGroup.{u1} k _inst_1)))) (OfNat.ofNat.{u1} k 0 (OfNat.mk.{u1} k 0 (Zero.zero.{u1} k (MulZeroClass.toHasZero.{u1} k (NonUnitalNonAssocSemiring.toMulZeroClass.{u1} k (NonUnitalNonAssocRing.toNonUnitalNonAssocSemiring.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))))))) r) -> (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (AffineMap.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (fun (_x : AffineMap.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) => k -> E) (AffineMap.hasCoeToFun.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (AffineMap.lineMap.{u1, u2, u2} k E E (OrderedRing.toRing.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) a b) r) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (AffineMap.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (fun (_x : AffineMap.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) => k -> E) (AffineMap.hasCoeToFun.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (AffineMap.lineMap.{u1, u2, u2} k E E (OrderedRing.toRing.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) a b') r))
but is expected to have type
  forall {k : Type.{u1}} {E : Type.{u2}} [_inst_1 : OrderedRing.{u1} k] [_inst_2 : OrderedAddCommGroup.{u2} E] [_inst_3 : Module.{u1, u2} k E (OrderedSemiring.toSemiring.{u1} k (OrderedRing.toOrderedSemiring.{u1} k _inst_1)) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2))] [_inst_4 : OrderedSMul.{u1, u2} k E (OrderedRing.toOrderedSemiring.{u1} k _inst_1) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u1, u2} k E (Semiring.toMonoidWithZero.{u1} k (OrderedSemiring.toSemiring.{u1} k (OrderedRing.toOrderedSemiring.{u1} k _inst_1))) (AddMonoid.toZero.{u2} E (AddCommMonoid.toAddMonoid.{u2} E (OrderedAddCommMonoid.toAddCommMonoid.{u2} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2))))) (Module.toMulActionWithZero.{u1, u2} k E (OrderedSemiring.toSemiring.{u1} k (OrderedRing.toOrderedSemiring.{u1} k _inst_1)) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) _inst_3))] {a : E} {b : E} {b' : E} {r : k}, (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) b b') -> (LE.le.{u1} k (Preorder.toLE.{u1} k (PartialOrder.toPreorder.{u1} k (OrderedRing.toPartialOrder.{u1} k _inst_1))) (OfNat.ofNat.{u1} k 0 (Zero.toOfNat0.{u1} k (MonoidWithZero.toZero.{u1} k (Semiring.toMonoidWithZero.{u1} k (OrderedSemiring.toSemiring.{u1} k (OrderedRing.toOrderedSemiring.{u1} k _inst_1)))))) r) -> (LE.le.{u2} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (Preorder.toLE.{u2} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (PartialOrder.toPreorder.{u2} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (OrderedAddCommGroup.toPartialOrder.{u2} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) _inst_2))) (FunLike.coe.{max (succ u1) (succ u2), succ u1, succ u2} (AffineMap.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (Ring.toAddCommGroup.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (Ring.toAddGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) _x) (AffineMap.funLike.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (Ring.toAddCommGroup.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (Ring.toAddGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (AffineMap.lineMap.{u1, u2, u2} k E E (OrderedRing.toRing.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) a b) r) (FunLike.coe.{max (succ u1) (succ u2), succ u1, succ u2} (AffineMap.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (Ring.toAddCommGroup.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (Ring.toAddGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) _x) (AffineMap.funLike.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (Ring.toAddCommGroup.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (Ring.toAddGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (AffineMap.lineMap.{u1, u2, u2} k E E (OrderedRing.toRing.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) a b') r))
Case conversion may be inaccurate. Consider using '#align line_map_mono_right lineMap_mono_rightₓ'. -/
theorem lineMap_mono_right (hb : b ≤ b') (hr : 0 ≤ r) : lineMap a b r ≤ lineMap a b' r :=
  by
  simp only [line_map_apply_module]
  exact add_le_add_left (smul_le_smul_of_nonneg hb hr) _
#align line_map_mono_right lineMap_mono_right

/- warning: line_map_strict_mono_right -> lineMap_strict_mono_right is a dubious translation:
lean 3 declaration is
  forall {k : Type.{u1}} {E : Type.{u2}} [_inst_1 : OrderedRing.{u1} k] [_inst_2 : OrderedAddCommGroup.{u2} E] [_inst_3 : Module.{u1, u2} k E (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))] [_inst_4 : OrderedSMul.{u1, u2} k E (OrderedRing.toOrderedSemiring.{u1} k _inst_1) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u1, u2} k E (Semiring.toMonoidWithZero.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (AddZeroClass.toHasZero.{u2} E (AddMonoid.toAddZeroClass.{u2} E (AddCommMonoid.toAddMonoid.{u2} E (OrderedAddCommMonoid.toAddCommMonoid.{u2} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)))))) (Module.toMulActionWithZero.{u1, u2} k E (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)) _inst_3))] {a : E} {b : E} {b' : E} {r : k}, (LT.lt.{u2} E (Preorder.toLT.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) b b') -> (LT.lt.{u1} k (Preorder.toLT.{u1} k (PartialOrder.toPreorder.{u1} k (OrderedAddCommGroup.toPartialOrder.{u1} k (OrderedRing.toOrderedAddCommGroup.{u1} k _inst_1)))) (OfNat.ofNat.{u1} k 0 (OfNat.mk.{u1} k 0 (Zero.zero.{u1} k (MulZeroClass.toHasZero.{u1} k (NonUnitalNonAssocSemiring.toMulZeroClass.{u1} k (NonUnitalNonAssocRing.toNonUnitalNonAssocSemiring.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))))))) r) -> (LT.lt.{u2} E (Preorder.toLT.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (AffineMap.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (fun (_x : AffineMap.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) => k -> E) (AffineMap.hasCoeToFun.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (AffineMap.lineMap.{u1, u2, u2} k E E (OrderedRing.toRing.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) a b) r) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (AffineMap.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (fun (_x : AffineMap.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) => k -> E) (AffineMap.hasCoeToFun.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (AffineMap.lineMap.{u1, u2, u2} k E E (OrderedRing.toRing.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) a b') r))
but is expected to have type
  forall {k : Type.{u1}} {E : Type.{u2}} [_inst_1 : OrderedRing.{u1} k] [_inst_2 : OrderedAddCommGroup.{u2} E] [_inst_3 : Module.{u1, u2} k E (OrderedSemiring.toSemiring.{u1} k (OrderedRing.toOrderedSemiring.{u1} k _inst_1)) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2))] [_inst_4 : OrderedSMul.{u1, u2} k E (OrderedRing.toOrderedSemiring.{u1} k _inst_1) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u1, u2} k E (Semiring.toMonoidWithZero.{u1} k (OrderedSemiring.toSemiring.{u1} k (OrderedRing.toOrderedSemiring.{u1} k _inst_1))) (AddMonoid.toZero.{u2} E (AddCommMonoid.toAddMonoid.{u2} E (OrderedAddCommMonoid.toAddCommMonoid.{u2} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2))))) (Module.toMulActionWithZero.{u1, u2} k E (OrderedSemiring.toSemiring.{u1} k (OrderedRing.toOrderedSemiring.{u1} k _inst_1)) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) _inst_3))] {a : E} {b : E} {b' : E} {r : k}, (LT.lt.{u2} E (Preorder.toLT.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) b b') -> (LT.lt.{u1} k (Preorder.toLT.{u1} k (PartialOrder.toPreorder.{u1} k (OrderedRing.toPartialOrder.{u1} k _inst_1))) (OfNat.ofNat.{u1} k 0 (Zero.toOfNat0.{u1} k (MonoidWithZero.toZero.{u1} k (Semiring.toMonoidWithZero.{u1} k (OrderedSemiring.toSemiring.{u1} k (OrderedRing.toOrderedSemiring.{u1} k _inst_1)))))) r) -> (LT.lt.{u2} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (Preorder.toLT.{u2} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (PartialOrder.toPreorder.{u2} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (OrderedAddCommGroup.toPartialOrder.{u2} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) _inst_2))) (FunLike.coe.{max (succ u1) (succ u2), succ u1, succ u2} (AffineMap.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (Ring.toAddCommGroup.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (Ring.toAddGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) _x) (AffineMap.funLike.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (Ring.toAddCommGroup.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (Ring.toAddGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (AffineMap.lineMap.{u1, u2, u2} k E E (OrderedRing.toRing.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) a b) r) (FunLike.coe.{max (succ u1) (succ u2), succ u1, succ u2} (AffineMap.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (Ring.toAddCommGroup.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (Ring.toAddGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) _x) (AffineMap.funLike.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (Ring.toAddCommGroup.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (Ring.toAddGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (AffineMap.lineMap.{u1, u2, u2} k E E (OrderedRing.toRing.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) a b') r))
Case conversion may be inaccurate. Consider using '#align line_map_strict_mono_right lineMap_strict_mono_rightₓ'. -/
theorem lineMap_strict_mono_right (hb : b < b') (hr : 0 < r) : lineMap a b r < lineMap a b' r :=
  by
  simp only [line_map_apply_module]
  exact add_lt_add_left (smul_lt_smul_of_pos hb hr) _
#align line_map_strict_mono_right lineMap_strict_mono_right

/- warning: line_map_mono_endpoints -> lineMap_mono_endpoints is a dubious translation:
lean 3 declaration is
  forall {k : Type.{u1}} {E : Type.{u2}} [_inst_1 : OrderedRing.{u1} k] [_inst_2 : OrderedAddCommGroup.{u2} E] [_inst_3 : Module.{u1, u2} k E (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))] [_inst_4 : OrderedSMul.{u1, u2} k E (OrderedRing.toOrderedSemiring.{u1} k _inst_1) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u1, u2} k E (Semiring.toMonoidWithZero.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (AddZeroClass.toHasZero.{u2} E (AddMonoid.toAddZeroClass.{u2} E (AddCommMonoid.toAddMonoid.{u2} E (OrderedAddCommMonoid.toAddCommMonoid.{u2} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)))))) (Module.toMulActionWithZero.{u1, u2} k E (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)) _inst_3))] {a : E} {a' : E} {b : E} {b' : E} {r : k}, (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) a a') -> (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) b b') -> (LE.le.{u1} k (Preorder.toLE.{u1} k (PartialOrder.toPreorder.{u1} k (OrderedAddCommGroup.toPartialOrder.{u1} k (OrderedRing.toOrderedAddCommGroup.{u1} k _inst_1)))) (OfNat.ofNat.{u1} k 0 (OfNat.mk.{u1} k 0 (Zero.zero.{u1} k (MulZeroClass.toHasZero.{u1} k (NonUnitalNonAssocSemiring.toMulZeroClass.{u1} k (NonUnitalNonAssocRing.toNonUnitalNonAssocSemiring.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))))))) r) -> (LE.le.{u1} k (Preorder.toLE.{u1} k (PartialOrder.toPreorder.{u1} k (OrderedAddCommGroup.toPartialOrder.{u1} k (OrderedRing.toOrderedAddCommGroup.{u1} k _inst_1)))) r (OfNat.ofNat.{u1} k 1 (OfNat.mk.{u1} k 1 (One.one.{u1} k (AddMonoidWithOne.toOne.{u1} k (AddGroupWithOne.toAddMonoidWithOne.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))))))) -> (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (AffineMap.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (fun (_x : AffineMap.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) => k -> E) (AffineMap.hasCoeToFun.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (AffineMap.lineMap.{u1, u2, u2} k E E (OrderedRing.toRing.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) a b) r) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (AffineMap.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (fun (_x : AffineMap.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) => k -> E) (AffineMap.hasCoeToFun.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (AffineMap.lineMap.{u1, u2, u2} k E E (OrderedRing.toRing.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) a' b') r))
but is expected to have type
  forall {k : Type.{u1}} {E : Type.{u2}} [_inst_1 : OrderedRing.{u1} k] [_inst_2 : OrderedAddCommGroup.{u2} E] [_inst_3 : Module.{u1, u2} k E (OrderedSemiring.toSemiring.{u1} k (OrderedRing.toOrderedSemiring.{u1} k _inst_1)) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2))] [_inst_4 : OrderedSMul.{u1, u2} k E (OrderedRing.toOrderedSemiring.{u1} k _inst_1) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u1, u2} k E (Semiring.toMonoidWithZero.{u1} k (OrderedSemiring.toSemiring.{u1} k (OrderedRing.toOrderedSemiring.{u1} k _inst_1))) (AddMonoid.toZero.{u2} E (AddCommMonoid.toAddMonoid.{u2} E (OrderedAddCommMonoid.toAddCommMonoid.{u2} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2))))) (Module.toMulActionWithZero.{u1, u2} k E (OrderedSemiring.toSemiring.{u1} k (OrderedRing.toOrderedSemiring.{u1} k _inst_1)) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) _inst_3))] {a : E} {a' : E} {b : E} {b' : E} {r : k}, (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) a a') -> (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) b b') -> (LE.le.{u1} k (Preorder.toLE.{u1} k (PartialOrder.toPreorder.{u1} k (OrderedRing.toPartialOrder.{u1} k _inst_1))) (OfNat.ofNat.{u1} k 0 (Zero.toOfNat0.{u1} k (MonoidWithZero.toZero.{u1} k (Semiring.toMonoidWithZero.{u1} k (OrderedSemiring.toSemiring.{u1} k (OrderedRing.toOrderedSemiring.{u1} k _inst_1)))))) r) -> (LE.le.{u1} k (Preorder.toLE.{u1} k (PartialOrder.toPreorder.{u1} k (OrderedRing.toPartialOrder.{u1} k _inst_1))) r (OfNat.ofNat.{u1} k 1 (One.toOfNat1.{u1} k (NonAssocRing.toOne.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))))) -> (LE.le.{u2} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (Preorder.toLE.{u2} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (PartialOrder.toPreorder.{u2} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (OrderedAddCommGroup.toPartialOrder.{u2} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) _inst_2))) (FunLike.coe.{max (succ u1) (succ u2), succ u1, succ u2} (AffineMap.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (Ring.toAddCommGroup.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (Ring.toAddGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) _x) (AffineMap.funLike.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (Ring.toAddCommGroup.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (Ring.toAddGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (AffineMap.lineMap.{u1, u2, u2} k E E (OrderedRing.toRing.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) a b) r) (FunLike.coe.{max (succ u1) (succ u2), succ u1, succ u2} (AffineMap.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (Ring.toAddCommGroup.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (Ring.toAddGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) _x) (AffineMap.funLike.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (Ring.toAddCommGroup.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (Ring.toAddGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (AffineMap.lineMap.{u1, u2, u2} k E E (OrderedRing.toRing.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) a' b') r))
Case conversion may be inaccurate. Consider using '#align line_map_mono_endpoints lineMap_mono_endpointsₓ'. -/
theorem lineMap_mono_endpoints (ha : a ≤ a') (hb : b ≤ b') (h₀ : 0 ≤ r) (h₁ : r ≤ 1) :
    lineMap a b r ≤ lineMap a' b' r :=
  (lineMap_mono_left ha h₁).trans (lineMap_mono_right hb h₀)
#align line_map_mono_endpoints lineMap_mono_endpoints

/- warning: line_map_strict_mono_endpoints -> lineMap_strict_mono_endpoints is a dubious translation:
lean 3 declaration is
  forall {k : Type.{u1}} {E : Type.{u2}} [_inst_1 : OrderedRing.{u1} k] [_inst_2 : OrderedAddCommGroup.{u2} E] [_inst_3 : Module.{u1, u2} k E (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))] [_inst_4 : OrderedSMul.{u1, u2} k E (OrderedRing.toOrderedSemiring.{u1} k _inst_1) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u1, u2} k E (Semiring.toMonoidWithZero.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (AddZeroClass.toHasZero.{u2} E (AddMonoid.toAddZeroClass.{u2} E (AddCommMonoid.toAddMonoid.{u2} E (OrderedAddCommMonoid.toAddCommMonoid.{u2} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)))))) (Module.toMulActionWithZero.{u1, u2} k E (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)) _inst_3))] {a : E} {a' : E} {b : E} {b' : E} {r : k}, (LT.lt.{u2} E (Preorder.toLT.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) a a') -> (LT.lt.{u2} E (Preorder.toLT.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) b b') -> (LE.le.{u1} k (Preorder.toLE.{u1} k (PartialOrder.toPreorder.{u1} k (OrderedAddCommGroup.toPartialOrder.{u1} k (OrderedRing.toOrderedAddCommGroup.{u1} k _inst_1)))) (OfNat.ofNat.{u1} k 0 (OfNat.mk.{u1} k 0 (Zero.zero.{u1} k (MulZeroClass.toHasZero.{u1} k (NonUnitalNonAssocSemiring.toMulZeroClass.{u1} k (NonUnitalNonAssocRing.toNonUnitalNonAssocSemiring.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))))))) r) -> (LE.le.{u1} k (Preorder.toLE.{u1} k (PartialOrder.toPreorder.{u1} k (OrderedAddCommGroup.toPartialOrder.{u1} k (OrderedRing.toOrderedAddCommGroup.{u1} k _inst_1)))) r (OfNat.ofNat.{u1} k 1 (OfNat.mk.{u1} k 1 (One.one.{u1} k (AddMonoidWithOne.toOne.{u1} k (AddGroupWithOne.toAddMonoidWithOne.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))))))) -> (LT.lt.{u2} E (Preorder.toLT.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (AffineMap.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (fun (_x : AffineMap.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) => k -> E) (AffineMap.hasCoeToFun.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (AffineMap.lineMap.{u1, u2, u2} k E E (OrderedRing.toRing.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) a b) r) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (AffineMap.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (fun (_x : AffineMap.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) => k -> E) (AffineMap.hasCoeToFun.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (AffineMap.lineMap.{u1, u2, u2} k E E (OrderedRing.toRing.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) a' b') r))
but is expected to have type
  forall {k : Type.{u1}} {E : Type.{u2}} [_inst_1 : OrderedRing.{u1} k] [_inst_2 : OrderedAddCommGroup.{u2} E] [_inst_3 : Module.{u1, u2} k E (OrderedSemiring.toSemiring.{u1} k (OrderedRing.toOrderedSemiring.{u1} k _inst_1)) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2))] [_inst_4 : OrderedSMul.{u1, u2} k E (OrderedRing.toOrderedSemiring.{u1} k _inst_1) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u1, u2} k E (Semiring.toMonoidWithZero.{u1} k (OrderedSemiring.toSemiring.{u1} k (OrderedRing.toOrderedSemiring.{u1} k _inst_1))) (AddMonoid.toZero.{u2} E (AddCommMonoid.toAddMonoid.{u2} E (OrderedAddCommMonoid.toAddCommMonoid.{u2} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2))))) (Module.toMulActionWithZero.{u1, u2} k E (OrderedSemiring.toSemiring.{u1} k (OrderedRing.toOrderedSemiring.{u1} k _inst_1)) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) _inst_3))] {a : E} {a' : E} {b : E} {b' : E} {r : k}, (LT.lt.{u2} E (Preorder.toLT.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) a a') -> (LT.lt.{u2} E (Preorder.toLT.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) b b') -> (LE.le.{u1} k (Preorder.toLE.{u1} k (PartialOrder.toPreorder.{u1} k (OrderedRing.toPartialOrder.{u1} k _inst_1))) (OfNat.ofNat.{u1} k 0 (Zero.toOfNat0.{u1} k (MonoidWithZero.toZero.{u1} k (Semiring.toMonoidWithZero.{u1} k (OrderedSemiring.toSemiring.{u1} k (OrderedRing.toOrderedSemiring.{u1} k _inst_1)))))) r) -> (LE.le.{u1} k (Preorder.toLE.{u1} k (PartialOrder.toPreorder.{u1} k (OrderedRing.toPartialOrder.{u1} k _inst_1))) r (OfNat.ofNat.{u1} k 1 (One.toOfNat1.{u1} k (NonAssocRing.toOne.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))))) -> (LT.lt.{u2} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (Preorder.toLT.{u2} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (PartialOrder.toPreorder.{u2} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (OrderedAddCommGroup.toPartialOrder.{u2} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) _inst_2))) (FunLike.coe.{max (succ u1) (succ u2), succ u1, succ u2} (AffineMap.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (Ring.toAddCommGroup.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (Ring.toAddGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) _x) (AffineMap.funLike.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (Ring.toAddCommGroup.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (Ring.toAddGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (AffineMap.lineMap.{u1, u2, u2} k E E (OrderedRing.toRing.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) a b) r) (FunLike.coe.{max (succ u1) (succ u2), succ u1, succ u2} (AffineMap.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (Ring.toAddCommGroup.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (Ring.toAddGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) _x) (AffineMap.funLike.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (Ring.toAddCommGroup.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (Ring.toAddGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (AffineMap.lineMap.{u1, u2, u2} k E E (OrderedRing.toRing.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) a' b') r))
Case conversion may be inaccurate. Consider using '#align line_map_strict_mono_endpoints lineMap_strict_mono_endpointsₓ'. -/
theorem lineMap_strict_mono_endpoints (ha : a < a') (hb : b < b') (h₀ : 0 ≤ r) (h₁ : r ≤ 1) :
    lineMap a b r < lineMap a' b' r :=
  by
  rcases h₀.eq_or_lt with (rfl | h₀); · simpa
  exact (lineMap_mono_left ha.le h₁).trans_lt (lineMap_strict_mono_right hb h₀)
#align line_map_strict_mono_endpoints lineMap_strict_mono_endpoints

/- warning: line_map_lt_line_map_iff_of_lt -> lineMap_lt_lineMap_iff_of_lt is a dubious translation:
lean 3 declaration is
  forall {k : Type.{u1}} {E : Type.{u2}} [_inst_1 : OrderedRing.{u1} k] [_inst_2 : OrderedAddCommGroup.{u2} E] [_inst_3 : Module.{u1, u2} k E (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))] [_inst_4 : OrderedSMul.{u1, u2} k E (OrderedRing.toOrderedSemiring.{u1} k _inst_1) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u1, u2} k E (Semiring.toMonoidWithZero.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (AddZeroClass.toHasZero.{u2} E (AddMonoid.toAddZeroClass.{u2} E (AddCommMonoid.toAddMonoid.{u2} E (OrderedAddCommMonoid.toAddCommMonoid.{u2} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)))))) (Module.toMulActionWithZero.{u1, u2} k E (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)) _inst_3))] {a : E} {b : E} {r : k} {r' : k}, (LT.lt.{u1} k (Preorder.toLT.{u1} k (PartialOrder.toPreorder.{u1} k (OrderedAddCommGroup.toPartialOrder.{u1} k (OrderedRing.toOrderedAddCommGroup.{u1} k _inst_1)))) r r') -> (Iff (LT.lt.{u2} E (Preorder.toLT.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (AffineMap.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (fun (_x : AffineMap.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) => k -> E) (AffineMap.hasCoeToFun.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (AffineMap.lineMap.{u1, u2, u2} k E E (OrderedRing.toRing.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) a b) r) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (AffineMap.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (fun (_x : AffineMap.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) => k -> E) (AffineMap.hasCoeToFun.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (AffineMap.lineMap.{u1, u2, u2} k E E (OrderedRing.toRing.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) a b) r')) (LT.lt.{u2} E (Preorder.toLT.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) a b))
but is expected to have type
  forall {k : Type.{u2}} {E : Type.{u1}} [_inst_1 : OrderedRing.{u2} k] [_inst_2 : OrderedAddCommGroup.{u1} E] [_inst_3 : Module.{u2, u1} k E (OrderedSemiring.toSemiring.{u2} k (OrderedRing.toOrderedSemiring.{u2} k _inst_1)) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2))] [_inst_4 : OrderedSMul.{u2, u1} k E (OrderedRing.toOrderedSemiring.{u2} k _inst_1) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u2, u1} k E (Semiring.toMonoidWithZero.{u2} k (OrderedSemiring.toSemiring.{u2} k (OrderedRing.toOrderedSemiring.{u2} k _inst_1))) (AddMonoid.toZero.{u1} E (AddCommMonoid.toAddMonoid.{u1} E (OrderedAddCommMonoid.toAddCommMonoid.{u1} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2))))) (Module.toMulActionWithZero.{u2, u1} k E (OrderedSemiring.toSemiring.{u2} k (OrderedRing.toOrderedSemiring.{u2} k _inst_1)) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2)) _inst_3))] {a : E} {b : E} {r : k} {r' : k}, (LT.lt.{u2} k (Preorder.toLT.{u2} k (PartialOrder.toPreorder.{u2} k (OrderedRing.toPartialOrder.{u2} k _inst_1))) r r') -> (Iff (LT.lt.{u1} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (Preorder.toLT.{u1} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (PartialOrder.toPreorder.{u1} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (OrderedAddCommGroup.toPartialOrder.{u1} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) _inst_2))) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (AffineMap.{u2, u2, u2, u1, u1} k k k E E (OrderedRing.toRing.{u2} k _inst_1) (Ring.toAddCommGroup.{u2} k (OrderedRing.toRing.{u2} k _inst_1)) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (OrderedRing.toRing.{u2} k _inst_1)) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (OrderedRing.toRing.{u2} k _inst_1)))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2)))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) _x) (AffineMap.funLike.{u2, u2, u2, u1, u1} k k k E E (OrderedRing.toRing.{u2} k _inst_1) (Ring.toAddCommGroup.{u2} k (OrderedRing.toRing.{u2} k _inst_1)) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (OrderedRing.toRing.{u2} k _inst_1)) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (OrderedRing.toRing.{u2} k _inst_1)))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2)))) (AffineMap.lineMap.{u2, u1, u1} k E E (OrderedRing.toRing.{u2} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2))) a b) r) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (AffineMap.{u2, u2, u2, u1, u1} k k k E E (OrderedRing.toRing.{u2} k _inst_1) (Ring.toAddCommGroup.{u2} k (OrderedRing.toRing.{u2} k _inst_1)) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (OrderedRing.toRing.{u2} k _inst_1)) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (OrderedRing.toRing.{u2} k _inst_1)))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2)))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) _x) (AffineMap.funLike.{u2, u2, u2, u1, u1} k k k E E (OrderedRing.toRing.{u2} k _inst_1) (Ring.toAddCommGroup.{u2} k (OrderedRing.toRing.{u2} k _inst_1)) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (OrderedRing.toRing.{u2} k _inst_1)) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (OrderedRing.toRing.{u2} k _inst_1)))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2)))) (AffineMap.lineMap.{u2, u1, u1} k E E (OrderedRing.toRing.{u2} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2))) a b) r')) (LT.lt.{u1} E (Preorder.toLT.{u1} E (PartialOrder.toPreorder.{u1} E (OrderedAddCommGroup.toPartialOrder.{u1} E _inst_2))) a b))
Case conversion may be inaccurate. Consider using '#align line_map_lt_line_map_iff_of_lt lineMap_lt_lineMap_iff_of_ltₓ'. -/
theorem lineMap_lt_lineMap_iff_of_lt (h : r < r') : lineMap a b r < lineMap a b r' ↔ a < b :=
  by
  simp only [line_map_apply_module]
  rw [← lt_sub_iff_add_lt, add_sub_assoc, ← sub_lt_iff_lt_add', ← sub_smul, ← sub_smul,
    sub_sub_sub_cancel_left, smul_lt_smul_iff_of_pos (sub_pos.2 h)]
  infer_instance
#align line_map_lt_line_map_iff_of_lt lineMap_lt_lineMap_iff_of_lt

/- warning: left_lt_line_map_iff_lt -> left_lt_lineMap_iff_lt is a dubious translation:
lean 3 declaration is
  forall {k : Type.{u1}} {E : Type.{u2}} [_inst_1 : OrderedRing.{u1} k] [_inst_2 : OrderedAddCommGroup.{u2} E] [_inst_3 : Module.{u1, u2} k E (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))] [_inst_4 : OrderedSMul.{u1, u2} k E (OrderedRing.toOrderedSemiring.{u1} k _inst_1) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u1, u2} k E (Semiring.toMonoidWithZero.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (AddZeroClass.toHasZero.{u2} E (AddMonoid.toAddZeroClass.{u2} E (AddCommMonoid.toAddMonoid.{u2} E (OrderedAddCommMonoid.toAddCommMonoid.{u2} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)))))) (Module.toMulActionWithZero.{u1, u2} k E (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)) _inst_3))] {a : E} {b : E} {r : k}, (LT.lt.{u1} k (Preorder.toLT.{u1} k (PartialOrder.toPreorder.{u1} k (OrderedAddCommGroup.toPartialOrder.{u1} k (OrderedRing.toOrderedAddCommGroup.{u1} k _inst_1)))) (OfNat.ofNat.{u1} k 0 (OfNat.mk.{u1} k 0 (Zero.zero.{u1} k (MulZeroClass.toHasZero.{u1} k (NonUnitalNonAssocSemiring.toMulZeroClass.{u1} k (NonUnitalNonAssocRing.toNonUnitalNonAssocSemiring.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))))))) r) -> (Iff (LT.lt.{u2} E (Preorder.toLT.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) a (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (AffineMap.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (fun (_x : AffineMap.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) => k -> E) (AffineMap.hasCoeToFun.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (AffineMap.lineMap.{u1, u2, u2} k E E (OrderedRing.toRing.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) a b) r)) (LT.lt.{u2} E (Preorder.toLT.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) a b))
but is expected to have type
  forall {k : Type.{u2}} {E : Type.{u1}} [_inst_1 : OrderedRing.{u2} k] [_inst_2 : OrderedAddCommGroup.{u1} E] [_inst_3 : Module.{u2, u1} k E (OrderedSemiring.toSemiring.{u2} k (OrderedRing.toOrderedSemiring.{u2} k _inst_1)) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2))] [_inst_4 : OrderedSMul.{u2, u1} k E (OrderedRing.toOrderedSemiring.{u2} k _inst_1) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u2, u1} k E (Semiring.toMonoidWithZero.{u2} k (OrderedSemiring.toSemiring.{u2} k (OrderedRing.toOrderedSemiring.{u2} k _inst_1))) (AddMonoid.toZero.{u1} E (AddCommMonoid.toAddMonoid.{u1} E (OrderedAddCommMonoid.toAddCommMonoid.{u1} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2))))) (Module.toMulActionWithZero.{u2, u1} k E (OrderedSemiring.toSemiring.{u2} k (OrderedRing.toOrderedSemiring.{u2} k _inst_1)) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2)) _inst_3))] {a : E} {b : E} {r : k}, (LT.lt.{u2} k (Preorder.toLT.{u2} k (PartialOrder.toPreorder.{u2} k (OrderedRing.toPartialOrder.{u2} k _inst_1))) (OfNat.ofNat.{u2} k 0 (Zero.toOfNat0.{u2} k (MonoidWithZero.toZero.{u2} k (Semiring.toMonoidWithZero.{u2} k (OrderedSemiring.toSemiring.{u2} k (OrderedRing.toOrderedSemiring.{u2} k _inst_1)))))) r) -> (Iff (LT.lt.{u1} E (Preorder.toLT.{u1} E (PartialOrder.toPreorder.{u1} E (OrderedAddCommGroup.toPartialOrder.{u1} E _inst_2))) a (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (AffineMap.{u2, u2, u2, u1, u1} k k k E E (OrderedRing.toRing.{u2} k _inst_1) (Ring.toAddCommGroup.{u2} k (OrderedRing.toRing.{u2} k _inst_1)) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (OrderedRing.toRing.{u2} k _inst_1)) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (OrderedRing.toRing.{u2} k _inst_1)))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2)))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) _x) (AffineMap.funLike.{u2, u2, u2, u1, u1} k k k E E (OrderedRing.toRing.{u2} k _inst_1) (Ring.toAddCommGroup.{u2} k (OrderedRing.toRing.{u2} k _inst_1)) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (OrderedRing.toRing.{u2} k _inst_1)) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (OrderedRing.toRing.{u2} k _inst_1)))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2)))) (AffineMap.lineMap.{u2, u1, u1} k E E (OrderedRing.toRing.{u2} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2))) a b) r)) (LT.lt.{u1} E (Preorder.toLT.{u1} E (PartialOrder.toPreorder.{u1} E (OrderedAddCommGroup.toPartialOrder.{u1} E _inst_2))) a b))
Case conversion may be inaccurate. Consider using '#align left_lt_line_map_iff_lt left_lt_lineMap_iff_ltₓ'. -/
theorem left_lt_lineMap_iff_lt (h : 0 < r) : a < lineMap a b r ↔ a < b :=
  Iff.trans (by rw [line_map_apply_zero]) (lineMap_lt_lineMap_iff_of_lt h)
#align left_lt_line_map_iff_lt left_lt_lineMap_iff_lt

/- warning: line_map_lt_left_iff_lt -> lineMap_lt_left_iff_lt is a dubious translation:
lean 3 declaration is
  forall {k : Type.{u1}} {E : Type.{u2}} [_inst_1 : OrderedRing.{u1} k] [_inst_2 : OrderedAddCommGroup.{u2} E] [_inst_3 : Module.{u1, u2} k E (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))] [_inst_4 : OrderedSMul.{u1, u2} k E (OrderedRing.toOrderedSemiring.{u1} k _inst_1) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u1, u2} k E (Semiring.toMonoidWithZero.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (AddZeroClass.toHasZero.{u2} E (AddMonoid.toAddZeroClass.{u2} E (AddCommMonoid.toAddMonoid.{u2} E (OrderedAddCommMonoid.toAddCommMonoid.{u2} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)))))) (Module.toMulActionWithZero.{u1, u2} k E (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)) _inst_3))] {a : E} {b : E} {r : k}, (LT.lt.{u1} k (Preorder.toLT.{u1} k (PartialOrder.toPreorder.{u1} k (OrderedAddCommGroup.toPartialOrder.{u1} k (OrderedRing.toOrderedAddCommGroup.{u1} k _inst_1)))) (OfNat.ofNat.{u1} k 0 (OfNat.mk.{u1} k 0 (Zero.zero.{u1} k (MulZeroClass.toHasZero.{u1} k (NonUnitalNonAssocSemiring.toMulZeroClass.{u1} k (NonUnitalNonAssocRing.toNonUnitalNonAssocSemiring.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))))))) r) -> (Iff (LT.lt.{u2} E (Preorder.toLT.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (AffineMap.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (fun (_x : AffineMap.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) => k -> E) (AffineMap.hasCoeToFun.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (AffineMap.lineMap.{u1, u2, u2} k E E (OrderedRing.toRing.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) a b) r) a) (LT.lt.{u2} E (Preorder.toLT.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) b a))
but is expected to have type
  forall {k : Type.{u2}} {E : Type.{u1}} [_inst_1 : OrderedRing.{u2} k] [_inst_2 : OrderedAddCommGroup.{u1} E] [_inst_3 : Module.{u2, u1} k E (OrderedSemiring.toSemiring.{u2} k (OrderedRing.toOrderedSemiring.{u2} k _inst_1)) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2))] [_inst_4 : OrderedSMul.{u2, u1} k E (OrderedRing.toOrderedSemiring.{u2} k _inst_1) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u2, u1} k E (Semiring.toMonoidWithZero.{u2} k (OrderedSemiring.toSemiring.{u2} k (OrderedRing.toOrderedSemiring.{u2} k _inst_1))) (AddMonoid.toZero.{u1} E (AddCommMonoid.toAddMonoid.{u1} E (OrderedAddCommMonoid.toAddCommMonoid.{u1} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2))))) (Module.toMulActionWithZero.{u2, u1} k E (OrderedSemiring.toSemiring.{u2} k (OrderedRing.toOrderedSemiring.{u2} k _inst_1)) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2)) _inst_3))] {a : E} {b : E} {r : k}, (LT.lt.{u2} k (Preorder.toLT.{u2} k (PartialOrder.toPreorder.{u2} k (OrderedRing.toPartialOrder.{u2} k _inst_1))) (OfNat.ofNat.{u2} k 0 (Zero.toOfNat0.{u2} k (MonoidWithZero.toZero.{u2} k (Semiring.toMonoidWithZero.{u2} k (OrderedSemiring.toSemiring.{u2} k (OrderedRing.toOrderedSemiring.{u2} k _inst_1)))))) r) -> (Iff (LT.lt.{u1} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (Preorder.toLT.{u1} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (PartialOrder.toPreorder.{u1} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (OrderedAddCommGroup.toPartialOrder.{u1} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) _inst_2))) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (AffineMap.{u2, u2, u2, u1, u1} k k k E E (OrderedRing.toRing.{u2} k _inst_1) (Ring.toAddCommGroup.{u2} k (OrderedRing.toRing.{u2} k _inst_1)) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (OrderedRing.toRing.{u2} k _inst_1)) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (OrderedRing.toRing.{u2} k _inst_1)))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2)))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) _x) (AffineMap.funLike.{u2, u2, u2, u1, u1} k k k E E (OrderedRing.toRing.{u2} k _inst_1) (Ring.toAddCommGroup.{u2} k (OrderedRing.toRing.{u2} k _inst_1)) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (OrderedRing.toRing.{u2} k _inst_1)) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (OrderedRing.toRing.{u2} k _inst_1)))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2)))) (AffineMap.lineMap.{u2, u1, u1} k E E (OrderedRing.toRing.{u2} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2))) a b) r) a) (LT.lt.{u1} E (Preorder.toLT.{u1} E (PartialOrder.toPreorder.{u1} E (OrderedAddCommGroup.toPartialOrder.{u1} E _inst_2))) b a))
Case conversion may be inaccurate. Consider using '#align line_map_lt_left_iff_lt lineMap_lt_left_iff_ltₓ'. -/
theorem lineMap_lt_left_iff_lt (h : 0 < r) : lineMap a b r < a ↔ b < a :=
  @left_lt_lineMap_iff_lt k Eᵒᵈ _ _ _ _ _ _ _ h
#align line_map_lt_left_iff_lt lineMap_lt_left_iff_lt

/- warning: line_map_lt_right_iff_lt -> lineMap_lt_right_iff_lt is a dubious translation:
lean 3 declaration is
  forall {k : Type.{u1}} {E : Type.{u2}} [_inst_1 : OrderedRing.{u1} k] [_inst_2 : OrderedAddCommGroup.{u2} E] [_inst_3 : Module.{u1, u2} k E (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))] [_inst_4 : OrderedSMul.{u1, u2} k E (OrderedRing.toOrderedSemiring.{u1} k _inst_1) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u1, u2} k E (Semiring.toMonoidWithZero.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (AddZeroClass.toHasZero.{u2} E (AddMonoid.toAddZeroClass.{u2} E (AddCommMonoid.toAddMonoid.{u2} E (OrderedAddCommMonoid.toAddCommMonoid.{u2} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)))))) (Module.toMulActionWithZero.{u1, u2} k E (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)) _inst_3))] {a : E} {b : E} {r : k}, (LT.lt.{u1} k (Preorder.toLT.{u1} k (PartialOrder.toPreorder.{u1} k (OrderedAddCommGroup.toPartialOrder.{u1} k (OrderedRing.toOrderedAddCommGroup.{u1} k _inst_1)))) r (OfNat.ofNat.{u1} k 1 (OfNat.mk.{u1} k 1 (One.one.{u1} k (AddMonoidWithOne.toOne.{u1} k (AddGroupWithOne.toAddMonoidWithOne.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))))))) -> (Iff (LT.lt.{u2} E (Preorder.toLT.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (AffineMap.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (fun (_x : AffineMap.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) => k -> E) (AffineMap.hasCoeToFun.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (AffineMap.lineMap.{u1, u2, u2} k E E (OrderedRing.toRing.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) a b) r) b) (LT.lt.{u2} E (Preorder.toLT.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) a b))
but is expected to have type
  forall {k : Type.{u2}} {E : Type.{u1}} [_inst_1 : OrderedRing.{u2} k] [_inst_2 : OrderedAddCommGroup.{u1} E] [_inst_3 : Module.{u2, u1} k E (OrderedSemiring.toSemiring.{u2} k (OrderedRing.toOrderedSemiring.{u2} k _inst_1)) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2))] [_inst_4 : OrderedSMul.{u2, u1} k E (OrderedRing.toOrderedSemiring.{u2} k _inst_1) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u2, u1} k E (Semiring.toMonoidWithZero.{u2} k (OrderedSemiring.toSemiring.{u2} k (OrderedRing.toOrderedSemiring.{u2} k _inst_1))) (AddMonoid.toZero.{u1} E (AddCommMonoid.toAddMonoid.{u1} E (OrderedAddCommMonoid.toAddCommMonoid.{u1} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2))))) (Module.toMulActionWithZero.{u2, u1} k E (OrderedSemiring.toSemiring.{u2} k (OrderedRing.toOrderedSemiring.{u2} k _inst_1)) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2)) _inst_3))] {a : E} {b : E} {r : k}, (LT.lt.{u2} k (Preorder.toLT.{u2} k (PartialOrder.toPreorder.{u2} k (OrderedRing.toPartialOrder.{u2} k _inst_1))) r (OfNat.ofNat.{u2} k 1 (One.toOfNat1.{u2} k (NonAssocRing.toOne.{u2} k (Ring.toNonAssocRing.{u2} k (OrderedRing.toRing.{u2} k _inst_1)))))) -> (Iff (LT.lt.{u1} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (Preorder.toLT.{u1} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (PartialOrder.toPreorder.{u1} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (OrderedAddCommGroup.toPartialOrder.{u1} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) _inst_2))) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (AffineMap.{u2, u2, u2, u1, u1} k k k E E (OrderedRing.toRing.{u2} k _inst_1) (Ring.toAddCommGroup.{u2} k (OrderedRing.toRing.{u2} k _inst_1)) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (OrderedRing.toRing.{u2} k _inst_1)) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (OrderedRing.toRing.{u2} k _inst_1)))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2)))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) _x) (AffineMap.funLike.{u2, u2, u2, u1, u1} k k k E E (OrderedRing.toRing.{u2} k _inst_1) (Ring.toAddCommGroup.{u2} k (OrderedRing.toRing.{u2} k _inst_1)) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (OrderedRing.toRing.{u2} k _inst_1)) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (OrderedRing.toRing.{u2} k _inst_1)))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2)))) (AffineMap.lineMap.{u2, u1, u1} k E E (OrderedRing.toRing.{u2} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2))) a b) r) b) (LT.lt.{u1} E (Preorder.toLT.{u1} E (PartialOrder.toPreorder.{u1} E (OrderedAddCommGroup.toPartialOrder.{u1} E _inst_2))) a b))
Case conversion may be inaccurate. Consider using '#align line_map_lt_right_iff_lt lineMap_lt_right_iff_ltₓ'. -/
theorem lineMap_lt_right_iff_lt (h : r < 1) : lineMap a b r < b ↔ a < b :=
  Iff.trans (by rw [line_map_apply_one]) (lineMap_lt_lineMap_iff_of_lt h)
#align line_map_lt_right_iff_lt lineMap_lt_right_iff_lt

/- warning: right_lt_line_map_iff_lt -> right_lt_lineMap_iff_lt is a dubious translation:
lean 3 declaration is
  forall {k : Type.{u1}} {E : Type.{u2}} [_inst_1 : OrderedRing.{u1} k] [_inst_2 : OrderedAddCommGroup.{u2} E] [_inst_3 : Module.{u1, u2} k E (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))] [_inst_4 : OrderedSMul.{u1, u2} k E (OrderedRing.toOrderedSemiring.{u1} k _inst_1) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u1, u2} k E (Semiring.toMonoidWithZero.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (AddZeroClass.toHasZero.{u2} E (AddMonoid.toAddZeroClass.{u2} E (AddCommMonoid.toAddMonoid.{u2} E (OrderedAddCommMonoid.toAddCommMonoid.{u2} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)))))) (Module.toMulActionWithZero.{u1, u2} k E (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1)) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)) _inst_3))] {a : E} {b : E} {r : k}, (LT.lt.{u1} k (Preorder.toLT.{u1} k (PartialOrder.toPreorder.{u1} k (OrderedAddCommGroup.toPartialOrder.{u1} k (OrderedRing.toOrderedAddCommGroup.{u1} k _inst_1)))) r (OfNat.ofNat.{u1} k 1 (OfNat.mk.{u1} k 1 (One.one.{u1} k (AddMonoidWithOne.toOne.{u1} k (AddGroupWithOne.toAddMonoidWithOne.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))))))) -> (Iff (LT.lt.{u2} E (Preorder.toLT.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) b (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (AffineMap.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (fun (_x : AffineMap.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) => k -> E) (AffineMap.hasCoeToFun.{u1, u1, u1, u2, u2} k k k E E (OrderedRing.toRing.{u1} k _inst_1) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (OrderedRing.toRing.{u1} k _inst_1)))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (OrderedRing.toRing.{u1} k _inst_1))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (OrderedRing.toRing.{u1} k _inst_1))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (AffineMap.lineMap.{u1, u2, u2} k E E (OrderedRing.toRing.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) a b) r)) (LT.lt.{u2} E (Preorder.toLT.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) b a))
but is expected to have type
  forall {k : Type.{u2}} {E : Type.{u1}} [_inst_1 : OrderedRing.{u2} k] [_inst_2 : OrderedAddCommGroup.{u1} E] [_inst_3 : Module.{u2, u1} k E (OrderedSemiring.toSemiring.{u2} k (OrderedRing.toOrderedSemiring.{u2} k _inst_1)) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2))] [_inst_4 : OrderedSMul.{u2, u1} k E (OrderedRing.toOrderedSemiring.{u2} k _inst_1) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u2, u1} k E (Semiring.toMonoidWithZero.{u2} k (OrderedSemiring.toSemiring.{u2} k (OrderedRing.toOrderedSemiring.{u2} k _inst_1))) (AddMonoid.toZero.{u1} E (AddCommMonoid.toAddMonoid.{u1} E (OrderedAddCommMonoid.toAddCommMonoid.{u1} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2))))) (Module.toMulActionWithZero.{u2, u1} k E (OrderedSemiring.toSemiring.{u2} k (OrderedRing.toOrderedSemiring.{u2} k _inst_1)) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2)) _inst_3))] {a : E} {b : E} {r : k}, (LT.lt.{u2} k (Preorder.toLT.{u2} k (PartialOrder.toPreorder.{u2} k (OrderedRing.toPartialOrder.{u2} k _inst_1))) r (OfNat.ofNat.{u2} k 1 (One.toOfNat1.{u2} k (NonAssocRing.toOne.{u2} k (Ring.toNonAssocRing.{u2} k (OrderedRing.toRing.{u2} k _inst_1)))))) -> (Iff (LT.lt.{u1} E (Preorder.toLT.{u1} E (PartialOrder.toPreorder.{u1} E (OrderedAddCommGroup.toPartialOrder.{u1} E _inst_2))) b (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (AffineMap.{u2, u2, u2, u1, u1} k k k E E (OrderedRing.toRing.{u2} k _inst_1) (Ring.toAddCommGroup.{u2} k (OrderedRing.toRing.{u2} k _inst_1)) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (OrderedRing.toRing.{u2} k _inst_1)) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (OrderedRing.toRing.{u2} k _inst_1)))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2)))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) _x) (AffineMap.funLike.{u2, u2, u2, u1, u1} k k k E E (OrderedRing.toRing.{u2} k _inst_1) (Ring.toAddCommGroup.{u2} k (OrderedRing.toRing.{u2} k _inst_1)) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (OrderedRing.toRing.{u2} k _inst_1)) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (OrderedRing.toRing.{u2} k _inst_1)))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2)))) (AffineMap.lineMap.{u2, u1, u1} k E E (OrderedRing.toRing.{u2} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2))) a b) r)) (LT.lt.{u1} E (Preorder.toLT.{u1} E (PartialOrder.toPreorder.{u1} E (OrderedAddCommGroup.toPartialOrder.{u1} E _inst_2))) b a))
Case conversion may be inaccurate. Consider using '#align right_lt_line_map_iff_lt right_lt_lineMap_iff_ltₓ'. -/
theorem right_lt_lineMap_iff_lt (h : r < 1) : b < lineMap a b r ↔ b < a :=
  @lineMap_lt_right_iff_lt k Eᵒᵈ _ _ _ _ _ _ _ h
#align right_lt_line_map_iff_lt right_lt_lineMap_iff_lt

end OrderedRing

section LinearOrderedRing

variable [LinearOrderedRing k] [OrderedAddCommGroup E] [Module k E] [OrderedSMul k E]
  [Invertible (2 : k)] {a a' b b' : E} {r r' : k}

/- warning: midpoint_le_midpoint -> midpoint_le_midpoint is a dubious translation:
lean 3 declaration is
  forall {k : Type.{u1}} {E : Type.{u2}} [_inst_1 : LinearOrderedRing.{u1} k] [_inst_2 : OrderedAddCommGroup.{u2} E] [_inst_3 : Module.{u1, u2} k E (Ring.toSemiring.{u1} k (StrictOrderedRing.toRing.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k _inst_1))) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))] [_inst_4 : OrderedSMul.{u1, u2} k E (StrictOrderedSemiring.toOrderedSemiring.{u1} k (StrictOrderedRing.toStrictOrderedSemiring.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k _inst_1))) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u1, u2} k E (Semiring.toMonoidWithZero.{u1} k (Ring.toSemiring.{u1} k (StrictOrderedRing.toRing.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k _inst_1)))) (AddZeroClass.toHasZero.{u2} E (AddMonoid.toAddZeroClass.{u2} E (AddCommMonoid.toAddMonoid.{u2} E (OrderedAddCommMonoid.toAddCommMonoid.{u2} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)))))) (Module.toMulActionWithZero.{u1, u2} k E (Ring.toSemiring.{u1} k (StrictOrderedRing.toRing.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k _inst_1))) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)) _inst_3))] [_inst_5 : Invertible.{u1} k (Distrib.toHasMul.{u1} k (Ring.toDistrib.{u1} k (StrictOrderedRing.toRing.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k _inst_1)))) (AddMonoidWithOne.toOne.{u1} k (AddGroupWithOne.toAddMonoidWithOne.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (StrictOrderedRing.toRing.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k _inst_1)))))) (OfNat.ofNat.{u1} k 2 (OfNat.mk.{u1} k 2 (bit0.{u1} k (Distrib.toHasAdd.{u1} k (Ring.toDistrib.{u1} k (StrictOrderedRing.toRing.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k _inst_1)))) (One.one.{u1} k (AddMonoidWithOne.toOne.{u1} k (AddGroupWithOne.toAddMonoidWithOne.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (StrictOrderedRing.toRing.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k _inst_1))))))))))] {a : E} {a' : E} {b : E} {b' : E}, (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) a a') -> (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) b b') -> (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) (midpoint.{u1, u2, u2} k E E (StrictOrderedRing.toRing.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k _inst_1)) _inst_5 (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) a b) (midpoint.{u1, u2, u2} k E E (StrictOrderedRing.toRing.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k _inst_1)) _inst_5 (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) a' b'))
but is expected to have type
  forall {k : Type.{u1}} {E : Type.{u2}} [_inst_1 : LinearOrderedRing.{u1} k] [_inst_2 : OrderedAddCommGroup.{u2} E] [_inst_3 : Module.{u1, u2} k E (StrictOrderedSemiring.toSemiring.{u1} k (LinearOrderedSemiring.toStrictOrderedSemiring.{u1} k (LinearOrderedRing.toLinearOrderedSemiring.{u1} k _inst_1))) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2))] [_inst_4 : OrderedSMul.{u1, u2} k E (StrictOrderedSemiring.toOrderedSemiring.{u1} k (LinearOrderedSemiring.toStrictOrderedSemiring.{u1} k (LinearOrderedRing.toLinearOrderedSemiring.{u1} k _inst_1))) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u1, u2} k E (Semiring.toMonoidWithZero.{u1} k (StrictOrderedSemiring.toSemiring.{u1} k (LinearOrderedSemiring.toStrictOrderedSemiring.{u1} k (LinearOrderedRing.toLinearOrderedSemiring.{u1} k _inst_1)))) (AddMonoid.toZero.{u2} E (AddCommMonoid.toAddMonoid.{u2} E (OrderedAddCommMonoid.toAddCommMonoid.{u2} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2))))) (Module.toMulActionWithZero.{u1, u2} k E (StrictOrderedSemiring.toSemiring.{u1} k (LinearOrderedSemiring.toStrictOrderedSemiring.{u1} k (LinearOrderedRing.toLinearOrderedSemiring.{u1} k _inst_1))) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) _inst_3))] [_inst_5 : Invertible.{u1} k (NonUnitalNonAssocRing.toMul.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (StrictOrderedRing.toRing.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k _inst_1))))) (NonAssocRing.toOne.{u1} k (Ring.toNonAssocRing.{u1} k (StrictOrderedRing.toRing.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k _inst_1)))) (OfNat.ofNat.{u1} k 2 (instOfNat.{u1} k 2 (NonAssocRing.toNatCast.{u1} k (Ring.toNonAssocRing.{u1} k (StrictOrderedRing.toRing.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k _inst_1)))) (instAtLeastTwoHAddNatInstHAddInstAddNatOfNat (OfNat.ofNat.{0} Nat 0 (instOfNatNat 0)))))] {a : E} {a' : E} {b : E} {b' : E}, (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) a a') -> (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) b b') -> (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) (midpoint.{u1, u2, u2} k E E (StrictOrderedRing.toRing.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k _inst_1)) _inst_5 (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) a b) (midpoint.{u1, u2, u2} k E E (StrictOrderedRing.toRing.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k _inst_1)) _inst_5 (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) a' b'))
Case conversion may be inaccurate. Consider using '#align midpoint_le_midpoint midpoint_le_midpointₓ'. -/
theorem midpoint_le_midpoint (ha : a ≤ a') (hb : b ≤ b') : midpoint k a b ≤ midpoint k a' b' :=
  lineMap_mono_endpoints ha hb (invOf_nonneg.2 zero_le_two) <| invOf_le_one one_le_two
#align midpoint_le_midpoint midpoint_le_midpoint

end LinearOrderedRing

section LinearOrderedField

variable [LinearOrderedField k] [OrderedAddCommGroup E]

variable [Module k E] [OrderedSMul k E]

section

variable {a b : E} {r r' : k}

/- warning: line_map_le_line_map_iff_of_lt -> lineMap_le_lineMap_iff_of_lt is a dubious translation:
lean 3 declaration is
  forall {k : Type.{u1}} {E : Type.{u2}} [_inst_1 : LinearOrderedField.{u1} k] [_inst_2 : OrderedAddCommGroup.{u2} E] [_inst_3 : Module.{u1, u2} k E (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))] [_inst_4 : OrderedSMul.{u1, u2} k E (StrictOrderedSemiring.toOrderedSemiring.{u1} k (StrictOrderedRing.toStrictOrderedSemiring.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k (LinearOrderedCommRing.toLinearOrderedRing.{u1} k (LinearOrderedField.toLinearOrderedCommRing.{u1} k _inst_1))))) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u1, u2} k E (Semiring.toMonoidWithZero.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (AddZeroClass.toHasZero.{u2} E (AddMonoid.toAddZeroClass.{u2} E (AddCommMonoid.toAddMonoid.{u2} E (OrderedAddCommMonoid.toAddCommMonoid.{u2} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)))))) (Module.toMulActionWithZero.{u1, u2} k E (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)) _inst_3))] {a : E} {b : E} {r : k} {r' : k}, (LT.lt.{u1} k (Preorder.toLT.{u1} k (PartialOrder.toPreorder.{u1} k (OrderedAddCommGroup.toPartialOrder.{u1} k (StrictOrderedRing.toOrderedAddCommGroup.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k (LinearOrderedCommRing.toLinearOrderedRing.{u1} k (LinearOrderedField.toLinearOrderedCommRing.{u1} k _inst_1))))))) r r') -> (Iff (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (AffineMap.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (fun (_x : AffineMap.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) => k -> E) (AffineMap.hasCoeToFun.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (AffineMap.lineMap.{u1, u2, u2} k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) a b) r) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (AffineMap.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (fun (_x : AffineMap.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) => k -> E) (AffineMap.hasCoeToFun.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (AffineMap.lineMap.{u1, u2, u2} k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) a b) r')) (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) a b))
but is expected to have type
  forall {k : Type.{u2}} {E : Type.{u1}} [_inst_1 : LinearOrderedField.{u2} k] [_inst_2 : OrderedAddCommGroup.{u1} E] [_inst_3 : Module.{u2, u1} k E (DivisionSemiring.toSemiring.{u2} k (Semifield.toDivisionSemiring.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1)))) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2))] [_inst_4 : OrderedSMul.{u2, u1} k E (OrderedCommSemiring.toOrderedSemiring.{u2} k (StrictOrderedCommSemiring.toOrderedCommSemiring.{u2} k (LinearOrderedCommSemiring.toStrictOrderedCommSemiring.{u2} k (LinearOrderedSemifield.toLinearOrderedCommSemiring.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1))))) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u2, u1} k E (Semiring.toMonoidWithZero.{u2} k (DivisionSemiring.toSemiring.{u2} k (Semifield.toDivisionSemiring.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1))))) (AddMonoid.toZero.{u1} E (AddCommMonoid.toAddMonoid.{u1} E (OrderedAddCommMonoid.toAddCommMonoid.{u1} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2))))) (Module.toMulActionWithZero.{u2, u1} k E (DivisionSemiring.toSemiring.{u2} k (Semifield.toDivisionSemiring.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1)))) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2)) _inst_3))] {a : E} {b : E} {r : k} {r' : k}, (LT.lt.{u2} k (Preorder.toLT.{u2} k (PartialOrder.toPreorder.{u2} k (StrictOrderedRing.toPartialOrder.{u2} k (LinearOrderedRing.toStrictOrderedRing.{u2} k (LinearOrderedCommRing.toLinearOrderedRing.{u2} k (LinearOrderedField.toLinearOrderedCommRing.{u2} k _inst_1)))))) r r') -> (Iff (LE.le.{u1} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (Preorder.toLE.{u1} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (PartialOrder.toPreorder.{u1} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (OrderedAddCommGroup.toPartialOrder.{u1} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) _inst_2))) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (AffineMap.{u2, u2, u2, u1, u1} k k k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2)))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) _x) (AffineMap.funLike.{u2, u2, u2, u1, u1} k k k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2)))) (AffineMap.lineMap.{u2, u1, u1} k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2))) a b) r) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (AffineMap.{u2, u2, u2, u1, u1} k k k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2)))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) _x) (AffineMap.funLike.{u2, u2, u2, u1, u1} k k k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2)))) (AffineMap.lineMap.{u2, u1, u1} k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2))) a b) r')) (LE.le.{u1} E (Preorder.toLE.{u1} E (PartialOrder.toPreorder.{u1} E (OrderedAddCommGroup.toPartialOrder.{u1} E _inst_2))) a b))
Case conversion may be inaccurate. Consider using '#align line_map_le_line_map_iff_of_lt lineMap_le_lineMap_iff_of_ltₓ'. -/
theorem lineMap_le_lineMap_iff_of_lt (h : r < r') : lineMap a b r ≤ lineMap a b r' ↔ a ≤ b :=
  by
  simp only [line_map_apply_module]
  rw [← le_sub_iff_add_le, add_sub_assoc, ← sub_le_iff_le_add', ← sub_smul, ← sub_smul,
    sub_sub_sub_cancel_left, smul_le_smul_iff_of_pos (sub_pos.2 h)]
  infer_instance
#align line_map_le_line_map_iff_of_lt lineMap_le_lineMap_iff_of_lt

/- warning: left_le_line_map_iff_le -> left_le_lineMap_iff_le is a dubious translation:
lean 3 declaration is
  forall {k : Type.{u1}} {E : Type.{u2}} [_inst_1 : LinearOrderedField.{u1} k] [_inst_2 : OrderedAddCommGroup.{u2} E] [_inst_3 : Module.{u1, u2} k E (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))] [_inst_4 : OrderedSMul.{u1, u2} k E (StrictOrderedSemiring.toOrderedSemiring.{u1} k (StrictOrderedRing.toStrictOrderedSemiring.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k (LinearOrderedCommRing.toLinearOrderedRing.{u1} k (LinearOrderedField.toLinearOrderedCommRing.{u1} k _inst_1))))) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u1, u2} k E (Semiring.toMonoidWithZero.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (AddZeroClass.toHasZero.{u2} E (AddMonoid.toAddZeroClass.{u2} E (AddCommMonoid.toAddMonoid.{u2} E (OrderedAddCommMonoid.toAddCommMonoid.{u2} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)))))) (Module.toMulActionWithZero.{u1, u2} k E (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)) _inst_3))] {a : E} {b : E} {r : k}, (LT.lt.{u1} k (Preorder.toLT.{u1} k (PartialOrder.toPreorder.{u1} k (OrderedAddCommGroup.toPartialOrder.{u1} k (StrictOrderedRing.toOrderedAddCommGroup.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k (LinearOrderedCommRing.toLinearOrderedRing.{u1} k (LinearOrderedField.toLinearOrderedCommRing.{u1} k _inst_1))))))) (OfNat.ofNat.{u1} k 0 (OfNat.mk.{u1} k 0 (Zero.zero.{u1} k (MulZeroClass.toHasZero.{u1} k (NonUnitalNonAssocSemiring.toMulZeroClass.{u1} k (NonUnitalNonAssocRing.toNonUnitalNonAssocSemiring.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))))))) r) -> (Iff (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) a (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (AffineMap.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (fun (_x : AffineMap.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) => k -> E) (AffineMap.hasCoeToFun.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (AffineMap.lineMap.{u1, u2, u2} k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) a b) r)) (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) a b))
but is expected to have type
  forall {k : Type.{u2}} {E : Type.{u1}} [_inst_1 : LinearOrderedField.{u2} k] [_inst_2 : OrderedAddCommGroup.{u1} E] [_inst_3 : Module.{u2, u1} k E (DivisionSemiring.toSemiring.{u2} k (Semifield.toDivisionSemiring.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1)))) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2))] [_inst_4 : OrderedSMul.{u2, u1} k E (OrderedCommSemiring.toOrderedSemiring.{u2} k (StrictOrderedCommSemiring.toOrderedCommSemiring.{u2} k (LinearOrderedCommSemiring.toStrictOrderedCommSemiring.{u2} k (LinearOrderedSemifield.toLinearOrderedCommSemiring.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1))))) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u2, u1} k E (Semiring.toMonoidWithZero.{u2} k (DivisionSemiring.toSemiring.{u2} k (Semifield.toDivisionSemiring.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1))))) (AddMonoid.toZero.{u1} E (AddCommMonoid.toAddMonoid.{u1} E (OrderedAddCommMonoid.toAddCommMonoid.{u1} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2))))) (Module.toMulActionWithZero.{u2, u1} k E (DivisionSemiring.toSemiring.{u2} k (Semifield.toDivisionSemiring.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1)))) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2)) _inst_3))] {a : E} {b : E} {r : k}, (LT.lt.{u2} k (Preorder.toLT.{u2} k (PartialOrder.toPreorder.{u2} k (StrictOrderedRing.toPartialOrder.{u2} k (LinearOrderedRing.toStrictOrderedRing.{u2} k (LinearOrderedCommRing.toLinearOrderedRing.{u2} k (LinearOrderedField.toLinearOrderedCommRing.{u2} k _inst_1)))))) (OfNat.ofNat.{u2} k 0 (Zero.toOfNat0.{u2} k (CommMonoidWithZero.toZero.{u2} k (CommGroupWithZero.toCommMonoidWithZero.{u2} k (Semifield.toCommGroupWithZero.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1))))))) r) -> (Iff (LE.le.{u1} E (Preorder.toLE.{u1} E (PartialOrder.toPreorder.{u1} E (OrderedAddCommGroup.toPartialOrder.{u1} E _inst_2))) a (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (AffineMap.{u2, u2, u2, u1, u1} k k k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2)))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) _x) (AffineMap.funLike.{u2, u2, u2, u1, u1} k k k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2)))) (AffineMap.lineMap.{u2, u1, u1} k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2))) a b) r)) (LE.le.{u1} E (Preorder.toLE.{u1} E (PartialOrder.toPreorder.{u1} E (OrderedAddCommGroup.toPartialOrder.{u1} E _inst_2))) a b))
Case conversion may be inaccurate. Consider using '#align left_le_line_map_iff_le left_le_lineMap_iff_leₓ'. -/
theorem left_le_lineMap_iff_le (h : 0 < r) : a ≤ lineMap a b r ↔ a ≤ b :=
  Iff.trans (by rw [line_map_apply_zero]) (lineMap_le_lineMap_iff_of_lt h)
#align left_le_line_map_iff_le left_le_lineMap_iff_le

/- warning: left_le_midpoint -> left_le_midpoint is a dubious translation:
lean 3 declaration is
  forall {k : Type.{u1}} {E : Type.{u2}} [_inst_1 : LinearOrderedField.{u1} k] [_inst_2 : OrderedAddCommGroup.{u2} E] [_inst_3 : Module.{u1, u2} k E (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))] [_inst_4 : OrderedSMul.{u1, u2} k E (StrictOrderedSemiring.toOrderedSemiring.{u1} k (StrictOrderedRing.toStrictOrderedSemiring.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k (LinearOrderedCommRing.toLinearOrderedRing.{u1} k (LinearOrderedField.toLinearOrderedCommRing.{u1} k _inst_1))))) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u1, u2} k E (Semiring.toMonoidWithZero.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (AddZeroClass.toHasZero.{u2} E (AddMonoid.toAddZeroClass.{u2} E (AddCommMonoid.toAddMonoid.{u2} E (OrderedAddCommMonoid.toAddCommMonoid.{u2} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)))))) (Module.toMulActionWithZero.{u1, u2} k E (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)) _inst_3))] {a : E} {b : E}, Iff (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) a (midpoint.{u1, u2, u2} k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (invertibleTwo.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)) (StrictOrderedSemiring.to_charZero.{u1} k (StrictOrderedRing.toStrictOrderedSemiring.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k (LinearOrderedCommRing.toLinearOrderedRing.{u1} k (LinearOrderedField.toLinearOrderedCommRing.{u1} k _inst_1)))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) a b)) (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) a b)
but is expected to have type
  forall {k : Type.{u1}} {E : Type.{u2}} [_inst_1 : LinearOrderedField.{u1} k] [_inst_2 : OrderedAddCommGroup.{u2} E] [_inst_3 : Module.{u1, u2} k E (DivisionSemiring.toSemiring.{u1} k (Semifield.toDivisionSemiring.{u1} k (LinearOrderedSemifield.toSemifield.{u1} k (LinearOrderedField.toLinearOrderedSemifield.{u1} k _inst_1)))) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2))] [_inst_4 : OrderedSMul.{u1, u2} k E (OrderedCommSemiring.toOrderedSemiring.{u1} k (StrictOrderedCommSemiring.toOrderedCommSemiring.{u1} k (LinearOrderedCommSemiring.toStrictOrderedCommSemiring.{u1} k (LinearOrderedSemifield.toLinearOrderedCommSemiring.{u1} k (LinearOrderedField.toLinearOrderedSemifield.{u1} k _inst_1))))) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u1, u2} k E (Semiring.toMonoidWithZero.{u1} k (DivisionSemiring.toSemiring.{u1} k (Semifield.toDivisionSemiring.{u1} k (LinearOrderedSemifield.toSemifield.{u1} k (LinearOrderedField.toLinearOrderedSemifield.{u1} k _inst_1))))) (AddMonoid.toZero.{u2} E (AddCommMonoid.toAddMonoid.{u2} E (OrderedAddCommMonoid.toAddCommMonoid.{u2} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2))))) (Module.toMulActionWithZero.{u1, u2} k E (DivisionSemiring.toSemiring.{u1} k (Semifield.toDivisionSemiring.{u1} k (LinearOrderedSemifield.toSemifield.{u1} k (LinearOrderedField.toLinearOrderedSemifield.{u1} k _inst_1)))) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) _inst_3))] {a : E} {b : E}, Iff (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) a (midpoint.{u1, u2, u2} k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (invertibleTwo.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)) (StrictOrderedSemiring.to_charZero.{u1} k (LinearOrderedSemiring.toStrictOrderedSemiring.{u1} k (LinearOrderedCommSemiring.toLinearOrderedSemiring.{u1} k (LinearOrderedSemifield.toLinearOrderedCommSemiring.{u1} k (LinearOrderedField.toLinearOrderedSemifield.{u1} k _inst_1)))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) a b)) (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) a b)
Case conversion may be inaccurate. Consider using '#align left_le_midpoint left_le_midpointₓ'. -/
@[simp]
theorem left_le_midpoint : a ≤ midpoint k a b ↔ a ≤ b :=
  left_le_lineMap_iff_le <| inv_pos.2 zero_lt_two
#align left_le_midpoint left_le_midpoint

/- warning: line_map_le_left_iff_le -> lineMap_le_left_iff_le is a dubious translation:
lean 3 declaration is
  forall {k : Type.{u1}} {E : Type.{u2}} [_inst_1 : LinearOrderedField.{u1} k] [_inst_2 : OrderedAddCommGroup.{u2} E] [_inst_3 : Module.{u1, u2} k E (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))] [_inst_4 : OrderedSMul.{u1, u2} k E (StrictOrderedSemiring.toOrderedSemiring.{u1} k (StrictOrderedRing.toStrictOrderedSemiring.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k (LinearOrderedCommRing.toLinearOrderedRing.{u1} k (LinearOrderedField.toLinearOrderedCommRing.{u1} k _inst_1))))) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u1, u2} k E (Semiring.toMonoidWithZero.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (AddZeroClass.toHasZero.{u2} E (AddMonoid.toAddZeroClass.{u2} E (AddCommMonoid.toAddMonoid.{u2} E (OrderedAddCommMonoid.toAddCommMonoid.{u2} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)))))) (Module.toMulActionWithZero.{u1, u2} k E (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)) _inst_3))] {a : E} {b : E} {r : k}, (LT.lt.{u1} k (Preorder.toLT.{u1} k (PartialOrder.toPreorder.{u1} k (OrderedAddCommGroup.toPartialOrder.{u1} k (StrictOrderedRing.toOrderedAddCommGroup.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k (LinearOrderedCommRing.toLinearOrderedRing.{u1} k (LinearOrderedField.toLinearOrderedCommRing.{u1} k _inst_1))))))) (OfNat.ofNat.{u1} k 0 (OfNat.mk.{u1} k 0 (Zero.zero.{u1} k (MulZeroClass.toHasZero.{u1} k (NonUnitalNonAssocSemiring.toMulZeroClass.{u1} k (NonUnitalNonAssocRing.toNonUnitalNonAssocSemiring.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))))))) r) -> (Iff (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (AffineMap.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (fun (_x : AffineMap.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) => k -> E) (AffineMap.hasCoeToFun.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (AffineMap.lineMap.{u1, u2, u2} k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) a b) r) a) (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) b a))
but is expected to have type
  forall {k : Type.{u2}} {E : Type.{u1}} [_inst_1 : LinearOrderedField.{u2} k] [_inst_2 : OrderedAddCommGroup.{u1} E] [_inst_3 : Module.{u2, u1} k E (DivisionSemiring.toSemiring.{u2} k (Semifield.toDivisionSemiring.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1)))) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2))] [_inst_4 : OrderedSMul.{u2, u1} k E (OrderedCommSemiring.toOrderedSemiring.{u2} k (StrictOrderedCommSemiring.toOrderedCommSemiring.{u2} k (LinearOrderedCommSemiring.toStrictOrderedCommSemiring.{u2} k (LinearOrderedSemifield.toLinearOrderedCommSemiring.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1))))) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u2, u1} k E (Semiring.toMonoidWithZero.{u2} k (DivisionSemiring.toSemiring.{u2} k (Semifield.toDivisionSemiring.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1))))) (AddMonoid.toZero.{u1} E (AddCommMonoid.toAddMonoid.{u1} E (OrderedAddCommMonoid.toAddCommMonoid.{u1} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2))))) (Module.toMulActionWithZero.{u2, u1} k E (DivisionSemiring.toSemiring.{u2} k (Semifield.toDivisionSemiring.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1)))) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2)) _inst_3))] {a : E} {b : E} {r : k}, (LT.lt.{u2} k (Preorder.toLT.{u2} k (PartialOrder.toPreorder.{u2} k (StrictOrderedRing.toPartialOrder.{u2} k (LinearOrderedRing.toStrictOrderedRing.{u2} k (LinearOrderedCommRing.toLinearOrderedRing.{u2} k (LinearOrderedField.toLinearOrderedCommRing.{u2} k _inst_1)))))) (OfNat.ofNat.{u2} k 0 (Zero.toOfNat0.{u2} k (CommMonoidWithZero.toZero.{u2} k (CommGroupWithZero.toCommMonoidWithZero.{u2} k (Semifield.toCommGroupWithZero.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1))))))) r) -> (Iff (LE.le.{u1} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (Preorder.toLE.{u1} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (PartialOrder.toPreorder.{u1} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (OrderedAddCommGroup.toPartialOrder.{u1} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) _inst_2))) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (AffineMap.{u2, u2, u2, u1, u1} k k k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2)))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) _x) (AffineMap.funLike.{u2, u2, u2, u1, u1} k k k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2)))) (AffineMap.lineMap.{u2, u1, u1} k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2))) a b) r) a) (LE.le.{u1} E (Preorder.toLE.{u1} E (PartialOrder.toPreorder.{u1} E (OrderedAddCommGroup.toPartialOrder.{u1} E _inst_2))) b a))
Case conversion may be inaccurate. Consider using '#align line_map_le_left_iff_le lineMap_le_left_iff_leₓ'. -/
theorem lineMap_le_left_iff_le (h : 0 < r) : lineMap a b r ≤ a ↔ b ≤ a :=
  @left_le_lineMap_iff_le k Eᵒᵈ _ _ _ _ _ _ _ h
#align line_map_le_left_iff_le lineMap_le_left_iff_le

/- warning: midpoint_le_left -> midpoint_le_left is a dubious translation:
lean 3 declaration is
  forall {k : Type.{u1}} {E : Type.{u2}} [_inst_1 : LinearOrderedField.{u1} k] [_inst_2 : OrderedAddCommGroup.{u2} E] [_inst_3 : Module.{u1, u2} k E (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))] [_inst_4 : OrderedSMul.{u1, u2} k E (StrictOrderedSemiring.toOrderedSemiring.{u1} k (StrictOrderedRing.toStrictOrderedSemiring.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k (LinearOrderedCommRing.toLinearOrderedRing.{u1} k (LinearOrderedField.toLinearOrderedCommRing.{u1} k _inst_1))))) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u1, u2} k E (Semiring.toMonoidWithZero.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (AddZeroClass.toHasZero.{u2} E (AddMonoid.toAddZeroClass.{u2} E (AddCommMonoid.toAddMonoid.{u2} E (OrderedAddCommMonoid.toAddCommMonoid.{u2} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)))))) (Module.toMulActionWithZero.{u1, u2} k E (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)) _inst_3))] {a : E} {b : E}, Iff (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) (midpoint.{u1, u2, u2} k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (invertibleTwo.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)) (StrictOrderedSemiring.to_charZero.{u1} k (StrictOrderedRing.toStrictOrderedSemiring.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k (LinearOrderedCommRing.toLinearOrderedRing.{u1} k (LinearOrderedField.toLinearOrderedCommRing.{u1} k _inst_1)))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) a b) a) (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) b a)
but is expected to have type
  forall {k : Type.{u1}} {E : Type.{u2}} [_inst_1 : LinearOrderedField.{u1} k] [_inst_2 : OrderedAddCommGroup.{u2} E] [_inst_3 : Module.{u1, u2} k E (DivisionSemiring.toSemiring.{u1} k (Semifield.toDivisionSemiring.{u1} k (LinearOrderedSemifield.toSemifield.{u1} k (LinearOrderedField.toLinearOrderedSemifield.{u1} k _inst_1)))) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2))] [_inst_4 : OrderedSMul.{u1, u2} k E (OrderedCommSemiring.toOrderedSemiring.{u1} k (StrictOrderedCommSemiring.toOrderedCommSemiring.{u1} k (LinearOrderedCommSemiring.toStrictOrderedCommSemiring.{u1} k (LinearOrderedSemifield.toLinearOrderedCommSemiring.{u1} k (LinearOrderedField.toLinearOrderedSemifield.{u1} k _inst_1))))) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u1, u2} k E (Semiring.toMonoidWithZero.{u1} k (DivisionSemiring.toSemiring.{u1} k (Semifield.toDivisionSemiring.{u1} k (LinearOrderedSemifield.toSemifield.{u1} k (LinearOrderedField.toLinearOrderedSemifield.{u1} k _inst_1))))) (AddMonoid.toZero.{u2} E (AddCommMonoid.toAddMonoid.{u2} E (OrderedAddCommMonoid.toAddCommMonoid.{u2} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2))))) (Module.toMulActionWithZero.{u1, u2} k E (DivisionSemiring.toSemiring.{u1} k (Semifield.toDivisionSemiring.{u1} k (LinearOrderedSemifield.toSemifield.{u1} k (LinearOrderedField.toLinearOrderedSemifield.{u1} k _inst_1)))) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) _inst_3))] {a : E} {b : E}, Iff (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) (midpoint.{u1, u2, u2} k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (invertibleTwo.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)) (StrictOrderedSemiring.to_charZero.{u1} k (LinearOrderedSemiring.toStrictOrderedSemiring.{u1} k (LinearOrderedCommSemiring.toLinearOrderedSemiring.{u1} k (LinearOrderedSemifield.toLinearOrderedCommSemiring.{u1} k (LinearOrderedField.toLinearOrderedSemifield.{u1} k _inst_1)))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) a b) a) (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) b a)
Case conversion may be inaccurate. Consider using '#align midpoint_le_left midpoint_le_leftₓ'. -/
@[simp]
theorem midpoint_le_left : midpoint k a b ≤ a ↔ b ≤ a :=
  lineMap_le_left_iff_le <| inv_pos.2 zero_lt_two
#align midpoint_le_left midpoint_le_left

/- warning: line_map_le_right_iff_le -> lineMap_le_right_iff_le is a dubious translation:
lean 3 declaration is
  forall {k : Type.{u1}} {E : Type.{u2}} [_inst_1 : LinearOrderedField.{u1} k] [_inst_2 : OrderedAddCommGroup.{u2} E] [_inst_3 : Module.{u1, u2} k E (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))] [_inst_4 : OrderedSMul.{u1, u2} k E (StrictOrderedSemiring.toOrderedSemiring.{u1} k (StrictOrderedRing.toStrictOrderedSemiring.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k (LinearOrderedCommRing.toLinearOrderedRing.{u1} k (LinearOrderedField.toLinearOrderedCommRing.{u1} k _inst_1))))) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u1, u2} k E (Semiring.toMonoidWithZero.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (AddZeroClass.toHasZero.{u2} E (AddMonoid.toAddZeroClass.{u2} E (AddCommMonoid.toAddMonoid.{u2} E (OrderedAddCommMonoid.toAddCommMonoid.{u2} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)))))) (Module.toMulActionWithZero.{u1, u2} k E (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)) _inst_3))] {a : E} {b : E} {r : k}, (LT.lt.{u1} k (Preorder.toLT.{u1} k (PartialOrder.toPreorder.{u1} k (OrderedAddCommGroup.toPartialOrder.{u1} k (StrictOrderedRing.toOrderedAddCommGroup.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k (LinearOrderedCommRing.toLinearOrderedRing.{u1} k (LinearOrderedField.toLinearOrderedCommRing.{u1} k _inst_1))))))) r (OfNat.ofNat.{u1} k 1 (OfNat.mk.{u1} k 1 (One.one.{u1} k (AddMonoidWithOne.toOne.{u1} k (AddGroupWithOne.toAddMonoidWithOne.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))))))) -> (Iff (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (AffineMap.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (fun (_x : AffineMap.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) => k -> E) (AffineMap.hasCoeToFun.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (AffineMap.lineMap.{u1, u2, u2} k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) a b) r) b) (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) a b))
but is expected to have type
  forall {k : Type.{u2}} {E : Type.{u1}} [_inst_1 : LinearOrderedField.{u2} k] [_inst_2 : OrderedAddCommGroup.{u1} E] [_inst_3 : Module.{u2, u1} k E (DivisionSemiring.toSemiring.{u2} k (Semifield.toDivisionSemiring.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1)))) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2))] [_inst_4 : OrderedSMul.{u2, u1} k E (OrderedCommSemiring.toOrderedSemiring.{u2} k (StrictOrderedCommSemiring.toOrderedCommSemiring.{u2} k (LinearOrderedCommSemiring.toStrictOrderedCommSemiring.{u2} k (LinearOrderedSemifield.toLinearOrderedCommSemiring.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1))))) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u2, u1} k E (Semiring.toMonoidWithZero.{u2} k (DivisionSemiring.toSemiring.{u2} k (Semifield.toDivisionSemiring.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1))))) (AddMonoid.toZero.{u1} E (AddCommMonoid.toAddMonoid.{u1} E (OrderedAddCommMonoid.toAddCommMonoid.{u1} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2))))) (Module.toMulActionWithZero.{u2, u1} k E (DivisionSemiring.toSemiring.{u2} k (Semifield.toDivisionSemiring.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1)))) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2)) _inst_3))] {a : E} {b : E} {r : k}, (LT.lt.{u2} k (Preorder.toLT.{u2} k (PartialOrder.toPreorder.{u2} k (StrictOrderedRing.toPartialOrder.{u2} k (LinearOrderedRing.toStrictOrderedRing.{u2} k (LinearOrderedCommRing.toLinearOrderedRing.{u2} k (LinearOrderedField.toLinearOrderedCommRing.{u2} k _inst_1)))))) r (OfNat.ofNat.{u2} k 1 (One.toOfNat1.{u2} k (NonAssocRing.toOne.{u2} k (Ring.toNonAssocRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))))) -> (Iff (LE.le.{u1} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (Preorder.toLE.{u1} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (PartialOrder.toPreorder.{u1} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (OrderedAddCommGroup.toPartialOrder.{u1} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) _inst_2))) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (AffineMap.{u2, u2, u2, u1, u1} k k k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2)))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) _x) (AffineMap.funLike.{u2, u2, u2, u1, u1} k k k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2)))) (AffineMap.lineMap.{u2, u1, u1} k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2))) a b) r) b) (LE.le.{u1} E (Preorder.toLE.{u1} E (PartialOrder.toPreorder.{u1} E (OrderedAddCommGroup.toPartialOrder.{u1} E _inst_2))) a b))
Case conversion may be inaccurate. Consider using '#align line_map_le_right_iff_le lineMap_le_right_iff_leₓ'. -/
theorem lineMap_le_right_iff_le (h : r < 1) : lineMap a b r ≤ b ↔ a ≤ b :=
  Iff.trans (by rw [line_map_apply_one]) (lineMap_le_lineMap_iff_of_lt h)
#align line_map_le_right_iff_le lineMap_le_right_iff_le

/- warning: midpoint_le_right -> midpoint_le_right is a dubious translation:
lean 3 declaration is
  forall {k : Type.{u1}} {E : Type.{u2}} [_inst_1 : LinearOrderedField.{u1} k] [_inst_2 : OrderedAddCommGroup.{u2} E] [_inst_3 : Module.{u1, u2} k E (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))] [_inst_4 : OrderedSMul.{u1, u2} k E (StrictOrderedSemiring.toOrderedSemiring.{u1} k (StrictOrderedRing.toStrictOrderedSemiring.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k (LinearOrderedCommRing.toLinearOrderedRing.{u1} k (LinearOrderedField.toLinearOrderedCommRing.{u1} k _inst_1))))) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u1, u2} k E (Semiring.toMonoidWithZero.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (AddZeroClass.toHasZero.{u2} E (AddMonoid.toAddZeroClass.{u2} E (AddCommMonoid.toAddMonoid.{u2} E (OrderedAddCommMonoid.toAddCommMonoid.{u2} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)))))) (Module.toMulActionWithZero.{u1, u2} k E (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)) _inst_3))] {a : E} {b : E}, Iff (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) (midpoint.{u1, u2, u2} k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (invertibleTwo.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)) (StrictOrderedSemiring.to_charZero.{u1} k (StrictOrderedRing.toStrictOrderedSemiring.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k (LinearOrderedCommRing.toLinearOrderedRing.{u1} k (LinearOrderedField.toLinearOrderedCommRing.{u1} k _inst_1)))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) a b) b) (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) a b)
but is expected to have type
  forall {k : Type.{u1}} {E : Type.{u2}} [_inst_1 : LinearOrderedField.{u1} k] [_inst_2 : OrderedAddCommGroup.{u2} E] [_inst_3 : Module.{u1, u2} k E (DivisionSemiring.toSemiring.{u1} k (Semifield.toDivisionSemiring.{u1} k (LinearOrderedSemifield.toSemifield.{u1} k (LinearOrderedField.toLinearOrderedSemifield.{u1} k _inst_1)))) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2))] [_inst_4 : OrderedSMul.{u1, u2} k E (OrderedCommSemiring.toOrderedSemiring.{u1} k (StrictOrderedCommSemiring.toOrderedCommSemiring.{u1} k (LinearOrderedCommSemiring.toStrictOrderedCommSemiring.{u1} k (LinearOrderedSemifield.toLinearOrderedCommSemiring.{u1} k (LinearOrderedField.toLinearOrderedSemifield.{u1} k _inst_1))))) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u1, u2} k E (Semiring.toMonoidWithZero.{u1} k (DivisionSemiring.toSemiring.{u1} k (Semifield.toDivisionSemiring.{u1} k (LinearOrderedSemifield.toSemifield.{u1} k (LinearOrderedField.toLinearOrderedSemifield.{u1} k _inst_1))))) (AddMonoid.toZero.{u2} E (AddCommMonoid.toAddMonoid.{u2} E (OrderedAddCommMonoid.toAddCommMonoid.{u2} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2))))) (Module.toMulActionWithZero.{u1, u2} k E (DivisionSemiring.toSemiring.{u1} k (Semifield.toDivisionSemiring.{u1} k (LinearOrderedSemifield.toSemifield.{u1} k (LinearOrderedField.toLinearOrderedSemifield.{u1} k _inst_1)))) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) _inst_3))] {a : E} {b : E}, Iff (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) (midpoint.{u1, u2, u2} k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (invertibleTwo.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)) (StrictOrderedSemiring.to_charZero.{u1} k (LinearOrderedSemiring.toStrictOrderedSemiring.{u1} k (LinearOrderedCommSemiring.toLinearOrderedSemiring.{u1} k (LinearOrderedSemifield.toLinearOrderedCommSemiring.{u1} k (LinearOrderedField.toLinearOrderedSemifield.{u1} k _inst_1)))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) a b) b) (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) a b)
Case conversion may be inaccurate. Consider using '#align midpoint_le_right midpoint_le_rightₓ'. -/
@[simp]
theorem midpoint_le_right : midpoint k a b ≤ b ↔ a ≤ b :=
  lineMap_le_right_iff_le <| inv_lt_one one_lt_two
#align midpoint_le_right midpoint_le_right

/- warning: right_le_line_map_iff_le -> right_le_lineMap_iff_le is a dubious translation:
lean 3 declaration is
  forall {k : Type.{u1}} {E : Type.{u2}} [_inst_1 : LinearOrderedField.{u1} k] [_inst_2 : OrderedAddCommGroup.{u2} E] [_inst_3 : Module.{u1, u2} k E (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))] [_inst_4 : OrderedSMul.{u1, u2} k E (StrictOrderedSemiring.toOrderedSemiring.{u1} k (StrictOrderedRing.toStrictOrderedSemiring.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k (LinearOrderedCommRing.toLinearOrderedRing.{u1} k (LinearOrderedField.toLinearOrderedCommRing.{u1} k _inst_1))))) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u1, u2} k E (Semiring.toMonoidWithZero.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (AddZeroClass.toHasZero.{u2} E (AddMonoid.toAddZeroClass.{u2} E (AddCommMonoid.toAddMonoid.{u2} E (OrderedAddCommMonoid.toAddCommMonoid.{u2} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)))))) (Module.toMulActionWithZero.{u1, u2} k E (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)) _inst_3))] {a : E} {b : E} {r : k}, (LT.lt.{u1} k (Preorder.toLT.{u1} k (PartialOrder.toPreorder.{u1} k (OrderedAddCommGroup.toPartialOrder.{u1} k (StrictOrderedRing.toOrderedAddCommGroup.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k (LinearOrderedCommRing.toLinearOrderedRing.{u1} k (LinearOrderedField.toLinearOrderedCommRing.{u1} k _inst_1))))))) r (OfNat.ofNat.{u1} k 1 (OfNat.mk.{u1} k 1 (One.one.{u1} k (AddMonoidWithOne.toOne.{u1} k (AddGroupWithOne.toAddMonoidWithOne.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))))))) -> (Iff (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) b (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (AffineMap.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (fun (_x : AffineMap.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) => k -> E) (AffineMap.hasCoeToFun.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (AffineMap.lineMap.{u1, u2, u2} k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) a b) r)) (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) b a))
but is expected to have type
  forall {k : Type.{u2}} {E : Type.{u1}} [_inst_1 : LinearOrderedField.{u2} k] [_inst_2 : OrderedAddCommGroup.{u1} E] [_inst_3 : Module.{u2, u1} k E (DivisionSemiring.toSemiring.{u2} k (Semifield.toDivisionSemiring.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1)))) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2))] [_inst_4 : OrderedSMul.{u2, u1} k E (OrderedCommSemiring.toOrderedSemiring.{u2} k (StrictOrderedCommSemiring.toOrderedCommSemiring.{u2} k (LinearOrderedCommSemiring.toStrictOrderedCommSemiring.{u2} k (LinearOrderedSemifield.toLinearOrderedCommSemiring.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1))))) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u2, u1} k E (Semiring.toMonoidWithZero.{u2} k (DivisionSemiring.toSemiring.{u2} k (Semifield.toDivisionSemiring.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1))))) (AddMonoid.toZero.{u1} E (AddCommMonoid.toAddMonoid.{u1} E (OrderedAddCommMonoid.toAddCommMonoid.{u1} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2))))) (Module.toMulActionWithZero.{u2, u1} k E (DivisionSemiring.toSemiring.{u2} k (Semifield.toDivisionSemiring.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1)))) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2)) _inst_3))] {a : E} {b : E} {r : k}, (LT.lt.{u2} k (Preorder.toLT.{u2} k (PartialOrder.toPreorder.{u2} k (StrictOrderedRing.toPartialOrder.{u2} k (LinearOrderedRing.toStrictOrderedRing.{u2} k (LinearOrderedCommRing.toLinearOrderedRing.{u2} k (LinearOrderedField.toLinearOrderedCommRing.{u2} k _inst_1)))))) r (OfNat.ofNat.{u2} k 1 (One.toOfNat1.{u2} k (NonAssocRing.toOne.{u2} k (Ring.toNonAssocRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))))) -> (Iff (LE.le.{u1} E (Preorder.toLE.{u1} E (PartialOrder.toPreorder.{u1} E (OrderedAddCommGroup.toPartialOrder.{u1} E _inst_2))) b (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (AffineMap.{u2, u2, u2, u1, u1} k k k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2)))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) _x) (AffineMap.funLike.{u2, u2, u2, u1, u1} k k k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2)))) (AffineMap.lineMap.{u2, u1, u1} k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2))) a b) r)) (LE.le.{u1} E (Preorder.toLE.{u1} E (PartialOrder.toPreorder.{u1} E (OrderedAddCommGroup.toPartialOrder.{u1} E _inst_2))) b a))
Case conversion may be inaccurate. Consider using '#align right_le_line_map_iff_le right_le_lineMap_iff_leₓ'. -/
theorem right_le_lineMap_iff_le (h : r < 1) : b ≤ lineMap a b r ↔ b ≤ a :=
  @lineMap_le_right_iff_le k Eᵒᵈ _ _ _ _ _ _ _ h
#align right_le_line_map_iff_le right_le_lineMap_iff_le

/- warning: right_le_midpoint -> right_le_midpoint is a dubious translation:
lean 3 declaration is
  forall {k : Type.{u1}} {E : Type.{u2}} [_inst_1 : LinearOrderedField.{u1} k] [_inst_2 : OrderedAddCommGroup.{u2} E] [_inst_3 : Module.{u1, u2} k E (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))] [_inst_4 : OrderedSMul.{u1, u2} k E (StrictOrderedSemiring.toOrderedSemiring.{u1} k (StrictOrderedRing.toStrictOrderedSemiring.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k (LinearOrderedCommRing.toLinearOrderedRing.{u1} k (LinearOrderedField.toLinearOrderedCommRing.{u1} k _inst_1))))) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u1, u2} k E (Semiring.toMonoidWithZero.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (AddZeroClass.toHasZero.{u2} E (AddMonoid.toAddZeroClass.{u2} E (AddCommMonoid.toAddMonoid.{u2} E (OrderedAddCommMonoid.toAddCommMonoid.{u2} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)))))) (Module.toMulActionWithZero.{u1, u2} k E (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)) _inst_3))] {a : E} {b : E}, Iff (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) b (midpoint.{u1, u2, u2} k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (invertibleTwo.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)) (StrictOrderedSemiring.to_charZero.{u1} k (StrictOrderedRing.toStrictOrderedSemiring.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k (LinearOrderedCommRing.toLinearOrderedRing.{u1} k (LinearOrderedField.toLinearOrderedCommRing.{u1} k _inst_1)))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) a b)) (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) b a)
but is expected to have type
  forall {k : Type.{u1}} {E : Type.{u2}} [_inst_1 : LinearOrderedField.{u1} k] [_inst_2 : OrderedAddCommGroup.{u2} E] [_inst_3 : Module.{u1, u2} k E (DivisionSemiring.toSemiring.{u1} k (Semifield.toDivisionSemiring.{u1} k (LinearOrderedSemifield.toSemifield.{u1} k (LinearOrderedField.toLinearOrderedSemifield.{u1} k _inst_1)))) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2))] [_inst_4 : OrderedSMul.{u1, u2} k E (OrderedCommSemiring.toOrderedSemiring.{u1} k (StrictOrderedCommSemiring.toOrderedCommSemiring.{u1} k (LinearOrderedCommSemiring.toStrictOrderedCommSemiring.{u1} k (LinearOrderedSemifield.toLinearOrderedCommSemiring.{u1} k (LinearOrderedField.toLinearOrderedSemifield.{u1} k _inst_1))))) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u1, u2} k E (Semiring.toMonoidWithZero.{u1} k (DivisionSemiring.toSemiring.{u1} k (Semifield.toDivisionSemiring.{u1} k (LinearOrderedSemifield.toSemifield.{u1} k (LinearOrderedField.toLinearOrderedSemifield.{u1} k _inst_1))))) (AddMonoid.toZero.{u2} E (AddCommMonoid.toAddMonoid.{u2} E (OrderedAddCommMonoid.toAddCommMonoid.{u2} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2))))) (Module.toMulActionWithZero.{u1, u2} k E (DivisionSemiring.toSemiring.{u1} k (Semifield.toDivisionSemiring.{u1} k (LinearOrderedSemifield.toSemifield.{u1} k (LinearOrderedField.toLinearOrderedSemifield.{u1} k _inst_1)))) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) _inst_3))] {a : E} {b : E}, Iff (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) b (midpoint.{u1, u2, u2} k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (invertibleTwo.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)) (StrictOrderedSemiring.to_charZero.{u1} k (LinearOrderedSemiring.toStrictOrderedSemiring.{u1} k (LinearOrderedCommSemiring.toLinearOrderedSemiring.{u1} k (LinearOrderedSemifield.toLinearOrderedCommSemiring.{u1} k (LinearOrderedField.toLinearOrderedSemifield.{u1} k _inst_1)))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) a b)) (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) b a)
Case conversion may be inaccurate. Consider using '#align right_le_midpoint right_le_midpointₓ'. -/
@[simp]
theorem right_le_midpoint : b ≤ midpoint k a b ↔ b ≤ a :=
  right_le_lineMap_iff_le <| inv_lt_one one_lt_two
#align right_le_midpoint right_le_midpoint

end

/-!
### Convexity and slope

Given an interval `[a, b]` and a point `c ∈ (a, b)`, `c = line_map a b r`, there are a few ways to
say that the point `(c, f c)` is above/below the segment `[(a, f a), (b, f b)]`:

* compare `f c` to `line_map (f a) (f b) r`;
* compare `slope f a c` to `slope `f a b`;
* compare `slope f c b` to `slope f a b`;
* compare `slope f a c` to `slope f c b`.

In this section we prove equivalence of these four approaches. In order to make the statements more
readable, we introduce local notation `c = line_map a b r`. Then we prove lemmas like

```
lemma map_le_line_map_iff_slope_le_slope_left (h : 0 < r * (b - a)) :
  f c ≤ line_map (f a) (f b) r ↔ slope f a c ≤ slope f a b :=
```

For each inequality between `f c` and `line_map (f a) (f b) r` we provide 3 lemmas:

* `*_left` relates it to an inequality on `slope f a c` and `slope f a b`;
* `*_right` relates it to an inequality on `slope f a b` and `slope f c b`;
* no-suffix version relates it to an inequality on `slope f a c` and `slope f c b`.

These inequalities can by used in to restate `convex_on` in terms of monotonicity of the slope.
-/

variable {f : k → E} {a b r : k}

-- mathport name: exprc
local notation "c" => lineMap a b r

/- warning: map_le_line_map_iff_slope_le_slope_left -> map_le_lineMap_iff_slope_le_slope_left is a dubious translation:
lean 3 declaration is
  forall {k : Type.{u1}} {E : Type.{u2}} [_inst_1 : LinearOrderedField.{u1} k] [_inst_2 : OrderedAddCommGroup.{u2} E] [_inst_3 : Module.{u1, u2} k E (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))] [_inst_4 : OrderedSMul.{u1, u2} k E (StrictOrderedSemiring.toOrderedSemiring.{u1} k (StrictOrderedRing.toStrictOrderedSemiring.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k (LinearOrderedCommRing.toLinearOrderedRing.{u1} k (LinearOrderedField.toLinearOrderedCommRing.{u1} k _inst_1))))) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u1, u2} k E (Semiring.toMonoidWithZero.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (AddZeroClass.toHasZero.{u2} E (AddMonoid.toAddZeroClass.{u2} E (AddCommMonoid.toAddMonoid.{u2} E (OrderedAddCommMonoid.toAddCommMonoid.{u2} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)))))) (Module.toMulActionWithZero.{u1, u2} k E (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)) _inst_3))] {f : k -> E} {a : k} {b : k} {r : k}, (LT.lt.{u1} k (Preorder.toLT.{u1} k (PartialOrder.toPreorder.{u1} k (OrderedAddCommGroup.toPartialOrder.{u1} k (StrictOrderedRing.toOrderedAddCommGroup.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k (LinearOrderedCommRing.toLinearOrderedRing.{u1} k (LinearOrderedField.toLinearOrderedCommRing.{u1} k _inst_1))))))) (OfNat.ofNat.{u1} k 0 (OfNat.mk.{u1} k 0 (Zero.zero.{u1} k (MulZeroClass.toHasZero.{u1} k (NonUnitalNonAssocSemiring.toMulZeroClass.{u1} k (NonUnitalNonAssocRing.toNonUnitalNonAssocSemiring.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))))))) (HMul.hMul.{u1, u1, u1} k k k (instHMul.{u1} k (Distrib.toHasMul.{u1} k (Ring.toDistrib.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) r (HSub.hSub.{u1, u1, u1} k k k (instHSub.{u1} k (SubNegMonoid.toHasSub.{u1} k (AddGroup.toSubNegMonoid.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))))) b a))) -> (Iff (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) (f (coeFn.{succ u1, succ u1} (AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (fun (_x : AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) => k -> k) (AffineMap.hasCoeToFun.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (AffineMap.lineMap.{u1, u1, u1} k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) a b) r)) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (AffineMap.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (fun (_x : AffineMap.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) => k -> E) (AffineMap.hasCoeToFun.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (AffineMap.lineMap.{u1, u2, u2} k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) (f a) (f b)) r)) (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) (slope.{u1, u2, u2} k E E (LinearOrderedField.toField.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) f a (coeFn.{succ u1, succ u1} (AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (fun (_x : AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) => k -> k) (AffineMap.hasCoeToFun.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (AffineMap.lineMap.{u1, u1, u1} k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) a b) r)) (slope.{u1, u2, u2} k E E (LinearOrderedField.toField.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) f a b)))
but is expected to have type
  forall {k : Type.{u2}} {E : Type.{u1}} [_inst_1 : LinearOrderedField.{u2} k] [_inst_2 : OrderedAddCommGroup.{u1} E] [_inst_3 : Module.{u2, u1} k E (DivisionSemiring.toSemiring.{u2} k (Semifield.toDivisionSemiring.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1)))) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2))] [_inst_4 : OrderedSMul.{u2, u1} k E (OrderedCommSemiring.toOrderedSemiring.{u2} k (StrictOrderedCommSemiring.toOrderedCommSemiring.{u2} k (LinearOrderedCommSemiring.toStrictOrderedCommSemiring.{u2} k (LinearOrderedSemifield.toLinearOrderedCommSemiring.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1))))) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u2, u1} k E (Semiring.toMonoidWithZero.{u2} k (DivisionSemiring.toSemiring.{u2} k (Semifield.toDivisionSemiring.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1))))) (AddMonoid.toZero.{u1} E (AddCommMonoid.toAddMonoid.{u1} E (OrderedAddCommMonoid.toAddCommMonoid.{u1} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2))))) (Module.toMulActionWithZero.{u2, u1} k E (DivisionSemiring.toSemiring.{u2} k (Semifield.toDivisionSemiring.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1)))) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2)) _inst_3))] {f : k -> E} {a : k} {b : k} {r : k}, (LT.lt.{u2} k (Preorder.toLT.{u2} k (PartialOrder.toPreorder.{u2} k (StrictOrderedRing.toPartialOrder.{u2} k (LinearOrderedRing.toStrictOrderedRing.{u2} k (LinearOrderedCommRing.toLinearOrderedRing.{u2} k (LinearOrderedField.toLinearOrderedCommRing.{u2} k _inst_1)))))) (OfNat.ofNat.{u2} k 0 (Zero.toOfNat0.{u2} k (CommMonoidWithZero.toZero.{u2} k (CommGroupWithZero.toCommMonoidWithZero.{u2} k (Semifield.toCommGroupWithZero.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1))))))) (HMul.hMul.{u2, u2, u2} k k k (instHMul.{u2} k (NonUnitalNonAssocRing.toMul.{u2} k (NonAssocRing.toNonUnitalNonAssocRing.{u2} k (Ring.toNonAssocRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) r (HSub.hSub.{u2, u2, u2} k k k (instHSub.{u2} k (Ring.toSub.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))) b a))) -> (Iff (LE.le.{u1} E (Preorder.toLE.{u1} E (PartialOrder.toPreorder.{u1} E (OrderedAddCommGroup.toPartialOrder.{u1} E _inst_2))) (f (FunLike.coe.{succ u2, succ u2, succ u2} (AffineMap.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => k) _x) (AffineMap.funLike.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) (AffineMap.lineMap.{u2, u2, u2} k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) a b) r)) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (AffineMap.{u2, u2, u2, u1, u1} k k k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2)))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) _x) (AffineMap.funLike.{u2, u2, u2, u1, u1} k k k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2)))) (AffineMap.lineMap.{u2, u1, u1} k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2))) (f a) (f b)) r)) (LE.le.{u1} E (Preorder.toLE.{u1} E (PartialOrder.toPreorder.{u1} E (OrderedAddCommGroup.toPartialOrder.{u1} E _inst_2))) (slope.{u2, u1, u1} k E E (LinearOrderedField.toField.{u2} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2))) f a (FunLike.coe.{succ u2, succ u2, succ u2} (AffineMap.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => k) _x) (AffineMap.funLike.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) (AffineMap.lineMap.{u2, u2, u2} k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) a b) r)) (slope.{u2, u1, u1} k E E (LinearOrderedField.toField.{u2} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2))) f a b)))
Case conversion may be inaccurate. Consider using '#align map_le_line_map_iff_slope_le_slope_left map_le_lineMap_iff_slope_le_slope_leftₓ'. -/
/-- Given `c = line_map a b r`, `a < c`, the point `(c, f c)` is non-strictly below the
segment `[(a, f a), (b, f b)]` if and only if `slope f a c ≤ slope f a b`. -/
theorem map_le_lineMap_iff_slope_le_slope_left (h : 0 < r * (b - a)) :
    f c ≤ lineMap (f a) (f b) r ↔ slope f a c ≤ slope f a b :=
  by
  rw [line_map_apply, line_map_apply, slope, slope, vsub_eq_sub, vsub_eq_sub, vsub_eq_sub,
    vadd_eq_add, vadd_eq_add, smul_eq_mul, add_sub_cancel, smul_sub, smul_sub, smul_sub,
    sub_le_iff_le_add, mul_inv_rev, mul_smul, mul_smul, ← smul_sub, ← smul_sub, ← smul_add,
    smul_smul, ← mul_inv_rev, inv_smul_le_iff h, smul_smul,
    mul_inv_cancel_right₀ (right_ne_zero_of_mul h.ne'), smul_add,
    smul_inv_smul₀ (left_ne_zero_of_mul h.ne')]
  infer_instance
#align map_le_line_map_iff_slope_le_slope_left map_le_lineMap_iff_slope_le_slope_left

/- warning: line_map_le_map_iff_slope_le_slope_left -> lineMap_le_map_iff_slope_le_slope_left is a dubious translation:
lean 3 declaration is
  forall {k : Type.{u1}} {E : Type.{u2}} [_inst_1 : LinearOrderedField.{u1} k] [_inst_2 : OrderedAddCommGroup.{u2} E] [_inst_3 : Module.{u1, u2} k E (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))] [_inst_4 : OrderedSMul.{u1, u2} k E (StrictOrderedSemiring.toOrderedSemiring.{u1} k (StrictOrderedRing.toStrictOrderedSemiring.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k (LinearOrderedCommRing.toLinearOrderedRing.{u1} k (LinearOrderedField.toLinearOrderedCommRing.{u1} k _inst_1))))) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u1, u2} k E (Semiring.toMonoidWithZero.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (AddZeroClass.toHasZero.{u2} E (AddMonoid.toAddZeroClass.{u2} E (AddCommMonoid.toAddMonoid.{u2} E (OrderedAddCommMonoid.toAddCommMonoid.{u2} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)))))) (Module.toMulActionWithZero.{u1, u2} k E (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)) _inst_3))] {f : k -> E} {a : k} {b : k} {r : k}, (LT.lt.{u1} k (Preorder.toLT.{u1} k (PartialOrder.toPreorder.{u1} k (OrderedAddCommGroup.toPartialOrder.{u1} k (StrictOrderedRing.toOrderedAddCommGroup.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k (LinearOrderedCommRing.toLinearOrderedRing.{u1} k (LinearOrderedField.toLinearOrderedCommRing.{u1} k _inst_1))))))) (OfNat.ofNat.{u1} k 0 (OfNat.mk.{u1} k 0 (Zero.zero.{u1} k (MulZeroClass.toHasZero.{u1} k (NonUnitalNonAssocSemiring.toMulZeroClass.{u1} k (NonUnitalNonAssocRing.toNonUnitalNonAssocSemiring.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))))))) (HMul.hMul.{u1, u1, u1} k k k (instHMul.{u1} k (Distrib.toHasMul.{u1} k (Ring.toDistrib.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) r (HSub.hSub.{u1, u1, u1} k k k (instHSub.{u1} k (SubNegMonoid.toHasSub.{u1} k (AddGroup.toSubNegMonoid.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))))) b a))) -> (Iff (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (AffineMap.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (fun (_x : AffineMap.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) => k -> E) (AffineMap.hasCoeToFun.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (AffineMap.lineMap.{u1, u2, u2} k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) (f a) (f b)) r) (f (coeFn.{succ u1, succ u1} (AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (fun (_x : AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) => k -> k) (AffineMap.hasCoeToFun.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (AffineMap.lineMap.{u1, u1, u1} k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) a b) r))) (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) (slope.{u1, u2, u2} k E E (LinearOrderedField.toField.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) f a b) (slope.{u1, u2, u2} k E E (LinearOrderedField.toField.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) f a (coeFn.{succ u1, succ u1} (AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (fun (_x : AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) => k -> k) (AffineMap.hasCoeToFun.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (AffineMap.lineMap.{u1, u1, u1} k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) a b) r))))
but is expected to have type
  forall {k : Type.{u2}} {E : Type.{u1}} [_inst_1 : LinearOrderedField.{u2} k] [_inst_2 : OrderedAddCommGroup.{u1} E] [_inst_3 : Module.{u2, u1} k E (DivisionSemiring.toSemiring.{u2} k (Semifield.toDivisionSemiring.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1)))) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2))] [_inst_4 : OrderedSMul.{u2, u1} k E (OrderedCommSemiring.toOrderedSemiring.{u2} k (StrictOrderedCommSemiring.toOrderedCommSemiring.{u2} k (LinearOrderedCommSemiring.toStrictOrderedCommSemiring.{u2} k (LinearOrderedSemifield.toLinearOrderedCommSemiring.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1))))) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u2, u1} k E (Semiring.toMonoidWithZero.{u2} k (DivisionSemiring.toSemiring.{u2} k (Semifield.toDivisionSemiring.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1))))) (AddMonoid.toZero.{u1} E (AddCommMonoid.toAddMonoid.{u1} E (OrderedAddCommMonoid.toAddCommMonoid.{u1} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2))))) (Module.toMulActionWithZero.{u2, u1} k E (DivisionSemiring.toSemiring.{u2} k (Semifield.toDivisionSemiring.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1)))) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2)) _inst_3))] {f : k -> E} {a : k} {b : k} {r : k}, (LT.lt.{u2} k (Preorder.toLT.{u2} k (PartialOrder.toPreorder.{u2} k (StrictOrderedRing.toPartialOrder.{u2} k (LinearOrderedRing.toStrictOrderedRing.{u2} k (LinearOrderedCommRing.toLinearOrderedRing.{u2} k (LinearOrderedField.toLinearOrderedCommRing.{u2} k _inst_1)))))) (OfNat.ofNat.{u2} k 0 (Zero.toOfNat0.{u2} k (CommMonoidWithZero.toZero.{u2} k (CommGroupWithZero.toCommMonoidWithZero.{u2} k (Semifield.toCommGroupWithZero.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1))))))) (HMul.hMul.{u2, u2, u2} k k k (instHMul.{u2} k (NonUnitalNonAssocRing.toMul.{u2} k (NonAssocRing.toNonUnitalNonAssocRing.{u2} k (Ring.toNonAssocRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) r (HSub.hSub.{u2, u2, u2} k k k (instHSub.{u2} k (Ring.toSub.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))) b a))) -> (Iff (LE.le.{u1} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (Preorder.toLE.{u1} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (PartialOrder.toPreorder.{u1} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (OrderedAddCommGroup.toPartialOrder.{u1} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) _inst_2))) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (AffineMap.{u2, u2, u2, u1, u1} k k k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2)))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) _x) (AffineMap.funLike.{u2, u2, u2, u1, u1} k k k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2)))) (AffineMap.lineMap.{u2, u1, u1} k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2))) (f a) (f b)) r) (f (FunLike.coe.{succ u2, succ u2, succ u2} (AffineMap.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => k) _x) (AffineMap.funLike.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) (AffineMap.lineMap.{u2, u2, u2} k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) a b) r))) (LE.le.{u1} E (Preorder.toLE.{u1} E (PartialOrder.toPreorder.{u1} E (OrderedAddCommGroup.toPartialOrder.{u1} E _inst_2))) (slope.{u2, u1, u1} k E E (LinearOrderedField.toField.{u2} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2))) f a b) (slope.{u2, u1, u1} k E E (LinearOrderedField.toField.{u2} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2))) f a (FunLike.coe.{succ u2, succ u2, succ u2} (AffineMap.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => k) _x) (AffineMap.funLike.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) (AffineMap.lineMap.{u2, u2, u2} k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) a b) r))))
Case conversion may be inaccurate. Consider using '#align line_map_le_map_iff_slope_le_slope_left lineMap_le_map_iff_slope_le_slope_leftₓ'. -/
/-- Given `c = line_map a b r`, `a < c`, the point `(c, f c)` is non-strictly above the
segment `[(a, f a), (b, f b)]` if and only if `slope f a b ≤ slope f a c`. -/
theorem lineMap_le_map_iff_slope_le_slope_left (h : 0 < r * (b - a)) :
    lineMap (f a) (f b) r ≤ f c ↔ slope f a b ≤ slope f a c :=
  @map_le_lineMap_iff_slope_le_slope_left k Eᵒᵈ _ _ _ _ f a b r h
#align line_map_le_map_iff_slope_le_slope_left lineMap_le_map_iff_slope_le_slope_left

/- warning: map_lt_line_map_iff_slope_lt_slope_left -> map_lt_lineMap_iff_slope_lt_slope_left is a dubious translation:
lean 3 declaration is
  forall {k : Type.{u1}} {E : Type.{u2}} [_inst_1 : LinearOrderedField.{u1} k] [_inst_2 : OrderedAddCommGroup.{u2} E] [_inst_3 : Module.{u1, u2} k E (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))] [_inst_4 : OrderedSMul.{u1, u2} k E (StrictOrderedSemiring.toOrderedSemiring.{u1} k (StrictOrderedRing.toStrictOrderedSemiring.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k (LinearOrderedCommRing.toLinearOrderedRing.{u1} k (LinearOrderedField.toLinearOrderedCommRing.{u1} k _inst_1))))) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u1, u2} k E (Semiring.toMonoidWithZero.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (AddZeroClass.toHasZero.{u2} E (AddMonoid.toAddZeroClass.{u2} E (AddCommMonoid.toAddMonoid.{u2} E (OrderedAddCommMonoid.toAddCommMonoid.{u2} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)))))) (Module.toMulActionWithZero.{u1, u2} k E (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)) _inst_3))] {f : k -> E} {a : k} {b : k} {r : k}, (LT.lt.{u1} k (Preorder.toLT.{u1} k (PartialOrder.toPreorder.{u1} k (OrderedAddCommGroup.toPartialOrder.{u1} k (StrictOrderedRing.toOrderedAddCommGroup.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k (LinearOrderedCommRing.toLinearOrderedRing.{u1} k (LinearOrderedField.toLinearOrderedCommRing.{u1} k _inst_1))))))) (OfNat.ofNat.{u1} k 0 (OfNat.mk.{u1} k 0 (Zero.zero.{u1} k (MulZeroClass.toHasZero.{u1} k (NonUnitalNonAssocSemiring.toMulZeroClass.{u1} k (NonUnitalNonAssocRing.toNonUnitalNonAssocSemiring.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))))))) (HMul.hMul.{u1, u1, u1} k k k (instHMul.{u1} k (Distrib.toHasMul.{u1} k (Ring.toDistrib.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) r (HSub.hSub.{u1, u1, u1} k k k (instHSub.{u1} k (SubNegMonoid.toHasSub.{u1} k (AddGroup.toSubNegMonoid.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))))) b a))) -> (Iff (LT.lt.{u2} E (Preorder.toLT.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) (f (coeFn.{succ u1, succ u1} (AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (fun (_x : AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) => k -> k) (AffineMap.hasCoeToFun.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (AffineMap.lineMap.{u1, u1, u1} k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) a b) r)) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (AffineMap.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (fun (_x : AffineMap.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) => k -> E) (AffineMap.hasCoeToFun.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (AffineMap.lineMap.{u1, u2, u2} k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) (f a) (f b)) r)) (LT.lt.{u2} E (Preorder.toLT.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) (slope.{u1, u2, u2} k E E (LinearOrderedField.toField.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) f a (coeFn.{succ u1, succ u1} (AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (fun (_x : AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) => k -> k) (AffineMap.hasCoeToFun.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (AffineMap.lineMap.{u1, u1, u1} k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) a b) r)) (slope.{u1, u2, u2} k E E (LinearOrderedField.toField.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) f a b)))
but is expected to have type
  forall {k : Type.{u2}} {E : Type.{u1}} [_inst_1 : LinearOrderedField.{u2} k] [_inst_2 : OrderedAddCommGroup.{u1} E] [_inst_3 : Module.{u2, u1} k E (DivisionSemiring.toSemiring.{u2} k (Semifield.toDivisionSemiring.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1)))) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2))] [_inst_4 : OrderedSMul.{u2, u1} k E (OrderedCommSemiring.toOrderedSemiring.{u2} k (StrictOrderedCommSemiring.toOrderedCommSemiring.{u2} k (LinearOrderedCommSemiring.toStrictOrderedCommSemiring.{u2} k (LinearOrderedSemifield.toLinearOrderedCommSemiring.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1))))) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u2, u1} k E (Semiring.toMonoidWithZero.{u2} k (DivisionSemiring.toSemiring.{u2} k (Semifield.toDivisionSemiring.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1))))) (AddMonoid.toZero.{u1} E (AddCommMonoid.toAddMonoid.{u1} E (OrderedAddCommMonoid.toAddCommMonoid.{u1} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2))))) (Module.toMulActionWithZero.{u2, u1} k E (DivisionSemiring.toSemiring.{u2} k (Semifield.toDivisionSemiring.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1)))) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2)) _inst_3))] {f : k -> E} {a : k} {b : k} {r : k}, (LT.lt.{u2} k (Preorder.toLT.{u2} k (PartialOrder.toPreorder.{u2} k (StrictOrderedRing.toPartialOrder.{u2} k (LinearOrderedRing.toStrictOrderedRing.{u2} k (LinearOrderedCommRing.toLinearOrderedRing.{u2} k (LinearOrderedField.toLinearOrderedCommRing.{u2} k _inst_1)))))) (OfNat.ofNat.{u2} k 0 (Zero.toOfNat0.{u2} k (CommMonoidWithZero.toZero.{u2} k (CommGroupWithZero.toCommMonoidWithZero.{u2} k (Semifield.toCommGroupWithZero.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1))))))) (HMul.hMul.{u2, u2, u2} k k k (instHMul.{u2} k (NonUnitalNonAssocRing.toMul.{u2} k (NonAssocRing.toNonUnitalNonAssocRing.{u2} k (Ring.toNonAssocRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) r (HSub.hSub.{u2, u2, u2} k k k (instHSub.{u2} k (Ring.toSub.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))) b a))) -> (Iff (LT.lt.{u1} E (Preorder.toLT.{u1} E (PartialOrder.toPreorder.{u1} E (OrderedAddCommGroup.toPartialOrder.{u1} E _inst_2))) (f (FunLike.coe.{succ u2, succ u2, succ u2} (AffineMap.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => k) _x) (AffineMap.funLike.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) (AffineMap.lineMap.{u2, u2, u2} k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) a b) r)) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (AffineMap.{u2, u2, u2, u1, u1} k k k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2)))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) _x) (AffineMap.funLike.{u2, u2, u2, u1, u1} k k k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2)))) (AffineMap.lineMap.{u2, u1, u1} k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2))) (f a) (f b)) r)) (LT.lt.{u1} E (Preorder.toLT.{u1} E (PartialOrder.toPreorder.{u1} E (OrderedAddCommGroup.toPartialOrder.{u1} E _inst_2))) (slope.{u2, u1, u1} k E E (LinearOrderedField.toField.{u2} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2))) f a (FunLike.coe.{succ u2, succ u2, succ u2} (AffineMap.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => k) _x) (AffineMap.funLike.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) (AffineMap.lineMap.{u2, u2, u2} k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) a b) r)) (slope.{u2, u1, u1} k E E (LinearOrderedField.toField.{u2} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2))) f a b)))
Case conversion may be inaccurate. Consider using '#align map_lt_line_map_iff_slope_lt_slope_left map_lt_lineMap_iff_slope_lt_slope_leftₓ'. -/
/-- Given `c = line_map a b r`, `a < c`, the point `(c, f c)` is strictly below the
segment `[(a, f a), (b, f b)]` if and only if `slope f a c < slope f a b`. -/
theorem map_lt_lineMap_iff_slope_lt_slope_left (h : 0 < r * (b - a)) :
    f c < lineMap (f a) (f b) r ↔ slope f a c < slope f a b :=
  lt_iff_lt_of_le_iff_le' (lineMap_le_map_iff_slope_le_slope_left h)
    (map_le_lineMap_iff_slope_le_slope_left h)
#align map_lt_line_map_iff_slope_lt_slope_left map_lt_lineMap_iff_slope_lt_slope_left

/- warning: line_map_lt_map_iff_slope_lt_slope_left -> lineMap_lt_map_iff_slope_lt_slope_left is a dubious translation:
lean 3 declaration is
  forall {k : Type.{u1}} {E : Type.{u2}} [_inst_1 : LinearOrderedField.{u1} k] [_inst_2 : OrderedAddCommGroup.{u2} E] [_inst_3 : Module.{u1, u2} k E (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))] [_inst_4 : OrderedSMul.{u1, u2} k E (StrictOrderedSemiring.toOrderedSemiring.{u1} k (StrictOrderedRing.toStrictOrderedSemiring.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k (LinearOrderedCommRing.toLinearOrderedRing.{u1} k (LinearOrderedField.toLinearOrderedCommRing.{u1} k _inst_1))))) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u1, u2} k E (Semiring.toMonoidWithZero.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (AddZeroClass.toHasZero.{u2} E (AddMonoid.toAddZeroClass.{u2} E (AddCommMonoid.toAddMonoid.{u2} E (OrderedAddCommMonoid.toAddCommMonoid.{u2} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)))))) (Module.toMulActionWithZero.{u1, u2} k E (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)) _inst_3))] {f : k -> E} {a : k} {b : k} {r : k}, (LT.lt.{u1} k (Preorder.toLT.{u1} k (PartialOrder.toPreorder.{u1} k (OrderedAddCommGroup.toPartialOrder.{u1} k (StrictOrderedRing.toOrderedAddCommGroup.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k (LinearOrderedCommRing.toLinearOrderedRing.{u1} k (LinearOrderedField.toLinearOrderedCommRing.{u1} k _inst_1))))))) (OfNat.ofNat.{u1} k 0 (OfNat.mk.{u1} k 0 (Zero.zero.{u1} k (MulZeroClass.toHasZero.{u1} k (NonUnitalNonAssocSemiring.toMulZeroClass.{u1} k (NonUnitalNonAssocRing.toNonUnitalNonAssocSemiring.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))))))) (HMul.hMul.{u1, u1, u1} k k k (instHMul.{u1} k (Distrib.toHasMul.{u1} k (Ring.toDistrib.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) r (HSub.hSub.{u1, u1, u1} k k k (instHSub.{u1} k (SubNegMonoid.toHasSub.{u1} k (AddGroup.toSubNegMonoid.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))))) b a))) -> (Iff (LT.lt.{u2} E (Preorder.toLT.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (AffineMap.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (fun (_x : AffineMap.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) => k -> E) (AffineMap.hasCoeToFun.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (AffineMap.lineMap.{u1, u2, u2} k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) (f a) (f b)) r) (f (coeFn.{succ u1, succ u1} (AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (fun (_x : AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) => k -> k) (AffineMap.hasCoeToFun.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (AffineMap.lineMap.{u1, u1, u1} k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) a b) r))) (LT.lt.{u2} E (Preorder.toLT.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) (slope.{u1, u2, u2} k E E (LinearOrderedField.toField.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) f a b) (slope.{u1, u2, u2} k E E (LinearOrderedField.toField.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) f a (coeFn.{succ u1, succ u1} (AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (fun (_x : AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) => k -> k) (AffineMap.hasCoeToFun.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (AffineMap.lineMap.{u1, u1, u1} k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) a b) r))))
but is expected to have type
  forall {k : Type.{u2}} {E : Type.{u1}} [_inst_1 : LinearOrderedField.{u2} k] [_inst_2 : OrderedAddCommGroup.{u1} E] [_inst_3 : Module.{u2, u1} k E (DivisionSemiring.toSemiring.{u2} k (Semifield.toDivisionSemiring.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1)))) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2))] [_inst_4 : OrderedSMul.{u2, u1} k E (OrderedCommSemiring.toOrderedSemiring.{u2} k (StrictOrderedCommSemiring.toOrderedCommSemiring.{u2} k (LinearOrderedCommSemiring.toStrictOrderedCommSemiring.{u2} k (LinearOrderedSemifield.toLinearOrderedCommSemiring.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1))))) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u2, u1} k E (Semiring.toMonoidWithZero.{u2} k (DivisionSemiring.toSemiring.{u2} k (Semifield.toDivisionSemiring.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1))))) (AddMonoid.toZero.{u1} E (AddCommMonoid.toAddMonoid.{u1} E (OrderedAddCommMonoid.toAddCommMonoid.{u1} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2))))) (Module.toMulActionWithZero.{u2, u1} k E (DivisionSemiring.toSemiring.{u2} k (Semifield.toDivisionSemiring.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1)))) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2)) _inst_3))] {f : k -> E} {a : k} {b : k} {r : k}, (LT.lt.{u2} k (Preorder.toLT.{u2} k (PartialOrder.toPreorder.{u2} k (StrictOrderedRing.toPartialOrder.{u2} k (LinearOrderedRing.toStrictOrderedRing.{u2} k (LinearOrderedCommRing.toLinearOrderedRing.{u2} k (LinearOrderedField.toLinearOrderedCommRing.{u2} k _inst_1)))))) (OfNat.ofNat.{u2} k 0 (Zero.toOfNat0.{u2} k (CommMonoidWithZero.toZero.{u2} k (CommGroupWithZero.toCommMonoidWithZero.{u2} k (Semifield.toCommGroupWithZero.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1))))))) (HMul.hMul.{u2, u2, u2} k k k (instHMul.{u2} k (NonUnitalNonAssocRing.toMul.{u2} k (NonAssocRing.toNonUnitalNonAssocRing.{u2} k (Ring.toNonAssocRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) r (HSub.hSub.{u2, u2, u2} k k k (instHSub.{u2} k (Ring.toSub.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))) b a))) -> (Iff (LT.lt.{u1} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (Preorder.toLT.{u1} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (PartialOrder.toPreorder.{u1} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (OrderedAddCommGroup.toPartialOrder.{u1} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) _inst_2))) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (AffineMap.{u2, u2, u2, u1, u1} k k k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2)))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) _x) (AffineMap.funLike.{u2, u2, u2, u1, u1} k k k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2)))) (AffineMap.lineMap.{u2, u1, u1} k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2))) (f a) (f b)) r) (f (FunLike.coe.{succ u2, succ u2, succ u2} (AffineMap.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => k) _x) (AffineMap.funLike.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) (AffineMap.lineMap.{u2, u2, u2} k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) a b) r))) (LT.lt.{u1} E (Preorder.toLT.{u1} E (PartialOrder.toPreorder.{u1} E (OrderedAddCommGroup.toPartialOrder.{u1} E _inst_2))) (slope.{u2, u1, u1} k E E (LinearOrderedField.toField.{u2} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2))) f a b) (slope.{u2, u1, u1} k E E (LinearOrderedField.toField.{u2} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2))) f a (FunLike.coe.{succ u2, succ u2, succ u2} (AffineMap.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => k) _x) (AffineMap.funLike.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) (AffineMap.lineMap.{u2, u2, u2} k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) a b) r))))
Case conversion may be inaccurate. Consider using '#align line_map_lt_map_iff_slope_lt_slope_left lineMap_lt_map_iff_slope_lt_slope_leftₓ'. -/
/-- Given `c = line_map a b r`, `a < c`, the point `(c, f c)` is strictly above the
segment `[(a, f a), (b, f b)]` if and only if `slope f a b < slope f a c`. -/
theorem lineMap_lt_map_iff_slope_lt_slope_left (h : 0 < r * (b - a)) :
    lineMap (f a) (f b) r < f c ↔ slope f a b < slope f a c :=
  @map_lt_lineMap_iff_slope_lt_slope_left k Eᵒᵈ _ _ _ _ f a b r h
#align line_map_lt_map_iff_slope_lt_slope_left lineMap_lt_map_iff_slope_lt_slope_left

/- warning: map_le_line_map_iff_slope_le_slope_right -> map_le_lineMap_iff_slope_le_slope_right is a dubious translation:
lean 3 declaration is
  forall {k : Type.{u1}} {E : Type.{u2}} [_inst_1 : LinearOrderedField.{u1} k] [_inst_2 : OrderedAddCommGroup.{u2} E] [_inst_3 : Module.{u1, u2} k E (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))] [_inst_4 : OrderedSMul.{u1, u2} k E (StrictOrderedSemiring.toOrderedSemiring.{u1} k (StrictOrderedRing.toStrictOrderedSemiring.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k (LinearOrderedCommRing.toLinearOrderedRing.{u1} k (LinearOrderedField.toLinearOrderedCommRing.{u1} k _inst_1))))) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u1, u2} k E (Semiring.toMonoidWithZero.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (AddZeroClass.toHasZero.{u2} E (AddMonoid.toAddZeroClass.{u2} E (AddCommMonoid.toAddMonoid.{u2} E (OrderedAddCommMonoid.toAddCommMonoid.{u2} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)))))) (Module.toMulActionWithZero.{u1, u2} k E (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)) _inst_3))] {f : k -> E} {a : k} {b : k} {r : k}, (LT.lt.{u1} k (Preorder.toLT.{u1} k (PartialOrder.toPreorder.{u1} k (OrderedAddCommGroup.toPartialOrder.{u1} k (StrictOrderedRing.toOrderedAddCommGroup.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k (LinearOrderedCommRing.toLinearOrderedRing.{u1} k (LinearOrderedField.toLinearOrderedCommRing.{u1} k _inst_1))))))) (OfNat.ofNat.{u1} k 0 (OfNat.mk.{u1} k 0 (Zero.zero.{u1} k (MulZeroClass.toHasZero.{u1} k (NonUnitalNonAssocSemiring.toMulZeroClass.{u1} k (NonUnitalNonAssocRing.toNonUnitalNonAssocSemiring.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))))))) (HMul.hMul.{u1, u1, u1} k k k (instHMul.{u1} k (Distrib.toHasMul.{u1} k (Ring.toDistrib.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (HSub.hSub.{u1, u1, u1} k k k (instHSub.{u1} k (SubNegMonoid.toHasSub.{u1} k (AddGroup.toSubNegMonoid.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))))) (OfNat.ofNat.{u1} k 1 (OfNat.mk.{u1} k 1 (One.one.{u1} k (AddMonoidWithOne.toOne.{u1} k (AddGroupWithOne.toAddMonoidWithOne.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))))) r) (HSub.hSub.{u1, u1, u1} k k k (instHSub.{u1} k (SubNegMonoid.toHasSub.{u1} k (AddGroup.toSubNegMonoid.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))))) b a))) -> (Iff (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) (f (coeFn.{succ u1, succ u1} (AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (fun (_x : AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) => k -> k) (AffineMap.hasCoeToFun.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (AffineMap.lineMap.{u1, u1, u1} k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) a b) r)) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (AffineMap.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (fun (_x : AffineMap.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) => k -> E) (AffineMap.hasCoeToFun.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (AffineMap.lineMap.{u1, u2, u2} k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) (f a) (f b)) r)) (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) (slope.{u1, u2, u2} k E E (LinearOrderedField.toField.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) f a b) (slope.{u1, u2, u2} k E E (LinearOrderedField.toField.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) f (coeFn.{succ u1, succ u1} (AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (fun (_x : AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) => k -> k) (AffineMap.hasCoeToFun.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (AffineMap.lineMap.{u1, u1, u1} k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) a b) r) b)))
but is expected to have type
  forall {k : Type.{u2}} {E : Type.{u1}} [_inst_1 : LinearOrderedField.{u2} k] [_inst_2 : OrderedAddCommGroup.{u1} E] [_inst_3 : Module.{u2, u1} k E (DivisionSemiring.toSemiring.{u2} k (Semifield.toDivisionSemiring.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1)))) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2))] [_inst_4 : OrderedSMul.{u2, u1} k E (OrderedCommSemiring.toOrderedSemiring.{u2} k (StrictOrderedCommSemiring.toOrderedCommSemiring.{u2} k (LinearOrderedCommSemiring.toStrictOrderedCommSemiring.{u2} k (LinearOrderedSemifield.toLinearOrderedCommSemiring.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1))))) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u2, u1} k E (Semiring.toMonoidWithZero.{u2} k (DivisionSemiring.toSemiring.{u2} k (Semifield.toDivisionSemiring.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1))))) (AddMonoid.toZero.{u1} E (AddCommMonoid.toAddMonoid.{u1} E (OrderedAddCommMonoid.toAddCommMonoid.{u1} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2))))) (Module.toMulActionWithZero.{u2, u1} k E (DivisionSemiring.toSemiring.{u2} k (Semifield.toDivisionSemiring.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1)))) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2)) _inst_3))] {f : k -> E} {a : k} {b : k} {r : k}, (LT.lt.{u2} k (Preorder.toLT.{u2} k (PartialOrder.toPreorder.{u2} k (StrictOrderedRing.toPartialOrder.{u2} k (LinearOrderedRing.toStrictOrderedRing.{u2} k (LinearOrderedCommRing.toLinearOrderedRing.{u2} k (LinearOrderedField.toLinearOrderedCommRing.{u2} k _inst_1)))))) (OfNat.ofNat.{u2} k 0 (Zero.toOfNat0.{u2} k (CommMonoidWithZero.toZero.{u2} k (CommGroupWithZero.toCommMonoidWithZero.{u2} k (Semifield.toCommGroupWithZero.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1))))))) (HMul.hMul.{u2, u2, u2} k k k (instHMul.{u2} k (NonUnitalNonAssocRing.toMul.{u2} k (NonAssocRing.toNonUnitalNonAssocRing.{u2} k (Ring.toNonAssocRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) (HSub.hSub.{u2, u2, u2} k k k (instHSub.{u2} k (Ring.toSub.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))) (OfNat.ofNat.{u2} k 1 (One.toOfNat1.{u2} k (NonAssocRing.toOne.{u2} k (Ring.toNonAssocRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) r) (HSub.hSub.{u2, u2, u2} k k k (instHSub.{u2} k (Ring.toSub.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))) b a))) -> (Iff (LE.le.{u1} E (Preorder.toLE.{u1} E (PartialOrder.toPreorder.{u1} E (OrderedAddCommGroup.toPartialOrder.{u1} E _inst_2))) (f (FunLike.coe.{succ u2, succ u2, succ u2} (AffineMap.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => k) _x) (AffineMap.funLike.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) (AffineMap.lineMap.{u2, u2, u2} k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) a b) r)) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (AffineMap.{u2, u2, u2, u1, u1} k k k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2)))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) _x) (AffineMap.funLike.{u2, u2, u2, u1, u1} k k k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2)))) (AffineMap.lineMap.{u2, u1, u1} k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2))) (f a) (f b)) r)) (LE.le.{u1} E (Preorder.toLE.{u1} E (PartialOrder.toPreorder.{u1} E (OrderedAddCommGroup.toPartialOrder.{u1} E _inst_2))) (slope.{u2, u1, u1} k E E (LinearOrderedField.toField.{u2} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2))) f a b) (slope.{u2, u1, u1} k E E (LinearOrderedField.toField.{u2} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2))) f (FunLike.coe.{succ u2, succ u2, succ u2} (AffineMap.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => k) _x) (AffineMap.funLike.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) (AffineMap.lineMap.{u2, u2, u2} k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) a b) r) b)))
Case conversion may be inaccurate. Consider using '#align map_le_line_map_iff_slope_le_slope_right map_le_lineMap_iff_slope_le_slope_rightₓ'. -/
/-- Given `c = line_map a b r`, `c < b`, the point `(c, f c)` is non-strictly below the
segment `[(a, f a), (b, f b)]` if and only if `slope f a b ≤ slope f c b`. -/
theorem map_le_lineMap_iff_slope_le_slope_right (h : 0 < (1 - r) * (b - a)) :
    f c ≤ lineMap (f a) (f b) r ↔ slope f a b ≤ slope f c b :=
  by
  rw [← line_map_apply_one_sub, ← line_map_apply_one_sub _ _ r]
  revert h; generalize 1 - r = r'; clear r; intro h
  simp_rw [line_map_apply, slope, vsub_eq_sub, vadd_eq_add, smul_eq_mul]
  rw [sub_add_eq_sub_sub_swap, sub_self, zero_sub, neg_mul_eq_mul_neg, neg_sub, le_inv_smul_iff h,
    smul_smul, mul_inv_cancel_right₀, le_sub_comm, ← neg_sub (f b), smul_neg, neg_add_eq_sub]
  · exact right_ne_zero_of_mul h.ne'
  · infer_instance
#align map_le_line_map_iff_slope_le_slope_right map_le_lineMap_iff_slope_le_slope_right

/- warning: line_map_le_map_iff_slope_le_slope_right -> lineMap_le_map_iff_slope_le_slope_right is a dubious translation:
lean 3 declaration is
  forall {k : Type.{u1}} {E : Type.{u2}} [_inst_1 : LinearOrderedField.{u1} k] [_inst_2 : OrderedAddCommGroup.{u2} E] [_inst_3 : Module.{u1, u2} k E (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))] [_inst_4 : OrderedSMul.{u1, u2} k E (StrictOrderedSemiring.toOrderedSemiring.{u1} k (StrictOrderedRing.toStrictOrderedSemiring.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k (LinearOrderedCommRing.toLinearOrderedRing.{u1} k (LinearOrderedField.toLinearOrderedCommRing.{u1} k _inst_1))))) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u1, u2} k E (Semiring.toMonoidWithZero.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (AddZeroClass.toHasZero.{u2} E (AddMonoid.toAddZeroClass.{u2} E (AddCommMonoid.toAddMonoid.{u2} E (OrderedAddCommMonoid.toAddCommMonoid.{u2} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)))))) (Module.toMulActionWithZero.{u1, u2} k E (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)) _inst_3))] {f : k -> E} {a : k} {b : k} {r : k}, (LT.lt.{u1} k (Preorder.toLT.{u1} k (PartialOrder.toPreorder.{u1} k (OrderedAddCommGroup.toPartialOrder.{u1} k (StrictOrderedRing.toOrderedAddCommGroup.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k (LinearOrderedCommRing.toLinearOrderedRing.{u1} k (LinearOrderedField.toLinearOrderedCommRing.{u1} k _inst_1))))))) (OfNat.ofNat.{u1} k 0 (OfNat.mk.{u1} k 0 (Zero.zero.{u1} k (MulZeroClass.toHasZero.{u1} k (NonUnitalNonAssocSemiring.toMulZeroClass.{u1} k (NonUnitalNonAssocRing.toNonUnitalNonAssocSemiring.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))))))) (HMul.hMul.{u1, u1, u1} k k k (instHMul.{u1} k (Distrib.toHasMul.{u1} k (Ring.toDistrib.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (HSub.hSub.{u1, u1, u1} k k k (instHSub.{u1} k (SubNegMonoid.toHasSub.{u1} k (AddGroup.toSubNegMonoid.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))))) (OfNat.ofNat.{u1} k 1 (OfNat.mk.{u1} k 1 (One.one.{u1} k (AddMonoidWithOne.toOne.{u1} k (AddGroupWithOne.toAddMonoidWithOne.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))))) r) (HSub.hSub.{u1, u1, u1} k k k (instHSub.{u1} k (SubNegMonoid.toHasSub.{u1} k (AddGroup.toSubNegMonoid.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))))) b a))) -> (Iff (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (AffineMap.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (fun (_x : AffineMap.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) => k -> E) (AffineMap.hasCoeToFun.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (AffineMap.lineMap.{u1, u2, u2} k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) (f a) (f b)) r) (f (coeFn.{succ u1, succ u1} (AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (fun (_x : AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) => k -> k) (AffineMap.hasCoeToFun.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (AffineMap.lineMap.{u1, u1, u1} k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) a b) r))) (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) (slope.{u1, u2, u2} k E E (LinearOrderedField.toField.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) f (coeFn.{succ u1, succ u1} (AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (fun (_x : AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) => k -> k) (AffineMap.hasCoeToFun.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (AffineMap.lineMap.{u1, u1, u1} k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) a b) r) b) (slope.{u1, u2, u2} k E E (LinearOrderedField.toField.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) f a b)))
but is expected to have type
  forall {k : Type.{u2}} {E : Type.{u1}} [_inst_1 : LinearOrderedField.{u2} k] [_inst_2 : OrderedAddCommGroup.{u1} E] [_inst_3 : Module.{u2, u1} k E (DivisionSemiring.toSemiring.{u2} k (Semifield.toDivisionSemiring.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1)))) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2))] [_inst_4 : OrderedSMul.{u2, u1} k E (OrderedCommSemiring.toOrderedSemiring.{u2} k (StrictOrderedCommSemiring.toOrderedCommSemiring.{u2} k (LinearOrderedCommSemiring.toStrictOrderedCommSemiring.{u2} k (LinearOrderedSemifield.toLinearOrderedCommSemiring.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1))))) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u2, u1} k E (Semiring.toMonoidWithZero.{u2} k (DivisionSemiring.toSemiring.{u2} k (Semifield.toDivisionSemiring.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1))))) (AddMonoid.toZero.{u1} E (AddCommMonoid.toAddMonoid.{u1} E (OrderedAddCommMonoid.toAddCommMonoid.{u1} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2))))) (Module.toMulActionWithZero.{u2, u1} k E (DivisionSemiring.toSemiring.{u2} k (Semifield.toDivisionSemiring.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1)))) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2)) _inst_3))] {f : k -> E} {a : k} {b : k} {r : k}, (LT.lt.{u2} k (Preorder.toLT.{u2} k (PartialOrder.toPreorder.{u2} k (StrictOrderedRing.toPartialOrder.{u2} k (LinearOrderedRing.toStrictOrderedRing.{u2} k (LinearOrderedCommRing.toLinearOrderedRing.{u2} k (LinearOrderedField.toLinearOrderedCommRing.{u2} k _inst_1)))))) (OfNat.ofNat.{u2} k 0 (Zero.toOfNat0.{u2} k (CommMonoidWithZero.toZero.{u2} k (CommGroupWithZero.toCommMonoidWithZero.{u2} k (Semifield.toCommGroupWithZero.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1))))))) (HMul.hMul.{u2, u2, u2} k k k (instHMul.{u2} k (NonUnitalNonAssocRing.toMul.{u2} k (NonAssocRing.toNonUnitalNonAssocRing.{u2} k (Ring.toNonAssocRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) (HSub.hSub.{u2, u2, u2} k k k (instHSub.{u2} k (Ring.toSub.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))) (OfNat.ofNat.{u2} k 1 (One.toOfNat1.{u2} k (NonAssocRing.toOne.{u2} k (Ring.toNonAssocRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) r) (HSub.hSub.{u2, u2, u2} k k k (instHSub.{u2} k (Ring.toSub.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))) b a))) -> (Iff (LE.le.{u1} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (Preorder.toLE.{u1} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (PartialOrder.toPreorder.{u1} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (OrderedAddCommGroup.toPartialOrder.{u1} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) _inst_2))) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (AffineMap.{u2, u2, u2, u1, u1} k k k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2)))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) _x) (AffineMap.funLike.{u2, u2, u2, u1, u1} k k k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2)))) (AffineMap.lineMap.{u2, u1, u1} k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2))) (f a) (f b)) r) (f (FunLike.coe.{succ u2, succ u2, succ u2} (AffineMap.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => k) _x) (AffineMap.funLike.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) (AffineMap.lineMap.{u2, u2, u2} k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) a b) r))) (LE.le.{u1} E (Preorder.toLE.{u1} E (PartialOrder.toPreorder.{u1} E (OrderedAddCommGroup.toPartialOrder.{u1} E _inst_2))) (slope.{u2, u1, u1} k E E (LinearOrderedField.toField.{u2} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2))) f (FunLike.coe.{succ u2, succ u2, succ u2} (AffineMap.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => k) _x) (AffineMap.funLike.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) (AffineMap.lineMap.{u2, u2, u2} k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) a b) r) b) (slope.{u2, u1, u1} k E E (LinearOrderedField.toField.{u2} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2))) f a b)))
Case conversion may be inaccurate. Consider using '#align line_map_le_map_iff_slope_le_slope_right lineMap_le_map_iff_slope_le_slope_rightₓ'. -/
/-- Given `c = line_map a b r`, `c < b`, the point `(c, f c)` is non-strictly above the
segment `[(a, f a), (b, f b)]` if and only if `slope f c b ≤ slope f a b`. -/
theorem lineMap_le_map_iff_slope_le_slope_right (h : 0 < (1 - r) * (b - a)) :
    lineMap (f a) (f b) r ≤ f c ↔ slope f c b ≤ slope f a b :=
  @map_le_lineMap_iff_slope_le_slope_right k Eᵒᵈ _ _ _ _ f a b r h
#align line_map_le_map_iff_slope_le_slope_right lineMap_le_map_iff_slope_le_slope_right

/- warning: map_lt_line_map_iff_slope_lt_slope_right -> map_lt_lineMap_iff_slope_lt_slope_right is a dubious translation:
lean 3 declaration is
  forall {k : Type.{u1}} {E : Type.{u2}} [_inst_1 : LinearOrderedField.{u1} k] [_inst_2 : OrderedAddCommGroup.{u2} E] [_inst_3 : Module.{u1, u2} k E (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))] [_inst_4 : OrderedSMul.{u1, u2} k E (StrictOrderedSemiring.toOrderedSemiring.{u1} k (StrictOrderedRing.toStrictOrderedSemiring.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k (LinearOrderedCommRing.toLinearOrderedRing.{u1} k (LinearOrderedField.toLinearOrderedCommRing.{u1} k _inst_1))))) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u1, u2} k E (Semiring.toMonoidWithZero.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (AddZeroClass.toHasZero.{u2} E (AddMonoid.toAddZeroClass.{u2} E (AddCommMonoid.toAddMonoid.{u2} E (OrderedAddCommMonoid.toAddCommMonoid.{u2} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)))))) (Module.toMulActionWithZero.{u1, u2} k E (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)) _inst_3))] {f : k -> E} {a : k} {b : k} {r : k}, (LT.lt.{u1} k (Preorder.toLT.{u1} k (PartialOrder.toPreorder.{u1} k (OrderedAddCommGroup.toPartialOrder.{u1} k (StrictOrderedRing.toOrderedAddCommGroup.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k (LinearOrderedCommRing.toLinearOrderedRing.{u1} k (LinearOrderedField.toLinearOrderedCommRing.{u1} k _inst_1))))))) (OfNat.ofNat.{u1} k 0 (OfNat.mk.{u1} k 0 (Zero.zero.{u1} k (MulZeroClass.toHasZero.{u1} k (NonUnitalNonAssocSemiring.toMulZeroClass.{u1} k (NonUnitalNonAssocRing.toNonUnitalNonAssocSemiring.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))))))) (HMul.hMul.{u1, u1, u1} k k k (instHMul.{u1} k (Distrib.toHasMul.{u1} k (Ring.toDistrib.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (HSub.hSub.{u1, u1, u1} k k k (instHSub.{u1} k (SubNegMonoid.toHasSub.{u1} k (AddGroup.toSubNegMonoid.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))))) (OfNat.ofNat.{u1} k 1 (OfNat.mk.{u1} k 1 (One.one.{u1} k (AddMonoidWithOne.toOne.{u1} k (AddGroupWithOne.toAddMonoidWithOne.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))))) r) (HSub.hSub.{u1, u1, u1} k k k (instHSub.{u1} k (SubNegMonoid.toHasSub.{u1} k (AddGroup.toSubNegMonoid.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))))) b a))) -> (Iff (LT.lt.{u2} E (Preorder.toLT.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) (f (coeFn.{succ u1, succ u1} (AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (fun (_x : AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) => k -> k) (AffineMap.hasCoeToFun.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (AffineMap.lineMap.{u1, u1, u1} k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) a b) r)) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (AffineMap.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (fun (_x : AffineMap.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) => k -> E) (AffineMap.hasCoeToFun.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (AffineMap.lineMap.{u1, u2, u2} k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) (f a) (f b)) r)) (LT.lt.{u2} E (Preorder.toLT.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) (slope.{u1, u2, u2} k E E (LinearOrderedField.toField.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) f a b) (slope.{u1, u2, u2} k E E (LinearOrderedField.toField.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) f (coeFn.{succ u1, succ u1} (AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (fun (_x : AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) => k -> k) (AffineMap.hasCoeToFun.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (AffineMap.lineMap.{u1, u1, u1} k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) a b) r) b)))
but is expected to have type
  forall {k : Type.{u2}} {E : Type.{u1}} [_inst_1 : LinearOrderedField.{u2} k] [_inst_2 : OrderedAddCommGroup.{u1} E] [_inst_3 : Module.{u2, u1} k E (DivisionSemiring.toSemiring.{u2} k (Semifield.toDivisionSemiring.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1)))) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2))] [_inst_4 : OrderedSMul.{u2, u1} k E (OrderedCommSemiring.toOrderedSemiring.{u2} k (StrictOrderedCommSemiring.toOrderedCommSemiring.{u2} k (LinearOrderedCommSemiring.toStrictOrderedCommSemiring.{u2} k (LinearOrderedSemifield.toLinearOrderedCommSemiring.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1))))) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u2, u1} k E (Semiring.toMonoidWithZero.{u2} k (DivisionSemiring.toSemiring.{u2} k (Semifield.toDivisionSemiring.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1))))) (AddMonoid.toZero.{u1} E (AddCommMonoid.toAddMonoid.{u1} E (OrderedAddCommMonoid.toAddCommMonoid.{u1} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2))))) (Module.toMulActionWithZero.{u2, u1} k E (DivisionSemiring.toSemiring.{u2} k (Semifield.toDivisionSemiring.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1)))) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2)) _inst_3))] {f : k -> E} {a : k} {b : k} {r : k}, (LT.lt.{u2} k (Preorder.toLT.{u2} k (PartialOrder.toPreorder.{u2} k (StrictOrderedRing.toPartialOrder.{u2} k (LinearOrderedRing.toStrictOrderedRing.{u2} k (LinearOrderedCommRing.toLinearOrderedRing.{u2} k (LinearOrderedField.toLinearOrderedCommRing.{u2} k _inst_1)))))) (OfNat.ofNat.{u2} k 0 (Zero.toOfNat0.{u2} k (CommMonoidWithZero.toZero.{u2} k (CommGroupWithZero.toCommMonoidWithZero.{u2} k (Semifield.toCommGroupWithZero.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1))))))) (HMul.hMul.{u2, u2, u2} k k k (instHMul.{u2} k (NonUnitalNonAssocRing.toMul.{u2} k (NonAssocRing.toNonUnitalNonAssocRing.{u2} k (Ring.toNonAssocRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) (HSub.hSub.{u2, u2, u2} k k k (instHSub.{u2} k (Ring.toSub.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))) (OfNat.ofNat.{u2} k 1 (One.toOfNat1.{u2} k (NonAssocRing.toOne.{u2} k (Ring.toNonAssocRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) r) (HSub.hSub.{u2, u2, u2} k k k (instHSub.{u2} k (Ring.toSub.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))) b a))) -> (Iff (LT.lt.{u1} E (Preorder.toLT.{u1} E (PartialOrder.toPreorder.{u1} E (OrderedAddCommGroup.toPartialOrder.{u1} E _inst_2))) (f (FunLike.coe.{succ u2, succ u2, succ u2} (AffineMap.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => k) _x) (AffineMap.funLike.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) (AffineMap.lineMap.{u2, u2, u2} k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) a b) r)) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (AffineMap.{u2, u2, u2, u1, u1} k k k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2)))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) _x) (AffineMap.funLike.{u2, u2, u2, u1, u1} k k k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2)))) (AffineMap.lineMap.{u2, u1, u1} k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2))) (f a) (f b)) r)) (LT.lt.{u1} E (Preorder.toLT.{u1} E (PartialOrder.toPreorder.{u1} E (OrderedAddCommGroup.toPartialOrder.{u1} E _inst_2))) (slope.{u2, u1, u1} k E E (LinearOrderedField.toField.{u2} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2))) f a b) (slope.{u2, u1, u1} k E E (LinearOrderedField.toField.{u2} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2))) f (FunLike.coe.{succ u2, succ u2, succ u2} (AffineMap.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => k) _x) (AffineMap.funLike.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) (AffineMap.lineMap.{u2, u2, u2} k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) a b) r) b)))
Case conversion may be inaccurate. Consider using '#align map_lt_line_map_iff_slope_lt_slope_right map_lt_lineMap_iff_slope_lt_slope_rightₓ'. -/
/-- Given `c = line_map a b r`, `c < b`, the point `(c, f c)` is strictly below the
segment `[(a, f a), (b, f b)]` if and only if `slope f a b < slope f c b`. -/
theorem map_lt_lineMap_iff_slope_lt_slope_right (h : 0 < (1 - r) * (b - a)) :
    f c < lineMap (f a) (f b) r ↔ slope f a b < slope f c b :=
  lt_iff_lt_of_le_iff_le' (lineMap_le_map_iff_slope_le_slope_right h)
    (map_le_lineMap_iff_slope_le_slope_right h)
#align map_lt_line_map_iff_slope_lt_slope_right map_lt_lineMap_iff_slope_lt_slope_right

/- warning: line_map_lt_map_iff_slope_lt_slope_right -> lineMap_lt_map_iff_slope_lt_slope_right is a dubious translation:
lean 3 declaration is
  forall {k : Type.{u1}} {E : Type.{u2}} [_inst_1 : LinearOrderedField.{u1} k] [_inst_2 : OrderedAddCommGroup.{u2} E] [_inst_3 : Module.{u1, u2} k E (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))] [_inst_4 : OrderedSMul.{u1, u2} k E (StrictOrderedSemiring.toOrderedSemiring.{u1} k (StrictOrderedRing.toStrictOrderedSemiring.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k (LinearOrderedCommRing.toLinearOrderedRing.{u1} k (LinearOrderedField.toLinearOrderedCommRing.{u1} k _inst_1))))) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u1, u2} k E (Semiring.toMonoidWithZero.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (AddZeroClass.toHasZero.{u2} E (AddMonoid.toAddZeroClass.{u2} E (AddCommMonoid.toAddMonoid.{u2} E (OrderedAddCommMonoid.toAddCommMonoid.{u2} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)))))) (Module.toMulActionWithZero.{u1, u2} k E (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)) _inst_3))] {f : k -> E} {a : k} {b : k} {r : k}, (LT.lt.{u1} k (Preorder.toLT.{u1} k (PartialOrder.toPreorder.{u1} k (OrderedAddCommGroup.toPartialOrder.{u1} k (StrictOrderedRing.toOrderedAddCommGroup.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k (LinearOrderedCommRing.toLinearOrderedRing.{u1} k (LinearOrderedField.toLinearOrderedCommRing.{u1} k _inst_1))))))) (OfNat.ofNat.{u1} k 0 (OfNat.mk.{u1} k 0 (Zero.zero.{u1} k (MulZeroClass.toHasZero.{u1} k (NonUnitalNonAssocSemiring.toMulZeroClass.{u1} k (NonUnitalNonAssocRing.toNonUnitalNonAssocSemiring.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))))))) (HMul.hMul.{u1, u1, u1} k k k (instHMul.{u1} k (Distrib.toHasMul.{u1} k (Ring.toDistrib.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (HSub.hSub.{u1, u1, u1} k k k (instHSub.{u1} k (SubNegMonoid.toHasSub.{u1} k (AddGroup.toSubNegMonoid.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))))) (OfNat.ofNat.{u1} k 1 (OfNat.mk.{u1} k 1 (One.one.{u1} k (AddMonoidWithOne.toOne.{u1} k (AddGroupWithOne.toAddMonoidWithOne.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))))) r) (HSub.hSub.{u1, u1, u1} k k k (instHSub.{u1} k (SubNegMonoid.toHasSub.{u1} k (AddGroup.toSubNegMonoid.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))))) b a))) -> (Iff (LT.lt.{u2} E (Preorder.toLT.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (AffineMap.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (fun (_x : AffineMap.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) => k -> E) (AffineMap.hasCoeToFun.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (AffineMap.lineMap.{u1, u2, u2} k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) (f a) (f b)) r) (f (coeFn.{succ u1, succ u1} (AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (fun (_x : AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) => k -> k) (AffineMap.hasCoeToFun.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (AffineMap.lineMap.{u1, u1, u1} k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) a b) r))) (LT.lt.{u2} E (Preorder.toLT.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) (slope.{u1, u2, u2} k E E (LinearOrderedField.toField.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) f (coeFn.{succ u1, succ u1} (AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (fun (_x : AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) => k -> k) (AffineMap.hasCoeToFun.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (AffineMap.lineMap.{u1, u1, u1} k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) a b) r) b) (slope.{u1, u2, u2} k E E (LinearOrderedField.toField.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) f a b)))
but is expected to have type
  forall {k : Type.{u2}} {E : Type.{u1}} [_inst_1 : LinearOrderedField.{u2} k] [_inst_2 : OrderedAddCommGroup.{u1} E] [_inst_3 : Module.{u2, u1} k E (DivisionSemiring.toSemiring.{u2} k (Semifield.toDivisionSemiring.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1)))) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2))] [_inst_4 : OrderedSMul.{u2, u1} k E (OrderedCommSemiring.toOrderedSemiring.{u2} k (StrictOrderedCommSemiring.toOrderedCommSemiring.{u2} k (LinearOrderedCommSemiring.toStrictOrderedCommSemiring.{u2} k (LinearOrderedSemifield.toLinearOrderedCommSemiring.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1))))) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u2, u1} k E (Semiring.toMonoidWithZero.{u2} k (DivisionSemiring.toSemiring.{u2} k (Semifield.toDivisionSemiring.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1))))) (AddMonoid.toZero.{u1} E (AddCommMonoid.toAddMonoid.{u1} E (OrderedAddCommMonoid.toAddCommMonoid.{u1} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2))))) (Module.toMulActionWithZero.{u2, u1} k E (DivisionSemiring.toSemiring.{u2} k (Semifield.toDivisionSemiring.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1)))) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2)) _inst_3))] {f : k -> E} {a : k} {b : k} {r : k}, (LT.lt.{u2} k (Preorder.toLT.{u2} k (PartialOrder.toPreorder.{u2} k (StrictOrderedRing.toPartialOrder.{u2} k (LinearOrderedRing.toStrictOrderedRing.{u2} k (LinearOrderedCommRing.toLinearOrderedRing.{u2} k (LinearOrderedField.toLinearOrderedCommRing.{u2} k _inst_1)))))) (OfNat.ofNat.{u2} k 0 (Zero.toOfNat0.{u2} k (CommMonoidWithZero.toZero.{u2} k (CommGroupWithZero.toCommMonoidWithZero.{u2} k (Semifield.toCommGroupWithZero.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1))))))) (HMul.hMul.{u2, u2, u2} k k k (instHMul.{u2} k (NonUnitalNonAssocRing.toMul.{u2} k (NonAssocRing.toNonUnitalNonAssocRing.{u2} k (Ring.toNonAssocRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) (HSub.hSub.{u2, u2, u2} k k k (instHSub.{u2} k (Ring.toSub.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))) (OfNat.ofNat.{u2} k 1 (One.toOfNat1.{u2} k (NonAssocRing.toOne.{u2} k (Ring.toNonAssocRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) r) (HSub.hSub.{u2, u2, u2} k k k (instHSub.{u2} k (Ring.toSub.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))) b a))) -> (Iff (LT.lt.{u1} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (Preorder.toLT.{u1} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (PartialOrder.toPreorder.{u1} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (OrderedAddCommGroup.toPartialOrder.{u1} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) _inst_2))) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (AffineMap.{u2, u2, u2, u1, u1} k k k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2)))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) _x) (AffineMap.funLike.{u2, u2, u2, u1, u1} k k k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2)))) (AffineMap.lineMap.{u2, u1, u1} k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2))) (f a) (f b)) r) (f (FunLike.coe.{succ u2, succ u2, succ u2} (AffineMap.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => k) _x) (AffineMap.funLike.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) (AffineMap.lineMap.{u2, u2, u2} k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) a b) r))) (LT.lt.{u1} E (Preorder.toLT.{u1} E (PartialOrder.toPreorder.{u1} E (OrderedAddCommGroup.toPartialOrder.{u1} E _inst_2))) (slope.{u2, u1, u1} k E E (LinearOrderedField.toField.{u2} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2))) f (FunLike.coe.{succ u2, succ u2, succ u2} (AffineMap.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => k) _x) (AffineMap.funLike.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) (AffineMap.lineMap.{u2, u2, u2} k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) a b) r) b) (slope.{u2, u1, u1} k E E (LinearOrderedField.toField.{u2} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2))) f a b)))
Case conversion may be inaccurate. Consider using '#align line_map_lt_map_iff_slope_lt_slope_right lineMap_lt_map_iff_slope_lt_slope_rightₓ'. -/
/-- Given `c = line_map a b r`, `c < b`, the point `(c, f c)` is strictly above the
segment `[(a, f a), (b, f b)]` if and only if `slope f c b < slope f a b`. -/
theorem lineMap_lt_map_iff_slope_lt_slope_right (h : 0 < (1 - r) * (b - a)) :
    lineMap (f a) (f b) r < f c ↔ slope f c b < slope f a b :=
  @map_lt_lineMap_iff_slope_lt_slope_right k Eᵒᵈ _ _ _ _ f a b r h
#align line_map_lt_map_iff_slope_lt_slope_right lineMap_lt_map_iff_slope_lt_slope_right

/- warning: map_le_line_map_iff_slope_le_slope -> map_le_lineMap_iff_slope_le_slope is a dubious translation:
lean 3 declaration is
  forall {k : Type.{u1}} {E : Type.{u2}} [_inst_1 : LinearOrderedField.{u1} k] [_inst_2 : OrderedAddCommGroup.{u2} E] [_inst_3 : Module.{u1, u2} k E (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))] [_inst_4 : OrderedSMul.{u1, u2} k E (StrictOrderedSemiring.toOrderedSemiring.{u1} k (StrictOrderedRing.toStrictOrderedSemiring.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k (LinearOrderedCommRing.toLinearOrderedRing.{u1} k (LinearOrderedField.toLinearOrderedCommRing.{u1} k _inst_1))))) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u1, u2} k E (Semiring.toMonoidWithZero.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (AddZeroClass.toHasZero.{u2} E (AddMonoid.toAddZeroClass.{u2} E (AddCommMonoid.toAddMonoid.{u2} E (OrderedAddCommMonoid.toAddCommMonoid.{u2} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)))))) (Module.toMulActionWithZero.{u1, u2} k E (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)) _inst_3))] {f : k -> E} {a : k} {b : k} {r : k}, (LT.lt.{u1} k (Preorder.toLT.{u1} k (PartialOrder.toPreorder.{u1} k (OrderedAddCommGroup.toPartialOrder.{u1} k (StrictOrderedRing.toOrderedAddCommGroup.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k (LinearOrderedCommRing.toLinearOrderedRing.{u1} k (LinearOrderedField.toLinearOrderedCommRing.{u1} k _inst_1))))))) a b) -> (LT.lt.{u1} k (Preorder.toLT.{u1} k (PartialOrder.toPreorder.{u1} k (OrderedAddCommGroup.toPartialOrder.{u1} k (StrictOrderedRing.toOrderedAddCommGroup.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k (LinearOrderedCommRing.toLinearOrderedRing.{u1} k (LinearOrderedField.toLinearOrderedCommRing.{u1} k _inst_1))))))) (OfNat.ofNat.{u1} k 0 (OfNat.mk.{u1} k 0 (Zero.zero.{u1} k (MulZeroClass.toHasZero.{u1} k (NonUnitalNonAssocSemiring.toMulZeroClass.{u1} k (NonUnitalNonAssocRing.toNonUnitalNonAssocSemiring.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))))))) r) -> (LT.lt.{u1} k (Preorder.toLT.{u1} k (PartialOrder.toPreorder.{u1} k (OrderedAddCommGroup.toPartialOrder.{u1} k (StrictOrderedRing.toOrderedAddCommGroup.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k (LinearOrderedCommRing.toLinearOrderedRing.{u1} k (LinearOrderedField.toLinearOrderedCommRing.{u1} k _inst_1))))))) r (OfNat.ofNat.{u1} k 1 (OfNat.mk.{u1} k 1 (One.one.{u1} k (AddMonoidWithOne.toOne.{u1} k (AddGroupWithOne.toAddMonoidWithOne.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))))))) -> (Iff (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) (f (coeFn.{succ u1, succ u1} (AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (fun (_x : AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) => k -> k) (AffineMap.hasCoeToFun.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (AffineMap.lineMap.{u1, u1, u1} k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) a b) r)) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (AffineMap.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (fun (_x : AffineMap.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) => k -> E) (AffineMap.hasCoeToFun.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (AffineMap.lineMap.{u1, u2, u2} k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) (f a) (f b)) r)) (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) (slope.{u1, u2, u2} k E E (LinearOrderedField.toField.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) f a (coeFn.{succ u1, succ u1} (AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (fun (_x : AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) => k -> k) (AffineMap.hasCoeToFun.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (AffineMap.lineMap.{u1, u1, u1} k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) a b) r)) (slope.{u1, u2, u2} k E E (LinearOrderedField.toField.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) f (coeFn.{succ u1, succ u1} (AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (fun (_x : AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) => k -> k) (AffineMap.hasCoeToFun.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (AffineMap.lineMap.{u1, u1, u1} k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) a b) r) b)))
but is expected to have type
  forall {k : Type.{u2}} {E : Type.{u1}} [_inst_1 : LinearOrderedField.{u2} k] [_inst_2 : OrderedAddCommGroup.{u1} E] [_inst_3 : Module.{u2, u1} k E (DivisionSemiring.toSemiring.{u2} k (Semifield.toDivisionSemiring.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1)))) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2))] [_inst_4 : OrderedSMul.{u2, u1} k E (OrderedCommSemiring.toOrderedSemiring.{u2} k (StrictOrderedCommSemiring.toOrderedCommSemiring.{u2} k (LinearOrderedCommSemiring.toStrictOrderedCommSemiring.{u2} k (LinearOrderedSemifield.toLinearOrderedCommSemiring.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1))))) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u2, u1} k E (Semiring.toMonoidWithZero.{u2} k (DivisionSemiring.toSemiring.{u2} k (Semifield.toDivisionSemiring.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1))))) (AddMonoid.toZero.{u1} E (AddCommMonoid.toAddMonoid.{u1} E (OrderedAddCommMonoid.toAddCommMonoid.{u1} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2))))) (Module.toMulActionWithZero.{u2, u1} k E (DivisionSemiring.toSemiring.{u2} k (Semifield.toDivisionSemiring.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1)))) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2)) _inst_3))] {f : k -> E} {a : k} {b : k} {r : k}, (LT.lt.{u2} k (Preorder.toLT.{u2} k (PartialOrder.toPreorder.{u2} k (StrictOrderedRing.toPartialOrder.{u2} k (LinearOrderedRing.toStrictOrderedRing.{u2} k (LinearOrderedCommRing.toLinearOrderedRing.{u2} k (LinearOrderedField.toLinearOrderedCommRing.{u2} k _inst_1)))))) a b) -> (LT.lt.{u2} k (Preorder.toLT.{u2} k (PartialOrder.toPreorder.{u2} k (StrictOrderedRing.toPartialOrder.{u2} k (LinearOrderedRing.toStrictOrderedRing.{u2} k (LinearOrderedCommRing.toLinearOrderedRing.{u2} k (LinearOrderedField.toLinearOrderedCommRing.{u2} k _inst_1)))))) (OfNat.ofNat.{u2} k 0 (Zero.toOfNat0.{u2} k (CommMonoidWithZero.toZero.{u2} k (CommGroupWithZero.toCommMonoidWithZero.{u2} k (Semifield.toCommGroupWithZero.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1))))))) r) -> (LT.lt.{u2} k (Preorder.toLT.{u2} k (PartialOrder.toPreorder.{u2} k (StrictOrderedRing.toPartialOrder.{u2} k (LinearOrderedRing.toStrictOrderedRing.{u2} k (LinearOrderedCommRing.toLinearOrderedRing.{u2} k (LinearOrderedField.toLinearOrderedCommRing.{u2} k _inst_1)))))) r (OfNat.ofNat.{u2} k 1 (One.toOfNat1.{u2} k (NonAssocRing.toOne.{u2} k (Ring.toNonAssocRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))))) -> (Iff (LE.le.{u1} E (Preorder.toLE.{u1} E (PartialOrder.toPreorder.{u1} E (OrderedAddCommGroup.toPartialOrder.{u1} E _inst_2))) (f (FunLike.coe.{succ u2, succ u2, succ u2} (AffineMap.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => k) _x) (AffineMap.funLike.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) (AffineMap.lineMap.{u2, u2, u2} k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) a b) r)) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (AffineMap.{u2, u2, u2, u1, u1} k k k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2)))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) _x) (AffineMap.funLike.{u2, u2, u2, u1, u1} k k k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2)))) (AffineMap.lineMap.{u2, u1, u1} k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2))) (f a) (f b)) r)) (LE.le.{u1} E (Preorder.toLE.{u1} E (PartialOrder.toPreorder.{u1} E (OrderedAddCommGroup.toPartialOrder.{u1} E _inst_2))) (slope.{u2, u1, u1} k E E (LinearOrderedField.toField.{u2} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2))) f a (FunLike.coe.{succ u2, succ u2, succ u2} (AffineMap.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => k) _x) (AffineMap.funLike.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) (AffineMap.lineMap.{u2, u2, u2} k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) a b) r)) (slope.{u2, u1, u1} k E E (LinearOrderedField.toField.{u2} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2))) f (FunLike.coe.{succ u2, succ u2, succ u2} (AffineMap.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => k) _x) (AffineMap.funLike.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) (AffineMap.lineMap.{u2, u2, u2} k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) a b) r) b)))
Case conversion may be inaccurate. Consider using '#align map_le_line_map_iff_slope_le_slope map_le_lineMap_iff_slope_le_slopeₓ'. -/
/-- Given `c = line_map a b r`, `a < c < b`, the point `(c, f c)` is non-strictly below the
segment `[(a, f a), (b, f b)]` if and only if `slope f a c ≤ slope f c b`. -/
theorem map_le_lineMap_iff_slope_le_slope (hab : a < b) (h₀ : 0 < r) (h₁ : r < 1) :
    f c ≤ lineMap (f a) (f b) r ↔ slope f a c ≤ slope f c b :=
  by
  rw [map_le_lineMap_iff_slope_le_slope_left (mul_pos h₀ (sub_pos.2 hab)), ←
    lineMap_slope_lineMap_slope_lineMap f a b r, right_le_lineMap_iff_le h₁]
  infer_instance
  infer_instance
#align map_le_line_map_iff_slope_le_slope map_le_lineMap_iff_slope_le_slope

/- warning: line_map_le_map_iff_slope_le_slope -> lineMap_le_map_iff_slope_le_slope is a dubious translation:
lean 3 declaration is
  forall {k : Type.{u1}} {E : Type.{u2}} [_inst_1 : LinearOrderedField.{u1} k] [_inst_2 : OrderedAddCommGroup.{u2} E] [_inst_3 : Module.{u1, u2} k E (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))] [_inst_4 : OrderedSMul.{u1, u2} k E (StrictOrderedSemiring.toOrderedSemiring.{u1} k (StrictOrderedRing.toStrictOrderedSemiring.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k (LinearOrderedCommRing.toLinearOrderedRing.{u1} k (LinearOrderedField.toLinearOrderedCommRing.{u1} k _inst_1))))) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u1, u2} k E (Semiring.toMonoidWithZero.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (AddZeroClass.toHasZero.{u2} E (AddMonoid.toAddZeroClass.{u2} E (AddCommMonoid.toAddMonoid.{u2} E (OrderedAddCommMonoid.toAddCommMonoid.{u2} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)))))) (Module.toMulActionWithZero.{u1, u2} k E (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)) _inst_3))] {f : k -> E} {a : k} {b : k} {r : k}, (LT.lt.{u1} k (Preorder.toLT.{u1} k (PartialOrder.toPreorder.{u1} k (OrderedAddCommGroup.toPartialOrder.{u1} k (StrictOrderedRing.toOrderedAddCommGroup.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k (LinearOrderedCommRing.toLinearOrderedRing.{u1} k (LinearOrderedField.toLinearOrderedCommRing.{u1} k _inst_1))))))) a b) -> (LT.lt.{u1} k (Preorder.toLT.{u1} k (PartialOrder.toPreorder.{u1} k (OrderedAddCommGroup.toPartialOrder.{u1} k (StrictOrderedRing.toOrderedAddCommGroup.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k (LinearOrderedCommRing.toLinearOrderedRing.{u1} k (LinearOrderedField.toLinearOrderedCommRing.{u1} k _inst_1))))))) (OfNat.ofNat.{u1} k 0 (OfNat.mk.{u1} k 0 (Zero.zero.{u1} k (MulZeroClass.toHasZero.{u1} k (NonUnitalNonAssocSemiring.toMulZeroClass.{u1} k (NonUnitalNonAssocRing.toNonUnitalNonAssocSemiring.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))))))) r) -> (LT.lt.{u1} k (Preorder.toLT.{u1} k (PartialOrder.toPreorder.{u1} k (OrderedAddCommGroup.toPartialOrder.{u1} k (StrictOrderedRing.toOrderedAddCommGroup.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k (LinearOrderedCommRing.toLinearOrderedRing.{u1} k (LinearOrderedField.toLinearOrderedCommRing.{u1} k _inst_1))))))) r (OfNat.ofNat.{u1} k 1 (OfNat.mk.{u1} k 1 (One.one.{u1} k (AddMonoidWithOne.toOne.{u1} k (AddGroupWithOne.toAddMonoidWithOne.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))))))) -> (Iff (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (AffineMap.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (fun (_x : AffineMap.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) => k -> E) (AffineMap.hasCoeToFun.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (AffineMap.lineMap.{u1, u2, u2} k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) (f a) (f b)) r) (f (coeFn.{succ u1, succ u1} (AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (fun (_x : AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) => k -> k) (AffineMap.hasCoeToFun.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (AffineMap.lineMap.{u1, u1, u1} k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) a b) r))) (LE.le.{u2} E (Preorder.toLE.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) (slope.{u1, u2, u2} k E E (LinearOrderedField.toField.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) f (coeFn.{succ u1, succ u1} (AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (fun (_x : AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) => k -> k) (AffineMap.hasCoeToFun.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (AffineMap.lineMap.{u1, u1, u1} k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) a b) r) b) (slope.{u1, u2, u2} k E E (LinearOrderedField.toField.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) f a (coeFn.{succ u1, succ u1} (AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (fun (_x : AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) => k -> k) (AffineMap.hasCoeToFun.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (AffineMap.lineMap.{u1, u1, u1} k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) a b) r))))
but is expected to have type
  forall {k : Type.{u2}} {E : Type.{u1}} [_inst_1 : LinearOrderedField.{u2} k] [_inst_2 : OrderedAddCommGroup.{u1} E] [_inst_3 : Module.{u2, u1} k E (DivisionSemiring.toSemiring.{u2} k (Semifield.toDivisionSemiring.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1)))) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2))] [_inst_4 : OrderedSMul.{u2, u1} k E (OrderedCommSemiring.toOrderedSemiring.{u2} k (StrictOrderedCommSemiring.toOrderedCommSemiring.{u2} k (LinearOrderedCommSemiring.toStrictOrderedCommSemiring.{u2} k (LinearOrderedSemifield.toLinearOrderedCommSemiring.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1))))) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u2, u1} k E (Semiring.toMonoidWithZero.{u2} k (DivisionSemiring.toSemiring.{u2} k (Semifield.toDivisionSemiring.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1))))) (AddMonoid.toZero.{u1} E (AddCommMonoid.toAddMonoid.{u1} E (OrderedAddCommMonoid.toAddCommMonoid.{u1} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2))))) (Module.toMulActionWithZero.{u2, u1} k E (DivisionSemiring.toSemiring.{u2} k (Semifield.toDivisionSemiring.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1)))) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2)) _inst_3))] {f : k -> E} {a : k} {b : k} {r : k}, (LT.lt.{u2} k (Preorder.toLT.{u2} k (PartialOrder.toPreorder.{u2} k (StrictOrderedRing.toPartialOrder.{u2} k (LinearOrderedRing.toStrictOrderedRing.{u2} k (LinearOrderedCommRing.toLinearOrderedRing.{u2} k (LinearOrderedField.toLinearOrderedCommRing.{u2} k _inst_1)))))) a b) -> (LT.lt.{u2} k (Preorder.toLT.{u2} k (PartialOrder.toPreorder.{u2} k (StrictOrderedRing.toPartialOrder.{u2} k (LinearOrderedRing.toStrictOrderedRing.{u2} k (LinearOrderedCommRing.toLinearOrderedRing.{u2} k (LinearOrderedField.toLinearOrderedCommRing.{u2} k _inst_1)))))) (OfNat.ofNat.{u2} k 0 (Zero.toOfNat0.{u2} k (CommMonoidWithZero.toZero.{u2} k (CommGroupWithZero.toCommMonoidWithZero.{u2} k (Semifield.toCommGroupWithZero.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1))))))) r) -> (LT.lt.{u2} k (Preorder.toLT.{u2} k (PartialOrder.toPreorder.{u2} k (StrictOrderedRing.toPartialOrder.{u2} k (LinearOrderedRing.toStrictOrderedRing.{u2} k (LinearOrderedCommRing.toLinearOrderedRing.{u2} k (LinearOrderedField.toLinearOrderedCommRing.{u2} k _inst_1)))))) r (OfNat.ofNat.{u2} k 1 (One.toOfNat1.{u2} k (NonAssocRing.toOne.{u2} k (Ring.toNonAssocRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))))) -> (Iff (LE.le.{u1} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (Preorder.toLE.{u1} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (PartialOrder.toPreorder.{u1} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (OrderedAddCommGroup.toPartialOrder.{u1} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) _inst_2))) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (AffineMap.{u2, u2, u2, u1, u1} k k k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2)))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) _x) (AffineMap.funLike.{u2, u2, u2, u1, u1} k k k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2)))) (AffineMap.lineMap.{u2, u1, u1} k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2))) (f a) (f b)) r) (f (FunLike.coe.{succ u2, succ u2, succ u2} (AffineMap.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => k) _x) (AffineMap.funLike.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) (AffineMap.lineMap.{u2, u2, u2} k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) a b) r))) (LE.le.{u1} E (Preorder.toLE.{u1} E (PartialOrder.toPreorder.{u1} E (OrderedAddCommGroup.toPartialOrder.{u1} E _inst_2))) (slope.{u2, u1, u1} k E E (LinearOrderedField.toField.{u2} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2))) f (FunLike.coe.{succ u2, succ u2, succ u2} (AffineMap.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => k) _x) (AffineMap.funLike.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) (AffineMap.lineMap.{u2, u2, u2} k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) a b) r) b) (slope.{u2, u1, u1} k E E (LinearOrderedField.toField.{u2} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2))) f a (FunLike.coe.{succ u2, succ u2, succ u2} (AffineMap.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => k) _x) (AffineMap.funLike.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) (AffineMap.lineMap.{u2, u2, u2} k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) a b) r))))
Case conversion may be inaccurate. Consider using '#align line_map_le_map_iff_slope_le_slope lineMap_le_map_iff_slope_le_slopeₓ'. -/
/-- Given `c = line_map a b r`, `a < c < b`, the point `(c, f c)` is non-strictly above the
segment `[(a, f a), (b, f b)]` if and only if `slope f c b ≤ slope f a c`. -/
theorem lineMap_le_map_iff_slope_le_slope (hab : a < b) (h₀ : 0 < r) (h₁ : r < 1) :
    lineMap (f a) (f b) r ≤ f c ↔ slope f c b ≤ slope f a c :=
  @map_le_lineMap_iff_slope_le_slope k Eᵒᵈ _ _ _ _ _ _ _ _ hab h₀ h₁
#align line_map_le_map_iff_slope_le_slope lineMap_le_map_iff_slope_le_slope

/- warning: map_lt_line_map_iff_slope_lt_slope -> map_lt_lineMap_iff_slope_lt_slope is a dubious translation:
lean 3 declaration is
  forall {k : Type.{u1}} {E : Type.{u2}} [_inst_1 : LinearOrderedField.{u1} k] [_inst_2 : OrderedAddCommGroup.{u2} E] [_inst_3 : Module.{u1, u2} k E (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))] [_inst_4 : OrderedSMul.{u1, u2} k E (StrictOrderedSemiring.toOrderedSemiring.{u1} k (StrictOrderedRing.toStrictOrderedSemiring.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k (LinearOrderedCommRing.toLinearOrderedRing.{u1} k (LinearOrderedField.toLinearOrderedCommRing.{u1} k _inst_1))))) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u1, u2} k E (Semiring.toMonoidWithZero.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (AddZeroClass.toHasZero.{u2} E (AddMonoid.toAddZeroClass.{u2} E (AddCommMonoid.toAddMonoid.{u2} E (OrderedAddCommMonoid.toAddCommMonoid.{u2} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)))))) (Module.toMulActionWithZero.{u1, u2} k E (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)) _inst_3))] {f : k -> E} {a : k} {b : k} {r : k}, (LT.lt.{u1} k (Preorder.toLT.{u1} k (PartialOrder.toPreorder.{u1} k (OrderedAddCommGroup.toPartialOrder.{u1} k (StrictOrderedRing.toOrderedAddCommGroup.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k (LinearOrderedCommRing.toLinearOrderedRing.{u1} k (LinearOrderedField.toLinearOrderedCommRing.{u1} k _inst_1))))))) a b) -> (LT.lt.{u1} k (Preorder.toLT.{u1} k (PartialOrder.toPreorder.{u1} k (OrderedAddCommGroup.toPartialOrder.{u1} k (StrictOrderedRing.toOrderedAddCommGroup.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k (LinearOrderedCommRing.toLinearOrderedRing.{u1} k (LinearOrderedField.toLinearOrderedCommRing.{u1} k _inst_1))))))) (OfNat.ofNat.{u1} k 0 (OfNat.mk.{u1} k 0 (Zero.zero.{u1} k (MulZeroClass.toHasZero.{u1} k (NonUnitalNonAssocSemiring.toMulZeroClass.{u1} k (NonUnitalNonAssocRing.toNonUnitalNonAssocSemiring.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))))))) r) -> (LT.lt.{u1} k (Preorder.toLT.{u1} k (PartialOrder.toPreorder.{u1} k (OrderedAddCommGroup.toPartialOrder.{u1} k (StrictOrderedRing.toOrderedAddCommGroup.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k (LinearOrderedCommRing.toLinearOrderedRing.{u1} k (LinearOrderedField.toLinearOrderedCommRing.{u1} k _inst_1))))))) r (OfNat.ofNat.{u1} k 1 (OfNat.mk.{u1} k 1 (One.one.{u1} k (AddMonoidWithOne.toOne.{u1} k (AddGroupWithOne.toAddMonoidWithOne.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))))))) -> (Iff (LT.lt.{u2} E (Preorder.toLT.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) (f (coeFn.{succ u1, succ u1} (AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (fun (_x : AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) => k -> k) (AffineMap.hasCoeToFun.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (AffineMap.lineMap.{u1, u1, u1} k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) a b) r)) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (AffineMap.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (fun (_x : AffineMap.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) => k -> E) (AffineMap.hasCoeToFun.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (AffineMap.lineMap.{u1, u2, u2} k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) (f a) (f b)) r)) (LT.lt.{u2} E (Preorder.toLT.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) (slope.{u1, u2, u2} k E E (LinearOrderedField.toField.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) f a (coeFn.{succ u1, succ u1} (AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (fun (_x : AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) => k -> k) (AffineMap.hasCoeToFun.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (AffineMap.lineMap.{u1, u1, u1} k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) a b) r)) (slope.{u1, u2, u2} k E E (LinearOrderedField.toField.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) f (coeFn.{succ u1, succ u1} (AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (fun (_x : AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) => k -> k) (AffineMap.hasCoeToFun.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (AffineMap.lineMap.{u1, u1, u1} k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) a b) r) b)))
but is expected to have type
  forall {k : Type.{u2}} {E : Type.{u1}} [_inst_1 : LinearOrderedField.{u2} k] [_inst_2 : OrderedAddCommGroup.{u1} E] [_inst_3 : Module.{u2, u1} k E (DivisionSemiring.toSemiring.{u2} k (Semifield.toDivisionSemiring.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1)))) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2))] [_inst_4 : OrderedSMul.{u2, u1} k E (OrderedCommSemiring.toOrderedSemiring.{u2} k (StrictOrderedCommSemiring.toOrderedCommSemiring.{u2} k (LinearOrderedCommSemiring.toStrictOrderedCommSemiring.{u2} k (LinearOrderedSemifield.toLinearOrderedCommSemiring.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1))))) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u2, u1} k E (Semiring.toMonoidWithZero.{u2} k (DivisionSemiring.toSemiring.{u2} k (Semifield.toDivisionSemiring.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1))))) (AddMonoid.toZero.{u1} E (AddCommMonoid.toAddMonoid.{u1} E (OrderedAddCommMonoid.toAddCommMonoid.{u1} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2))))) (Module.toMulActionWithZero.{u2, u1} k E (DivisionSemiring.toSemiring.{u2} k (Semifield.toDivisionSemiring.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1)))) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2)) _inst_3))] {f : k -> E} {a : k} {b : k} {r : k}, (LT.lt.{u2} k (Preorder.toLT.{u2} k (PartialOrder.toPreorder.{u2} k (StrictOrderedRing.toPartialOrder.{u2} k (LinearOrderedRing.toStrictOrderedRing.{u2} k (LinearOrderedCommRing.toLinearOrderedRing.{u2} k (LinearOrderedField.toLinearOrderedCommRing.{u2} k _inst_1)))))) a b) -> (LT.lt.{u2} k (Preorder.toLT.{u2} k (PartialOrder.toPreorder.{u2} k (StrictOrderedRing.toPartialOrder.{u2} k (LinearOrderedRing.toStrictOrderedRing.{u2} k (LinearOrderedCommRing.toLinearOrderedRing.{u2} k (LinearOrderedField.toLinearOrderedCommRing.{u2} k _inst_1)))))) (OfNat.ofNat.{u2} k 0 (Zero.toOfNat0.{u2} k (CommMonoidWithZero.toZero.{u2} k (CommGroupWithZero.toCommMonoidWithZero.{u2} k (Semifield.toCommGroupWithZero.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1))))))) r) -> (LT.lt.{u2} k (Preorder.toLT.{u2} k (PartialOrder.toPreorder.{u2} k (StrictOrderedRing.toPartialOrder.{u2} k (LinearOrderedRing.toStrictOrderedRing.{u2} k (LinearOrderedCommRing.toLinearOrderedRing.{u2} k (LinearOrderedField.toLinearOrderedCommRing.{u2} k _inst_1)))))) r (OfNat.ofNat.{u2} k 1 (One.toOfNat1.{u2} k (NonAssocRing.toOne.{u2} k (Ring.toNonAssocRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))))) -> (Iff (LT.lt.{u1} E (Preorder.toLT.{u1} E (PartialOrder.toPreorder.{u1} E (OrderedAddCommGroup.toPartialOrder.{u1} E _inst_2))) (f (FunLike.coe.{succ u2, succ u2, succ u2} (AffineMap.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => k) _x) (AffineMap.funLike.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) (AffineMap.lineMap.{u2, u2, u2} k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) a b) r)) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (AffineMap.{u2, u2, u2, u1, u1} k k k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2)))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) _x) (AffineMap.funLike.{u2, u2, u2, u1, u1} k k k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2)))) (AffineMap.lineMap.{u2, u1, u1} k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2))) (f a) (f b)) r)) (LT.lt.{u1} E (Preorder.toLT.{u1} E (PartialOrder.toPreorder.{u1} E (OrderedAddCommGroup.toPartialOrder.{u1} E _inst_2))) (slope.{u2, u1, u1} k E E (LinearOrderedField.toField.{u2} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2))) f a (FunLike.coe.{succ u2, succ u2, succ u2} (AffineMap.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => k) _x) (AffineMap.funLike.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) (AffineMap.lineMap.{u2, u2, u2} k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) a b) r)) (slope.{u2, u1, u1} k E E (LinearOrderedField.toField.{u2} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2))) f (FunLike.coe.{succ u2, succ u2, succ u2} (AffineMap.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => k) _x) (AffineMap.funLike.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) (AffineMap.lineMap.{u2, u2, u2} k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) a b) r) b)))
Case conversion may be inaccurate. Consider using '#align map_lt_line_map_iff_slope_lt_slope map_lt_lineMap_iff_slope_lt_slopeₓ'. -/
/-- Given `c = line_map a b r`, `a < c < b`, the point `(c, f c)` is strictly below the
segment `[(a, f a), (b, f b)]` if and only if `slope f a c < slope f c b`. -/
theorem map_lt_lineMap_iff_slope_lt_slope (hab : a < b) (h₀ : 0 < r) (h₁ : r < 1) :
    f c < lineMap (f a) (f b) r ↔ slope f a c < slope f c b :=
  lt_iff_lt_of_le_iff_le' (lineMap_le_map_iff_slope_le_slope hab h₀ h₁)
    (map_le_lineMap_iff_slope_le_slope hab h₀ h₁)
#align map_lt_line_map_iff_slope_lt_slope map_lt_lineMap_iff_slope_lt_slope

/- warning: line_map_lt_map_iff_slope_lt_slope -> lineMap_lt_map_iff_slope_lt_slope is a dubious translation:
lean 3 declaration is
  forall {k : Type.{u1}} {E : Type.{u2}} [_inst_1 : LinearOrderedField.{u1} k] [_inst_2 : OrderedAddCommGroup.{u2} E] [_inst_3 : Module.{u1, u2} k E (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))] [_inst_4 : OrderedSMul.{u1, u2} k E (StrictOrderedSemiring.toOrderedSemiring.{u1} k (StrictOrderedRing.toStrictOrderedSemiring.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k (LinearOrderedCommRing.toLinearOrderedRing.{u1} k (LinearOrderedField.toLinearOrderedCommRing.{u1} k _inst_1))))) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u1, u2} k E (Semiring.toMonoidWithZero.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (AddZeroClass.toHasZero.{u2} E (AddMonoid.toAddZeroClass.{u2} E (AddCommMonoid.toAddMonoid.{u2} E (OrderedAddCommMonoid.toAddCommMonoid.{u2} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u2} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u2} E _inst_2)))))) (Module.toMulActionWithZero.{u1, u2} k E (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))) (AddCommGroup.toAddCommMonoid.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)) _inst_3))] {f : k -> E} {a : k} {b : k} {r : k}, (LT.lt.{u1} k (Preorder.toLT.{u1} k (PartialOrder.toPreorder.{u1} k (OrderedAddCommGroup.toPartialOrder.{u1} k (StrictOrderedRing.toOrderedAddCommGroup.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k (LinearOrderedCommRing.toLinearOrderedRing.{u1} k (LinearOrderedField.toLinearOrderedCommRing.{u1} k _inst_1))))))) a b) -> (LT.lt.{u1} k (Preorder.toLT.{u1} k (PartialOrder.toPreorder.{u1} k (OrderedAddCommGroup.toPartialOrder.{u1} k (StrictOrderedRing.toOrderedAddCommGroup.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k (LinearOrderedCommRing.toLinearOrderedRing.{u1} k (LinearOrderedField.toLinearOrderedCommRing.{u1} k _inst_1))))))) (OfNat.ofNat.{u1} k 0 (OfNat.mk.{u1} k 0 (Zero.zero.{u1} k (MulZeroClass.toHasZero.{u1} k (NonUnitalNonAssocSemiring.toMulZeroClass.{u1} k (NonUnitalNonAssocRing.toNonUnitalNonAssocSemiring.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))))))) r) -> (LT.lt.{u1} k (Preorder.toLT.{u1} k (PartialOrder.toPreorder.{u1} k (OrderedAddCommGroup.toPartialOrder.{u1} k (StrictOrderedRing.toOrderedAddCommGroup.{u1} k (LinearOrderedRing.toStrictOrderedRing.{u1} k (LinearOrderedCommRing.toLinearOrderedRing.{u1} k (LinearOrderedField.toLinearOrderedCommRing.{u1} k _inst_1))))))) r (OfNat.ofNat.{u1} k 1 (OfNat.mk.{u1} k 1 (One.one.{u1} k (AddMonoidWithOne.toOne.{u1} k (AddGroupWithOne.toAddMonoidWithOne.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))))))) -> (Iff (LT.lt.{u2} E (Preorder.toLT.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (AffineMap.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (fun (_x : AffineMap.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) => k -> E) (AffineMap.hasCoeToFun.{u1, u1, u1, u2, u2} k k k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2)))) (AffineMap.lineMap.{u1, u2, u2} k E E (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) (f a) (f b)) r) (f (coeFn.{succ u1, succ u1} (AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (fun (_x : AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) => k -> k) (AffineMap.hasCoeToFun.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (AffineMap.lineMap.{u1, u1, u1} k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) a b) r))) (LT.lt.{u2} E (Preorder.toLT.{u2} E (PartialOrder.toPreorder.{u2} E (OrderedAddCommGroup.toPartialOrder.{u2} E _inst_2))) (slope.{u1, u2, u2} k E E (LinearOrderedField.toField.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) f (coeFn.{succ u1, succ u1} (AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (fun (_x : AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) => k -> k) (AffineMap.hasCoeToFun.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (AffineMap.lineMap.{u1, u1, u1} k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) a b) r) b) (slope.{u1, u2, u2} k E E (LinearOrderedField.toField.{u1} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u2} E (AddCommGroup.toAddGroup.{u2} E (OrderedAddCommGroup.toAddCommGroup.{u2} E _inst_2))) f a (coeFn.{succ u1, succ u1} (AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (fun (_x : AffineMap.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) => k -> k) (AffineMap.hasCoeToFun.{u1, u1, u1, u1, u1} k k k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))))) (AffineMap.lineMap.{u1, u1, u1} k k k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))) (NonUnitalNonAssocRing.toAddCommGroup.{u1} k (NonAssocRing.toNonUnitalNonAssocRing.{u1} k (Ring.toNonAssocRing.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1)))))) (Semiring.toModule.{u1} k (Ring.toSemiring.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))) (addGroupIsAddTorsor.{u1} k (AddGroupWithOne.toAddGroup.{u1} k (AddCommGroupWithOne.toAddGroupWithOne.{u1} k (Ring.toAddCommGroupWithOne.{u1} k (DivisionRing.toRing.{u1} k (Field.toDivisionRing.{u1} k (LinearOrderedField.toField.{u1} k _inst_1))))))) a b) r))))
but is expected to have type
  forall {k : Type.{u2}} {E : Type.{u1}} [_inst_1 : LinearOrderedField.{u2} k] [_inst_2 : OrderedAddCommGroup.{u1} E] [_inst_3 : Module.{u2, u1} k E (DivisionSemiring.toSemiring.{u2} k (Semifield.toDivisionSemiring.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1)))) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2))] [_inst_4 : OrderedSMul.{u2, u1} k E (OrderedCommSemiring.toOrderedSemiring.{u2} k (StrictOrderedCommSemiring.toOrderedCommSemiring.{u2} k (LinearOrderedCommSemiring.toStrictOrderedCommSemiring.{u2} k (LinearOrderedSemifield.toLinearOrderedCommSemiring.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1))))) (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2)) (MulActionWithZero.toSMulWithZero.{u2, u1} k E (Semiring.toMonoidWithZero.{u2} k (DivisionSemiring.toSemiring.{u2} k (Semifield.toDivisionSemiring.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1))))) (AddMonoid.toZero.{u1} E (AddCommMonoid.toAddMonoid.{u1} E (OrderedAddCommMonoid.toAddCommMonoid.{u1} E (OrderedCancelAddCommMonoid.toOrderedAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2))))) (Module.toMulActionWithZero.{u2, u1} k E (DivisionSemiring.toSemiring.{u2} k (Semifield.toDivisionSemiring.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1)))) (OrderedCancelAddCommMonoid.toAddCommMonoid.{u1} E (OrderedAddCommGroup.toOrderedCancelAddCommMonoid.{u1} E _inst_2)) _inst_3))] {f : k -> E} {a : k} {b : k} {r : k}, (LT.lt.{u2} k (Preorder.toLT.{u2} k (PartialOrder.toPreorder.{u2} k (StrictOrderedRing.toPartialOrder.{u2} k (LinearOrderedRing.toStrictOrderedRing.{u2} k (LinearOrderedCommRing.toLinearOrderedRing.{u2} k (LinearOrderedField.toLinearOrderedCommRing.{u2} k _inst_1)))))) a b) -> (LT.lt.{u2} k (Preorder.toLT.{u2} k (PartialOrder.toPreorder.{u2} k (StrictOrderedRing.toPartialOrder.{u2} k (LinearOrderedRing.toStrictOrderedRing.{u2} k (LinearOrderedCommRing.toLinearOrderedRing.{u2} k (LinearOrderedField.toLinearOrderedCommRing.{u2} k _inst_1)))))) (OfNat.ofNat.{u2} k 0 (Zero.toOfNat0.{u2} k (CommMonoidWithZero.toZero.{u2} k (CommGroupWithZero.toCommMonoidWithZero.{u2} k (Semifield.toCommGroupWithZero.{u2} k (LinearOrderedSemifield.toSemifield.{u2} k (LinearOrderedField.toLinearOrderedSemifield.{u2} k _inst_1))))))) r) -> (LT.lt.{u2} k (Preorder.toLT.{u2} k (PartialOrder.toPreorder.{u2} k (StrictOrderedRing.toPartialOrder.{u2} k (LinearOrderedRing.toStrictOrderedRing.{u2} k (LinearOrderedCommRing.toLinearOrderedRing.{u2} k (LinearOrderedField.toLinearOrderedCommRing.{u2} k _inst_1)))))) r (OfNat.ofNat.{u2} k 1 (One.toOfNat1.{u2} k (NonAssocRing.toOne.{u2} k (Ring.toNonAssocRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))))) -> (Iff (LT.lt.{u1} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (Preorder.toLT.{u1} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (PartialOrder.toPreorder.{u1} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) (OrderedAddCommGroup.toPartialOrder.{u1} ((fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) r) _inst_2))) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (AffineMap.{u2, u2, u2, u1, u1} k k k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2)))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => E) _x) (AffineMap.funLike.{u2, u2, u2, u1, u1} k k k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2)))) (AffineMap.lineMap.{u2, u1, u1} k E E (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2))) (f a) (f b)) r) (f (FunLike.coe.{succ u2, succ u2, succ u2} (AffineMap.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => k) _x) (AffineMap.funLike.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) (AffineMap.lineMap.{u2, u2, u2} k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) a b) r))) (LT.lt.{u1} E (Preorder.toLT.{u1} E (PartialOrder.toPreorder.{u1} E (OrderedAddCommGroup.toPartialOrder.{u1} E _inst_2))) (slope.{u2, u1, u1} k E E (LinearOrderedField.toField.{u2} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2))) f (FunLike.coe.{succ u2, succ u2, succ u2} (AffineMap.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => k) _x) (AffineMap.funLike.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) (AffineMap.lineMap.{u2, u2, u2} k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) a b) r) b) (slope.{u2, u1, u1} k E E (LinearOrderedField.toField.{u2} k _inst_1) (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2) _inst_3 (addGroupIsAddTorsor.{u1} E (AddCommGroup.toAddGroup.{u1} E (OrderedAddCommGroup.toAddCommGroup.{u1} E _inst_2))) f a (FunLike.coe.{succ u2, succ u2, succ u2} (AffineMap.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) k (fun (_x : k) => (fun (a._@.Mathlib.LinearAlgebra.AffineSpace.AffineMap._hyg.1004 : k) => k) _x) (AffineMap.funLike.{u2, u2, u2, u2, u2} k k k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))))))) (AffineMap.lineMap.{u2, u2, u2} k k k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1))) (Ring.toAddCommGroup.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (AffineMap.instModuleToSemiringToAddCommMonoidToNonUnitalNonAssocSemiringToNonUnitalNonAssocRingToNonUnitalRing.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))) (addGroupIsAddTorsor.{u2} k (AddGroupWithOne.toAddGroup.{u2} k (Ring.toAddGroupWithOne.{u2} k (DivisionRing.toRing.{u2} k (Field.toDivisionRing.{u2} k (LinearOrderedField.toField.{u2} k _inst_1)))))) a b) r))))
Case conversion may be inaccurate. Consider using '#align line_map_lt_map_iff_slope_lt_slope lineMap_lt_map_iff_slope_lt_slopeₓ'. -/
/-- Given `c = line_map a b r`, `a < c < b`, the point `(c, f c)` is strictly above the
segment `[(a, f a), (b, f b)]` if and only if `slope f c b < slope f a c`. -/
theorem lineMap_lt_map_iff_slope_lt_slope (hab : a < b) (h₀ : 0 < r) (h₁ : r < 1) :
    lineMap (f a) (f b) r < f c ↔ slope f c b < slope f a c :=
  @map_lt_lineMap_iff_slope_lt_slope k Eᵒᵈ _ _ _ _ _ _ _ _ hab h₀ h₁
#align line_map_lt_map_iff_slope_lt_slope lineMap_lt_map_iff_slope_lt_slope

end LinearOrderedField