Search in sources :

Example 41 with Domain

use of cbit.vcell.math.Variable.Domain in project vcell by virtualcell.

the class XmlReader method getMembraneParticalVariable.

private MembraneParticleVariable getMembraneParticalVariable(Element param) {
    String name = unMangle(param.getAttributeValue(XMLTags.NameAttrTag));
    String domainStr = unMangle(param.getAttributeValue(XMLTags.DomainAttrTag));
    Domain domain = null;
    if (domainStr != null) {
        domain = new Domain(domainStr);
    }
    // -- create new VolVariable object
    MembraneParticleVariable var = new MembraneParticleVariable(name, domain);
    transcribeComments(param, var);
    return var;
}
Also used : MembraneParticleVariable(cbit.vcell.math.MembraneParticleVariable) MembraneSubDomain(cbit.vcell.math.MembraneSubDomain) CompartmentSubDomain(cbit.vcell.math.CompartmentSubDomain) FilamentSubDomain(cbit.vcell.math.FilamentSubDomain) PointSubDomain(cbit.vcell.math.PointSubDomain) Domain(cbit.vcell.math.Variable.Domain)

Example 42 with Domain

use of cbit.vcell.math.Variable.Domain in project vcell by virtualcell.

the class XmlReader method getFilamentRegionVariable.

/**
 * This method returns a FilamentRegionVariable object from a XML Element.
 * Creation date: (5/16/2001 2:56:34 PM)
 * @return cbit.vcell.math.FilamentRegionVariable
 * @param param org.jdom.Element
 */
private FilamentRegionVariable getFilamentRegionVariable(Element param) {
    String name = unMangle(param.getAttributeValue(XMLTags.NameAttrTag));
    String domainStr = unMangle(param.getAttributeValue(XMLTags.DomainAttrTag));
    Domain domain = null;
    if (domainStr != null) {
        domain = new Domain(domainStr);
    }
    // -- create new FilamentRegionVariable object
    FilamentRegionVariable filRegVariable = new FilamentRegionVariable(name, domain);
    transcribeComments(param, filRegVariable);
    return filRegVariable;
}
Also used : FilamentRegionVariable(cbit.vcell.math.FilamentRegionVariable) MembraneSubDomain(cbit.vcell.math.MembraneSubDomain) CompartmentSubDomain(cbit.vcell.math.CompartmentSubDomain) FilamentSubDomain(cbit.vcell.math.FilamentSubDomain) PointSubDomain(cbit.vcell.math.PointSubDomain) Domain(cbit.vcell.math.Variable.Domain)

Example 43 with Domain

use of cbit.vcell.math.Variable.Domain in project vcell by virtualcell.

the class XmlReader method getPointVariable.

private PointVariable getPointVariable(Element param) {
    String name = unMangle(param.getAttributeValue(XMLTags.NameAttrTag));
    String domainStr = unMangle(param.getAttributeValue(XMLTags.DomainAttrTag));
    Domain domain = null;
    if (domainStr != null) {
        domain = new Domain(domainStr);
    }
    // Create new memVariable
    PointVariable pointVariable = new PointVariable(name, domain);
    transcribeComments(param, pointVariable);
    return pointVariable;
}
Also used : PointVariable(cbit.vcell.math.PointVariable) MembraneSubDomain(cbit.vcell.math.MembraneSubDomain) CompartmentSubDomain(cbit.vcell.math.CompartmentSubDomain) FilamentSubDomain(cbit.vcell.math.FilamentSubDomain) PointSubDomain(cbit.vcell.math.PointSubDomain) Domain(cbit.vcell.math.Variable.Domain)

Example 44 with Domain

use of cbit.vcell.math.Variable.Domain in project vcell by virtualcell.

the class XmlReader method getRandomVariable.

