CellML Discussion List

Text archives Help


[cellml-discussion] Another thing to fix before CellML 1.1 is finalised


Chronological Thread 
  • From: ak.miller at auckland.ac.nz (Andrew Miller)
  • Subject: [cellml-discussion] Another thing to fix before CellML 1.1 is finalised
  • Date: Sat Mar 5 12:06:55 2005

In addition to the XSD(which I am making progress on), and the definition of
the
independent variable, we will probably also need to fix the table of "prefix"
values before CellML 1.1 is finalised...

The prefix attribute can be used to indicate a scale for the referenced units.
It is included primarily for the convenience of modellers who want to define
units that differ from another units definition only by an SI scale factor.
Its
value must be from the standard set of CellML prefix names given in Table 3 or
be an integer, in which case the units are pre-multiplied by 10 to the power
of
this number. The default value of the prefix attribute is "0" (the referenced
units are scaled by a factor of one).
name factor name factor
yotta 10^24 deci 10^-1
zetta 10^21 centi 10^-2
exa 10^18 milli 10^-3
peta 10^15 micro 10^-6
tera 10^12 nano 10^-9
giga 10^9 pico 10^-12
mega 10^6 femto 10^-15
kilo 10^3 atto 10^-18
hecto 10^2 zepto 10^-21
deka 10^1 yocto 10^-24
Table 3 The set of names that may be used in the prefix attribute on a <unit>
element and the corresponding scale factors that will pre-multiply the unit.

Note that the factors are the wrong way around -- e.g. to convert from milli
to
the SI unit, you should multiply by 10^3 not 10^-3.

Best regards,
Andrew


----------------------------------------------------------------
This message was sent using IMP, the Internet Messaging Program.
>From ak.miller at auckland.ac.nz Sat Mar 5 17:40:19 2005
From: ak.miller at auckland.ac.nz (Andrew Miller)
Date: Sat Mar 5 17:40:21 2005
Subject: [cellml-discussion] (no subject)
Message-ID:
<1109997619.422938330b675 AT www.bioeng.auckland.ac.nz>

