Opened 10 years ago

Closed 10 years ago

#2817 closed defect (fixed)

Modelica.Math.Vectors.Utilities.roots crashes

Reported by: lafrasu@… Owned by: Martin Sjölund
Priority: high Milestone: 1.9.1
Component: Code Generation Version: trunk
Keywords: vector, roots Cc:

Description (last modified by Martin Sjölund)

The following script:

model Poly
  import Modelica.Math.Vectors.Utilities.roots;
  Real a;
  parameter Real b=2, c=3, d=4, e=5;
  Real p[5];
  Real r[4,2];
initial equation
  a = 1;
equation
  p = {a, b, c, d, e};
  r = Modelica.Math.Vectors.Utilities.roots(p);
  der(a) = 1;
end Poly;

produces the following output:

base_array.c: array dimension size for dimension 0 is -1 < 0!
Poly: util/real_array.c:98: void copy_real_array_data(const real_array_t, real_array_t *): Assertion `base_array_ok(dest)' failed.
Aborted

Change History (2)

comment:1 by Martin Sjölund, 10 years ago

Component: BackendCode Generation
Description: modified (diff)
Milestone: Future1.9.1
Owner: changed from somebody to Martin Sjölund
Status: newassigned

comment:2 by Martin Sjölund, 10 years ago

Resolution: fixed
Status: assignedclosed

Fixed in r22453.

Note: See TracTickets for help on using tickets.