/[ascend]/trunk/models/johnpye/testcmslv2.a4c
ViewVC logotype

Diff of /trunk/models/johnpye/testcmslv2.a4c

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

revision 973 by johnpye, Fri Aug 4 09:08:16 2006 UTC revision 974 by johnpye, Tue Dec 19 11:00:57 2006 UTC
# Line 7  REQUIRE "atoms.a4l"; Line 7  REQUIRE "atoms.a4l";
7              1 +      .              1 +      .
8                |    .'                |    .'
9                |  .'                |  .'
10                |.'                |.'    1
11       <-+------*------+->       <-+------*------+->
12        -1  .-'`|      1        -1 _.-'`|
13        ,-'`    + -1/2       ,-'`     + - 0.5
14                |                  |  
15  *)  *)
16  MODEL testcmslv2;  MODEL testcmslv2;
# Line 18  MODEL testcmslv2; Line 18  MODEL testcmslv2;
18      y IS_A factor;      y IS_A factor;
19    
20      rhs: y = x;      rhs: y = x;
21      lhs: y = -0.5*x;      lhs: y = 0.5*x;
22    
23      CONDITIONAL      CONDITIONAL
24          ispos: x > 0;          ispos: x > 0;
# Line 36  MODEL testcmslv2; Line 36  MODEL testcmslv2;
36    
37  METHODS  METHODS
38  METHOD default_self;  METHOD default_self;
39      ispos := TRUE;      isposp := TRUE;
40      y := 0.0;      y := 3.0;
41      x := 0.0;      x := 3.0;
42  END default_self;  END default_self;
43    
44  METHOD values;  METHOD values;
45      x := 3;      x := -1;
46  END values;  END values;
47    
48  METHOD specify;  METHOD specify;
# Line 53  METHOD on_load; Line 53  METHOD on_load;
53      RUN default_self; RUN values; RUN specify;      RUN default_self; RUN values; RUN specify;
54  END on_load;  END on_load;
55    
56    METHOD self_test;
57        ASSERT y == -0.5;
58    END self_test;
59    
60  END testcmslv2;  END testcmslv2;

Legend:
Removed from v.973  
changed lines
  Added in v.974

john.pye@anu.edu.au
ViewVC Help
Powered by ViewVC 1.1.22