Please find attached a draft XML Schema Definition for CellML 1.1. It is in a
tar file including the MathML XSDs from W3C(with a trivial modification so
that
the toplevel math element can't contain presentation elements).

I also attached a small Java program which can be used to validate against the
XSD. You need Xerces-J to use this.

Usage:
java SchemaValidator "http://www.cellml.org/cellml/1.1# cellml_1_1.xsd"
model.xml
You have to either give a full file URL to the XSD, or otherwise put the model
in the same directory as the XSD.

Best regards,
Andrew


----------------------------------------------------------------
This message was sent using IMP, the Internet Messaging Program.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: SchemaValidator.java
Type: text/x-java
Size: 2074 bytes
Desc: not available
Url :
http://www.cellml.org/pipermail/cellml-discussion/attachments/20050305/346561d6/SchemaValidator-0001.java
-------------- next part --------------
A non-text attachment was scrubbed...
Name: CellML_1_1_xsds.tar.gz
Type: application/x-gzip
Size: 12936 bytes
Desc: not available
Url :
http://www.cellml.org/pipermail/cellml-discussion/attachments/20050305/346561d6/CellML_1_1_xsds.tar-0001.bin
>From d.nickerson at auckland.ac.nz Mon Mar 7 13:32:21 2005
From: d.nickerson at auckland.ac.nz (David Nickerson)
Date: Mon Mar 7 13:32:24 2005
Subject: [cellml-discussion] Another thing to fix before CellML 1.1 is
finalised
In-Reply-To:
<1109977613.4228ea0d70f46 AT www.bioeng.auckland.ac.nz>
References:
<1109977613.4228ea0d70f46 AT www.bioeng.auckland.ac.nz>
Message-ID:
<422BA115.9090406 AT auckland.ac.nz>

I guess I must be missing something, but as I understand it the factors
in that table are simply the numerical equivalent used when the name is
given in a prefix attribute. e.g. 1 milli metre is equivalent to 1*10^-3
metres (so prefix="-3").


Andrew Miller wrote:
> In addition to the XSD(which I am making progress on), and the definition
> of the
> independent variable, we will probably also need to fix the table of
> "prefix"
> values before CellML 1.1 is finalised...
>
> The prefix attribute can be used to indicate a scale for the referenced
> units.
> It is included primarily for the convenience of modellers who want to define
> units that differ from another units definition only by an SI scale factor.
> Its
> value must be from the standard set of CellML prefix names given in Table 3
> or
> be an integer, in which case the units are pre-multiplied by 10 to the
> power of
> this number. The default value of the prefix attribute is "0" (the
> referenced
> units are scaled by a factor of one).
> name factor name factor
> yotta 10^24 deci 10^-1
> zetta 10^21 centi 10^-2
> exa 10^18 milli 10^-3
> peta 10^15 micro 10^-6
> tera 10^12 nano 10^-9
> giga 10^9 pico 10^-12
> mega 10^6 femto 10^-15
> kilo 10^3 atto 10^-18
> hecto 10^2 zepto 10^-21
> deka 10^1 yocto 10^-24
> Table 3 The set of names that may be used in the prefix attribute on a
> <unit>
> element and the corresponding scale factors that will pre-multiply the unit.
>
> Note that the factors are the wrong way around -- e.g. to convert from
> milli to
> the SI unit, you should multiply by 10^3 not 10^-3.
>
> Best regards,
> Andrew
>
>
> ----------------------------------------------------------------
> This message was sent using IMP, the Internet Messaging Program.
> _______________________________________________
> cellml-discussion mailing list
> cellml-discussion AT cellml.org
> http://www.cellml.org/mailman/listinfo/cellml-discussion
>From ak.miller at auckland.ac.nz Mon Mar 7 13:52:22 2005
From: ak.miller at auckland.ac.nz (Andrew Miller)
Date: Mon Mar 7 13:52:24 2005
Subject: [cellml-discussion] Another thing to fix before CellML 1.1 is
finalised
In-Reply-To:
<422BA115.9090406 AT auckland.ac.nz>
References:
<1109977613.4228ea0d70f46 AT www.bioeng.auckland.ac.nz>

<422BA115.9090406 AT auckland.ac.nz>
Message-ID:
<1110156742.422ba5c6210e2 AT www.bioeng.auckland.ac.nz>

Quoting David Nickerson
<d.nickerson AT auckland.ac.nz>:

> I guess I must be missing something, but as I understand it the factors
> in that table are simply the numerical equivalent used when the name is
> given in a prefix attribute. e.g. 1 milli metre is equivalent to 1*10^-3
> metres (so prefix="-3").
Look at this in the context of equation 4, which explicitly specifies that the
prefix should be multiplied. Perhaps it is, however, equation 4 that is
wrong?(it also multiplies directly by the prefix attribute without raising it
to a power of 10). However, the prose should at least be clarified to explain
exactly what is meant by the factor, and how prefix is treated when it is an
integer.

Best regards,
Andrew


----------------------------------------------------------------
This message was sent using IMP, the Internet Messaging Program.
>From ak.miller at auckland.ac.nz Mon Mar 7 17:02:30 2005
From: ak.miller at auckland.ac.nz (Andrew Miller)
Date: Mon Mar 7 17:02:31 2005
Subject: [cellml-discussion] API: CellML structure change monitoring
Message-ID:
<1110168150.422bd2562c6a4 AT www.bioeng.auckland.ac.nz>

One of the goals of the CellML API should probably be to allow several users
to
work on the same CellML model at the same time. This will allow for, for
example, editor and evaluator(e.g. integrator) components to be placed in the
same model.

To do this, however, it would often be necessary to register to receive
notifications whenever part of the model changed. It would probably be
convenient to split such changes into four categories...
1) XML Comment or whitespace changes(where this information is kept in the
representation).
2) Changes to metadata.
3) Changes to initial_value attributes.
4) Structural changes to the model(all changes that don't fit into the first 3
categories).

This way, components could cache information from the model and invalidate the
cache whenever changes that would cause it to give inaccurate results occur.
It
could also be used to track the "dirty" state of a model to determine if it
should be saved, and to perform lazy cloning(where the model is cloned by a
component, but only after someone else tries to change it). To support all
these, there would need to be "pre"-change and "post"-change notifications.

The natural way to do this would be to define an interface like this:
interface CellMLModelChangeListener
{
/**
* Called prior to changing the metadata.
* @param model The model being changed.
* @return True to allow the change, or false to block it.
*/
bool preChangeMetadata(CellMLModel model);
void postChangeMetadata(CellMLModel model);

bool preChangeInitialValue(CellMLModel model);
void preChangeIntialValue(CellMLModel model);

bool preChangeStructure(CellMLModel model);
void preChangeStructure(CellMLModel model);
};
On top of this, there would need to be a way to register that change
notifications are desired with the CellMLModel.

Best regards,
Andrew


----------------------------------------------------------------
This message was sent using IMP, the Internet Messaging Program.
>From whedley at sdsc.edu Tue Mar 8 06:24:09 2005
From: whedley at sdsc.edu (Warren Hedley)
Date: Tue Mar 8 06:23:50 2005
Subject: [cellml-discussion] Another thing to fix before CellML 1.1 is
finalised
In-Reply-To:
<1110156742.422ba5c6210e2 AT www.bioeng.auckland.ac.nz>
References:
<1109977613.4228ea0d70f46 AT www.bioeng.auckland.ac.nz>

