Opened 12 years ago
Last modified 8 years ago
#2647 new enhancement
Expression.simplify is ways too — at Initial Version
| Reported by: | Willi Braun | Owned by: | probably noone | 
|---|---|---|---|
| Priority: | high | Milestone: | Future | 
| Component: | Backend | Version: | trunk | 
| Keywords: | Cc: | 
Description
For the following models the compile time increases heavy, if one increase the size. 
  model BaseModelEquations
    parameter Integer n=100; // see Backend time for 100, 200, 400
    input Real[n] u1;
    input Real[n] u2;
    output Real[n] y1;
    output Real y2;
  equation
    y1=array(if u1[i] > 0 then u1[i] else u2[i] for i in 1:n);
    y2=sum(y1);
  end BaseModelEquations;
For n=100 : timeBackend = 0.266189871 For n=200 : timeBackend = 1.490894306 For n=400 : timeBackend = 10.56719995
All the time is lost by trying to simplify expressions. 
Also we try to do it 3 time, once by creating the BackendDAE structure, 
once directly after that and once at the end of the Backend process.
We should do it only once and perhaps we should improve Expression.simplify further anyway.
  Note:
 See   TracTickets
 for help on using tickets.
    