private RandomVariable getRandomVariable(Element param) throws XmlParseException {
    // get attributes
    String name = unMangle(param.getAttributeValue(XMLTags.NameAttrTag));
    Element element = param.getChild(XMLTags.RandomVariableSeedTag, vcNamespace);
    Expression seed = null;
    if (element != null) {
        seed = unMangleExpression(element.getText());
    }
    Distribution dist = null;
    element = param.getChild(XMLTags.UniformDistributionTag, vcNamespace);
    if (element != null) {
        dist = getUniformDistribution(element);
    }
    element = param.getChild(XMLTags.GaussianDistributionTag, vcNamespace);
    if (element != null) {
        dist = getGaussianDistribution(element);
    }
    String domainStr = unMangle(param.getAttributeValue(XMLTags.DomainAttrTag));
    Domain domain = null;
    if (domainStr != null) {
        domain = new Domain(domainStr);
    }
    RandomVariable var = null;
    if (param.getName().equals(XMLTags.VolumeRandomVariableTag)) {
        var = new VolumeRandomVariable(name, seed, dist, domain);
    } else if (param.getName().equals(XMLTags.MembraneRandomVariableTag)) {
        var = new MembraneRandomVariable(name, seed, dist, domain);
    } else {
        throw new XmlParseException(param.getName() + " is not supported!");
    }
    transcribeComments(param, var);
    return var;
}
Also used : Expression(cbit.vcell.parser.Expression) Element(org.jdom.Element) UniformDistribution(cbit.vcell.math.UniformDistribution) Distribution(cbit.vcell.math.Distribution) GaussianDistribution(cbit.vcell.math.GaussianDistribution) VolumeRandomVariable(cbit.vcell.math.VolumeRandomVariable) MembraneRandomVariable(cbit.vcell.math.MembraneRandomVariable) RandomVariable(cbit.vcell.math.RandomVariable) VolumeRandomVariable(cbit.vcell.math.VolumeRandomVariable) MembraneRandomVariable(cbit.vcell.math.MembraneRandomVariable) MembraneSubDomain(cbit.vcell.math.MembraneSubDomain) CompartmentSubDomain(cbit.vcell.math.CompartmentSubDomain) FilamentSubDomain(cbit.vcell.math.FilamentSubDomain) PointSubDomain(cbit.vcell.math.PointSubDomain) Domain(cbit.vcell.math.Variable.Domain)

Example 45 with Domain

use of cbit.vcell.math.Variable.Domain in project vcell by virtualcell.

the class XmlReader method getVolVariable.

/**
 * This method returns a VolVariable object from a XML Element.
 * Creation date: (5/16/2001 2:56:34 PM)
 * @return cbit.vcell.math.VolVariable
 * @param param org.jdom.Element
 */
private VolVariable getVolVariable(Element param) {
    String name = unMangle(param.getAttributeValue(XMLTags.NameAttrTag));
    String domainStr = unMangle(param.getAttributeValue(XMLTags.DomainAttrTag));
    Domain domain = null;
    if (domainStr != null) {
        domain = new Domain(domainStr);
    }
    // -- create new VolVariable object
    VolVariable volVariable = new VolVariable(name, domain);
    transcribeComments(param, volVariable);
    return volVariable;
}
Also used : StochVolVariable(cbit.vcell.math.StochVolVariable) VolVariable(cbit.vcell.math.VolVariable) MembraneSubDomain(cbit.vcell.math.MembraneSubDomain) CompartmentSubDomain(cbit.vcell.math.CompartmentSubDomain) FilamentSubDomain(cbit.vcell.math.FilamentSubDomain) PointSubDomain(cbit.vcell.math.PointSubDomain) Domain(cbit.vcell.math.Variable.Domain)

Aggregations

Domain (cbit.vcell.math.Variable.Domain)54 CompartmentSubDomain (cbit.vcell.math.CompartmentSubDomain)35 Expression (cbit.vcell.parser.Expression)34 MembraneSubDomain (cbit.vcell.math.MembraneSubDomain)28 PointSubDomain (cbit.vcell.math.PointSubDomain)22 FilamentSubDomain (cbit.vcell.math.FilamentSubDomain)19 VolVariable (cbit.vcell.math.VolVariable)15 ExpressionException (cbit.vcell.parser.ExpressionException)14 Function (cbit.vcell.math.Function)13 SubDomain (cbit.vcell.math.SubDomain)13 Variable (cbit.vcell.math.Variable)13 AnnotatedFunction (cbit.vcell.solver.AnnotatedFunction)10 Element (org.jdom.Element)10 Constant (cbit.vcell.math.Constant)9 MemVariable (cbit.vcell.math.MemVariable)9 VariableHash (cbit.vcell.math.VariableHash)9 VariableType (cbit.vcell.math.VariableType)9 VolumeRegionVariable (cbit.vcell.math.VolumeRegionVariable)8 GeometryClass (cbit.vcell.geometry.GeometryClass)7 SubVolume (cbit.vcell.geometry.SubVolume)7