<422BA115.9090406 AT auckland.ac.nz>

<1110156742.422ba5c6210e2 AT www.bioeng.auckland.ac.nz>
Message-ID:
<422C8E39.8010700 AT sdsc.edu>

Hi Andrew,

David has the right interpretation of the spec, but you're correct in
pointing out that the text below equation (3) doesn't properly define
what the "prefix" variable is supposed to be.

Probably that last sentence should be split into:

Units are the units being defined, and multiplier, units and offset
correspond to the values of the appropriate attributes on the <unit>
element. Prefix is either 10 to the power of the value of the prefix
attribute (if an integer value is specified) or the value from table 3
that corresponds to the value of a text prefix attribute.

Can whoever's now maintaining the spec proofread the above and add it to
the errata for version 1.0 and the current spec?

Note that the definition gets cleared up by example in equation (6)
though, if that helps.

Regards,
Warren



Andrew Miller postulated on 03/06/2005 04:52 PM:
> Quoting David Nickerson
> <d.nickerson AT auckland.ac.nz>:
>
>
>>I guess I must be missing something, but as I understand it the factors
>>in that table are simply the numerical equivalent used when the name is
>>given in a prefix attribute. e.g. 1 milli metre is equivalent to 1*10^-3
>>metres (so prefix="-3").
>
> Look at this in the context of equation 4, which explicitly specifies that
> the
> prefix should be multiplied. Perhaps it is, however, equation 4 that is
> wrong?(it also multiplies directly by the prefix attribute without raising
> it
> to a power of 10). However, the prose should at least be clarified to
> explain
> exactly what is meant by the factor, and how prefix is treated when it is an
> integer.
>

--
Warren Hedley
>From ak.miller at auckland.ac.nz Sat Mar 26 16:11:00 2005
From: ak.miller at auckland.ac.nz (Andrew Miller)
Date: Sat Mar 26 16:11:03 2005
Subject: [cellml-discussion] Another IDL for the CellML API
Message-ID:
<1111810260.4244e0d4d8d6d AT www.bioeng.auckland.ac.nz>

This CellML API is based upon the specification at
http://n2.bioeng5.bioeng.auckland.ac.nz/development/documentation/apifiles/APIideas.pdf
by Matt Halstead.

It has the following differences:
1) It is a formulated in IDL instead as in a "more casual approach".
2) The naming of some objects has been changed to better fit into the usual
way
of doing things in IDL. For example, mixed case is used to separate words in
identifiers, instead of underscores. In addition, CellML was appended to a
number of names, like Component, to avoid conflicts with IDL reserved words.
Some names were also changed because case-insensitive conflicts of attribute
and interface names is not allowed in IDL.
3) As required by IDL, a decision about what attributes were readonly and
which
ones are read-write was made. Furthermore, all methods which take no
parameters, return no values, and are not expected to have any side effects
were converted to readonly attributes. Attributes referring to a CollectionOf*
were all made to be read-only(this doesn't mean you can't do any operations on
the collection that modify the collection, it just means you can't switch the
connection itself).
4) The collection architecture was changed somewhat to accomodate the need for
immutable collections. There are now ConstCollectionOf* and CollectionOf*
collections available, related by an inheritance hierarchy. The polymorphic
inheritance hierarchy chosen may need further study to ensure it is generally
applicable.


This version has Doxygen/Javadoc style comments on every interface(except
forward definitions), attribute, method, enumeration, and enumeration option.

Things which require further work are flagged with @todo. There are a number
of
these:
CellMLAttributeString has two @todo flags, one for whose responsibility
escaping
is, and another for the underlying IDL datatype to use.

The model interface has two @todo flags, one because I removed the model
manager
as previously agreed in-person with Matt(but not yet reflected in Matt's
spec),
and this needs further work, and one because the namespace map was removed,
again based on what Matt and I agreed on in-person.

CellMLImport::fullyInstantiate has a @todo flag to properly define "full
instantiation".

ImportComponent::componentRef has a @todo flag to define what happens if
componentRef is changed after fullyInstantiate() is called.

Group has a @todo flag because I don't understand what
Component get_parent_component_name(component name)
Component get_children_component_names(component name)
means.

Best regards,
Andrew


----------------------------------------------------------------
This message was sent using IMP, the Internet Messaging Program.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: CellML-APISPEC.idl
Type: text/x-idl
Size: 35545 bytes
Desc: not available
Url :
http://www.cellml.org/pipermail/cellml-discussion/attachments/20050326/4a79c94a/CellML-APISPEC-0001.bin




Archive powered by MHonArc 2.6.18.

Top of page