Incorrect floating-point numbers in sample model

This forum is for discussion of the System Dynamics model representation standard XMILE. Discussion here will be monitored by the Society's technical standards committee with ideas and concerns conveyed to the OASIS Technical Committee responsible for defining the standard.
Forum rules
Please note: By posting here you grant permission to the Society Technical Committee members to repost with attribution on the OASIS discussion forum. If you have material for which you wish to maintain copyright control please post a link to the copyrighted work.
Post Reply
Robert Muetzelfeldt
Posts: 29
Joined: Sun Jan 08, 2012 7:20 pm
Location: Edinburgh, Scotland, UK

Incorrect floating-point numbers in sample model

Post by Robert Muetzelfeldt » Tue Dec 15, 2015 4:11 pm

The XMILE spec states that floating-point numbers should conform to IEEE 754. This specifies that numbers should not begin with a leading decimal point.

However, the set of sample models for the spec includes one model ( lynx-hares.xml ) which has values which do begin with a leading decimal point, as shown in this extract:

Code: Select all

. . . . .
      <aux name="lynx_death_fraction">
          <xscale min="0" max="100" />
          <yscale min="0" max="1" />
. . . . .
This model validates OK, because the values are not represented individually, but rather are a single text value for the <ypts> element.

The immediate need is to fix values in the sample model, and any other models which include a lookup.

A better solution is to change the spec to list the values individually, so that they can be validated against the Schema, like:

Code: Select all

. . . . .
         . . . . .
. . . . . 

Karim Chichakly
Posts: 46
Joined: Fri Apr 10, 2009 11:52 am

Re: Incorrect floating-point numbers in sample model

Post by Karim Chichakly » Mon Dec 21, 2015 3:46 pm

The intention of IEEE 754 compatibility was for the behavior of operations, not the format of floating point numbers as text. The spec clearly shows the BNF for floating point numbers in Section 3.2.1, along with examples. Leading decimals are allowed.

Post Reply

Who is online

Users browsing this forum: No registered users and 2 guests