module Cat.Displayed.Diagram.Total.Exponential
  {o β o' β'} {B : Precategory o β} (E : Displayed B o' β')
  {bcart : Cartesian-category B} (ecart : Cartesian-over E bcart)
  whereopen Cat.Displayed.Reasoning E
open Cartesian-category bcart
open Cartesian-over ecartTotal exponential objectsπ
Let be a displayed category with total products over a Cartesian category and be the evaluation map for an exponential object in
A map is the evaluation map for a total exponential object in if we have an operation assigning to each a universal morphism with uniqueness and commutativity lying over those for
This definition follows the logic of βtotal universal constructionsβ, where we can display universal constructions in over the corresponding constructions in and this is equivalent to the total category having, and the projection functor preserving, those same constructions.
module
  _ {A B B^A : Ob} {ev : Hom (B^A ββ A) B}
    (exp : is-exponential _ bcart B^A ev)
    {A' : E Κ» A} {B' : E Κ» B} (B^A' : E Κ» B^A)
  where  record is-exponential-over (ev' : Hom[ ev ] (B^A' ββ' A') B')
    : Type (o β β β o' β β') where
    open is-exponential exp
    field
      Ζ'
        : β {Ξ Ξ'} {m : Hom (Ξ ββ A) B} (m' : Hom[ m ] (Ξ' ββ' A') B')
        β Hom[ Ζ m ] Ξ' B^A'
      commutes'
        : β {Ξ Ξ'} {m : Hom (Ξ ββ A) B} (m' : Hom[ m ] (Ξ' ββ' A') B')
        β ev' β' β¨ Ζ' m' β' Οβ' , id' β' Οβ' β©' β‘[ commutes m ] m'
      unique'
        : β {Ξ Ξ'} {m : Hom (Ξ ββ _) _} {n}
        β {p : ev β (n ββ id) β‘ m}
        β {m' : Hom[ m ] (Ξ' ββ' _) _} (n' : Hom[ n ] Ξ' _)
        β ev' β' β¨ n' β' Οβ' , id' β' Οβ' β©' β‘[ p ] m'
        β n' β‘[ unique n p ] Ζ' m'module _ {A B : Ob} (exp : Exponential _ bcart A B) where
  open Exponential exp
  record ExponentialP (A' : E Κ» A) (B' : E Κ» B) : Type (o β β β o' β β') where
    no-eta-equality
    field
      B^A'                : E Κ» B^A
      ev'                 : Hom[ ev ] (B^A' ββ' A') B'
      has-is-exponential' : is-exponential-over has-is-exp B^A' ev'
    open is-exponential-over has-is-exponential' public
Cartesian-closed-over : Cartesian-closed B bcart β Type _
Cartesian-closed-over cc =
  let open Cartesian-closed cc
   in β {A B} (A' : E Κ» A) (B' : E Κ» B) β ExponentialP (has-exp A B) A' B'
module Cartesian-closed-over {cc : Cartesian-closed B bcart} (cco : Cartesian-closed-over cc) where
  module _ {a b : Ob} (a' : E Κ» a) (b' : E Κ» b) where open ExponentialP (cco a' b') renaming (B^A' to [_,_]') using () public
  module _ {a b : Ob} {a' : E Κ» a} {b' : E Κ» b} where open ExponentialP (cco a' b') renaming (unique' to Ζ'-unique) hiding (B^A') public