@@ -15,6 +15,12 @@ R2 := Smooth.( 2 );
1515# ! ℝ^2
1616R3 := Smooth.( 3 );
1717# ! ℝ^3
18+ R1 / Para;
19+ # ! ℝ^1
20+ Para.( 1 );
21+ # ! ℝ^1
22+ IsEqualForObjects( Para.( 1 ), R1 / Para );
23+ # ! true
1824f := Smooth.Softmax( 3 );
1925# ! ℝ^3 -> ℝ^3
2026f := MorphismConstructor( Para, R1 / Para, [ R2, f ] , R3 / Para );
@@ -41,6 +47,8 @@ Display( f );
4147# ! ‣ Exp( x1 ) / (Exp( x1 ) + Exp( x2 ) + Exp( x3 ))
4248# ! ‣ Exp( x2 ) / (Exp( x1 ) + Exp( x2 ) + Exp( x3 ))
4349# ! ‣ Exp( x3 ) / (Exp( x1 ) + Exp( x2 ) + Exp( x3 ))
50+ IsWellDefined( f );
51+ # ! true
4452r := DirectProductFunctorial( Smooth, [ Smooth.Sqrt, Smooth.Cos ] );
4553# ! ℝ^2 -> ℝ^2
4654Display( r );
@@ -110,7 +118,7 @@ Display( h );
110118# ! + x6 * (Exp( Cos( x10 ) ) / (Exp( Sqrt( x9 ) ) + Exp( Cos( x10 ) ) + Exp( x11 )))
111119# ! + x7 * (Exp( x11 ) / (Exp( Sqrt( x9 ) ) + Exp( Cos( x10 ) ) + Exp( x11 ))) + x8
112120constants := [ 0.91 , 0.24 , 0.88 , 0.59 , 0.67 , 0.05 , 0.85 , 0.31 , 0.76 , 0.04 ] ;;
113- r := SmoothMorphism( Smooth, Smooth.( 0 ), constants, Smooth.( 10 ) );
121+ r := Smooth.Constant( constants );
114122# ! ℝ^0 -> ℝ^10
115123t := ReparametriseMorphism( h, r );
116124# ! ℝ^1 -> ℝ^2 defined by:
@@ -147,7 +155,7 @@ s := SimplifyMorphism( t, infinity );
147155# ! Parametrised Morphism:
148156# ! ----------------------
149157# ! ℝ^1 -> ℝ^2
150- # ! gap> Display( s );
158+ Display( s );
151159# ! ℝ^1 -> ℝ^2 defined by:
152160# !
153161# ! Parameter Object:
@@ -160,4 +168,30 @@ s := SimplifyMorphism( t, infinity );
160168# !
161169# ! ‣ (1.47 * Exp( x1 ) + 5.84111) / (Exp( x1 ) + 5.10727)
162170# ! ‣ (1.16 * Exp( x1 ) + 3.32114) / (Exp( x1 ) + 5.10727)
171+ iota := NaturalEmbeddingIntoCategoryOfParametrisedMorphisms( Smooth, Para );
172+ # ! Natural embedding into category of parametrised morphisms
173+ ApplyFunctor( iota, Smooth.( 1 ) );
174+ # ! ℝ^1
175+ psi := ApplyFunctor( iota, Smooth.Sum( 2 ) );
176+ # ! ℝ^2 -> ℝ^1 defined by:
177+ # !
178+ # ! Parameter Object:
179+ # ! -----------------
180+ # ! ℝ^0
181+ # !
182+ # ! Parametrised Morphism:
183+ # ! ----------------------
184+ # ! ℝ^2 -> ℝ^1
185+ Print( DisplayString( psi ) );
186+ # ! ℝ^2 -> ℝ^1 defined by:
187+ # !
188+ # ! Parameter Object:
189+ # ! -----------------
190+ # ! ℝ^0
191+ # !
192+ # ! Parametrised Morphism:
193+ # ! ----------------------
194+ # ! ℝ^2 -> ℝ^1
195+ # !
196+ # ! ‣ x1 + x2
163197# ! @EndExample
0 commit comments