Home My Page Projects Code Snippets Project Openings diderot
Summary Activity Tracker Tasks SCM

SCM Repository

[diderot] Diff of /branches/vis12/src/compiler/basis/basis-vars.sml
ViewVC logotype

Diff of /branches/vis12/src/compiler/basis/basis-vars.sml

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 2164, Fri Feb 22 22:44:05 2013 UTC revision 2165, Fri Feb 22 22:44:32 2013 UTC
# Line 173  Line 173 
173                      --> field(k, d, dd)                      --> field(k, d, dd)
174                  end))                  end))
175    
176      (* curl on 2d and 3d vector fields *)
177        local
178          val diff0 = Ty.DiffConst 0
179          fun field' (k, d, dd) = field(k, Ty.DimConst d, Ty.Shape(List.map Ty.DimConst dd))
180        in
181    (* FIXME: we want to be able to require that k > 0, but we don't have a way to do that! *)
182        val curl2D = polyVar (N.op_curl, all([DK],
183              fn [Ty.DIFF k] =>
184                [field' (Ty.DiffVar(k, 0), 2, [2])] --> field' (diff0, 2, [])))
185        val curl3D = polyVar (N.op_curl, all([DK],
186              fn [Ty.DIFF k] =>
187                [field' (Ty.DiffVar(k, 0), 3, [3])] --> field' (diff0, 2, [3])))
188        end (* local *)
189    
190      val lt_ii = monoVar(N.op_lt, [Ty.T_Int, Ty.T_Int] --> Ty.T_Bool)      val lt_ii = monoVar(N.op_lt, [Ty.T_Int, Ty.T_Int] --> Ty.T_Bool)
191      val lt_rr = monoVar(N.op_lt, [Ty.realTy, Ty.realTy] --> Ty.T_Bool)      val lt_rr = monoVar(N.op_lt, [Ty.realTy, Ty.realTy] --> Ty.T_Bool)
192      val lte_ii = monoVar(N.op_lte, [Ty.T_Int, Ty.T_Int] --> Ty.T_Bool)      val lte_ii = monoVar(N.op_lte, [Ty.T_Int, Ty.T_Int] --> Ty.T_Bool)

Legend:
Removed from v.2164  
changed lines
  Added in v.2165

root@smlnj-gforge.cs.uchicago.edu
ViewVC Help
Powered by ViewVC 1.0.0