Skip to Main Content Skip to Search
Product Documentation

SolverType - Select solver type for simulation

Description

The SolverType property lets you specify the solver to use for a simulation. For a discussion about solver types, see Choosing a Simulation Solver in the SimBiology User's Guide documentation.

Changing the solver type changes the options (properties) specified in the SolverOptions property of the configset object. If you change any SolverOptions, these changes are persistent when you switch SolverType. For example, if you set the ErrorTolerance for the expltau solver and then change to impltau when you switch back to expltau, the ErrorTolerance will have the value you assigned.

Characteristics

Applies toObject: Configset
Data typeenum
Data values'ode15s', 'ode23t', 'ode45', 'sundials', 'ssa', 'expltau', 'impltau'. Default is 'ode15s'.

    Note   If your model contains events, you cannot specify 'expltau' or 'impltau' for the SolverType property.

    Note   If your model contains doses, you cannot specify 'ssa', 'expltau', or 'impltau' for the SolverType property.

AccessRead/write

Examples

  1. Retrieve the configset object from the modelObj.

    modelObj  = sbiomodel('cell');
    configsetObj = getconfigset(modelObj)
    
    
    Configuration Settings - default (active)
         SolverType:                  ode15s
         StopTime:                    10.000000
    
       SolverOptions:
         AbsoluteTolerance:           1.000000e-006
         RelativeTolerance:           1.000000e-003
         SensitivityAnalysis:         false
    
       RuntimeOptions:
         StatesToLog:                 all
    
       CompileOptions:
         UnitConversion:              false
         DimensionalAnalysis:         true
    
       SensitivityAnalysisOptions:
         Inputs:                      0
         Outputs:                     0
  2. Configure the SolverType to ode45.

    set(configsetObj, 'SolverType', 'ode45')
    configsetObj
    
       Configuration Settings - default (active)
         SolverType:                  ode45
         StopTime:                    10.000000
    
       SolverOptions:
         AbsoluteTolerance:           1.000000e-006
         RelativeTolerance:           1.000000e-003
         SensitivityAnalysis:         false
    
       RuntimeOptions:
         StatesToLog:                 all
    
       CompileOptions:
         UnitConversion:              false
         DimensionalAnalysis:         true
    
       SensitivityAnalysisOptions:
         Inputs:                      0
         Outputs:                     0

See Also

getconfigset, set

  


Free Computational Biology Interactive Kit

See how to analyze, visualize, and model biological data and systems using MathWorks products.

Get free kit

Trials Available

Try the latest computational biology products.

Get trial software
 © 1984-2012- The MathWorks, Inc.    -   Site Help   -   Patents   -   Trademarks   -   Privacy Policy   -   Preventing Piracy   -   RSS