Contenido principal

Resultados de

We are often asked to help with parameter estimation problems. This discussion aims to provide guidance for parameter estimation, as well as troubleshooting some of the more common failure modes. We welcome your thoughts and advice in the comments below.

Guidance and Best Practices:

1. Make sure your data is formatted correctly. Your data should have:

  • a time column (defined as independent variable) that is monotonically increasing within every grouping variable,
  • one or more concentration columns (dependent variable),
  • one or more dose columns (with associated rate, if applicable) if you want your model to be perturbed by doses,
  • a column with a grouping variable is optional.

Note: the dose column should only have entries at time points where a dose is administered. At time points where the dose is not administered, there should be no entry. When importing your data, MATLAB/SimBiology will replace empty cells with NaNs. Similarly, the concentration column should only have entries where measurements have been acquired and should be left empty otherwise.

If you import your data first in MATLAB, you can manipulate your data into the right format using datatype ' table ' and its methods such as sortrows , join , innerjoin , outerjoin , stack and unstack . You can then add the data to SimBiology by using the 'Import data from MATLAB workspace' functionality.

2. Visually inspect data and model response. Create a simulation task in the SimBiology desktop where you plot your data ( plot external data ), together with your model response. You can create sliders for the parameters you are trying to estimate (or use group simulation). You can then see whether, by varying these parameter values, you can bring the model response in line with your data, while at the same time giving you good initial estimates for those parameters. This plot can also indicate whether units might cause a discrepancy between your simulations and data, and/or whether doses administered to the model are configured correctly and result in a model response.

3. Determine sensitivity of your model response to model parameters. The previous section can be considered a manual sensitivity analysis. There is also a more systematic way of performing such an analysis: a global or local sensitivity analysis can be used to determine how sensitive your responses are to the parameters you are trying to estimate. If a model is not sensitive to a parameter, the parameter’s value may change significantly but this does not lead to a significant change in the model response. As a result, the value of the objective function is not sensitive to changes in that parameter value, hindering estimating the parameter’s value effectively.

4. Choose an optimization algorithm. SimBiology supports a range of optimization algorithms, depending on the toolboxes you have installed. As a default, we would recommend using lsqnonlin if you have access to the Optimization Toolbox. See troubleshooting below for more considerations choosing an appropriate optimization algorithm.

5. Map your data to your model components: Make sure the columns for your dependent variable(s) and dose(s) are mapped to the corresponding component(s) in your model.

6. Start small: bring the estimation task down to the smallest meaningful objective. If you want to estimate 10 parameters, try to start with estimating one or two instead. This will make troubleshooting easier. Once your estimation is set up properly with a few parameters, you can increase the number of parameters.

Troubleshooting

1. Are you trying to estimate a parameter that is governed by a rule? You can’t estimate parameters that are the subject of a rule (initial/repeated assignment, algebraic rule, rate rule), as the rule would supersede the value of the parameter you are trying to estimate. See this topic.

2. Is the optimization using the correct initial conditions and parameter values? Check whether - for the fit task - the parameter values and initial conditions that are used for the model, make sense. You can do this by passing the relevant dose(s) and variant(s) to the getequations function. In the SimBiology App, you can look at your equation view (When you have your model open, in the Model Tab, click Open -> Equations). Subsequently, - in the Model tab - click "Show Tasks" and select your fit task and inspect the initial conditions for your parameters and species. A typical example of this is when you do a dosing species but ka (the absorption rate) is set to zero. In that case, your dose will not transfer into the model and you will not see a model response.

3. Are your units consistent between your data and your model? You can use unit conversion to automatically achieve this.

4. Have you checked your solver tolerances? The absolute and relative tolerance of your solver determine how accurate your model simulation is. If a state in your model is on the order of 1e-9 but your tolerances only allow you to calculate this state with an accuracy down to 1e-8, your state will practically represent a random error around 1e-8. This is especially relevant if your data is on an order that is lower than your solver tolerances. In that case, your objective function will only pick up the solver error, rather than the true model response and will not be able to effectively estimate parameters. When you plot your data and model response together and by using a log-scale on the y-axis (right-click on your Live plot, select Properties, select Axes Properties, select Log scale under “Y-axis”) you can also see whether your ODE solver tolerances are sufficiently small to accurately compute model responses at the order of magnitude of your data. A give-away that this is not the case is when your model response appears to randomly vary as it bottoms-out around absolute solver tolerance.

_ Tolerances are too low to simulate at the order of magnitude of the data. Absolute Tolerance: 0.001, Relative Tolerance: 0.01_

_ Sufficiently high tolerances. Absolute Tolerance: 1e-8, Relative Tolerance: 1e-5_

5. Have you checked the tolerances and stopping criteria of your optimization algorithm? The goal for your optimization should be that it terminates because it meets the imposed tolerances rather than because it exceeds the maximum number of iterations. Optimization algorithms terminate the estimation based on tolerances and stopping criteria. An example of a tolerance here is that you specify the precision with which you want to estimate a certain parameter, e.g. Cl with a precision down to 0.1 ml/hour. If these tolerances and stopping criteria are not set properly, your optimization could terminate early (leading to loss of precision in the estimation) or late (leading to unnecessarily long optimization compute times).

6. Have you considered structural and practical identifiability of your parameters? In your model, there might exist values for two (or more) parameters that result in a very similar model response. When estimating these parameters, the objective function will be very similar for these two parameters, resulting in the optimization algorithm not being able to find a unique set of parameter estimates. This effect is sometimes called aliasing and is a structural identifiability problem. An example would be if you have parallel enzymatic (Km, Vm) and linear clearance (Cl) routes. Practical identifiability occurs when there is not enough data available to sufficiently constrain the parameters you are estimating. An example is estimating the intercompartmental clearance (Q12), when you only have data on the central compartment of a two-compartment model. Another example would be that your data does not capture the process you are trying to estimate, e.g. you don’t have data on the absorption phase but are trying to estimate the absorption constant (Ka).

7. Have you considered trying another optimization algorithm? SimBiology supports a range of optimization algorithms, depending on the toolboxes you have installed. There is no single answer as to which algorithm you should use but some general guidelines can help in selecting the best algorithm.

  • Non-linear regression: If your aim is to estimate parameters estimates for each group in your dataset (unpooled) or for all groups (pooled), you can use non-linear regression estimation methods. The optimization algorithms can be broken down into local and global optimization algorithms. You can use a local optimization algorithm when you have good initial estimates for the parameters you are trying to estimate. Each of the local optimization functions has a different default optimization algorithm: fminsearch (Nelder-Mead/downhill simplex search method), fmincon (interior-point), fminunc (quasi-newton), nlinfit (Levenberg-Marquardt), lsqcurvefit, lsqnonlin (both trust-region-reflective algorithm). As a default, we would recommend using lsqnonlin if you have access to the Optimization Toolbox. Note that all but the fminsearch algorithm are gradient based. If a gradient based algorithm fails to find suitable estimates, you can try fminsearch and see whether that improves the optimization. All local optimization algorithms can get “stuck” in a local minimum of the objective function and might therefore fail to reach the true minimum. Global optimization algorithms are developed to find the absolute minimum of the objective function. You can use global optimization algorithms when your fitting task results in different parameter estimates when repeated with different initial values (in other words, your optimization is getting stuck in local minima). You are more likely to encounter this as you increase the number of parameters you are estimating, as you increase the parameter space you are exploring (in other words, the bounds you are imposing on your estimates) and when you have poor initial estimates (in other words, your initial estimates are potentially very far from the estimates that correspond with the minimum of the objective function). A disadvantage of global optimization algorithms is that these algorithms are much more computationally expensive – they often take significantly more time to converge than the local optimization methods do. When using global optimization methods, we recommend using SimBiology’s built-in scattersearch algorithm, combined with lsqnonlin as a local solver. If you have access to the Global Optimization Toolbox, you can try the functions ga (genetic algorithm), patternsearch and particleswarm. Note that some of the global optimization algorithms, including scattersearch, lend themselves well to be accelerated using parallel or distributed computing.
  • Estimate category-specific parameters: If you want to estimate category-specific parameters for multiple subjects, e.g. you have 10 male and 10 female subjects in your dataset and you want to estimate a separate clearance value for each gender while all other parameters will be gender-independent, you can also use non-linear regression. Please refer to this example in the documentation.
  • Non-linear mixed effects: If your data represents a population of individuals where you think there could be significant inter-individual variability you can use mixed effects modeling to estimate the fixed and random effects present in your population, while also understanding covariance between different parameters you are trying to estimate. When performing mixed effects estimation, it is advisable to perform fixed effects estimation in order to obtain reasonable initial estimates for the mixed effects estimation. SimBiology supports two estimation functions: nlmefit (LME, RELME, FO or FOCE algorithms), and nlmefitsa (Stochastic Approximation Expectation-Maximization). Sometimes, these solvers might seem to struggle to converge. In that case, it is worthwhile determining whether your (objective) function tolerance is set too low and increasing the tolerance somewhat.

8. Does your optimization get stuck? Sometimes, the optimization algorithm can get stuck at a certain iteration. For a particular iteration, the parameter values that model is simulated with as part of the optimization process, can cause the model to be in a state where the ODE solver needs to take very small time-steps to achieve the tolerances (e.g. very rapid changes of model responses). Solutions can include: changing your initial estimates, imposing lower and upper bounds on the parameters you are trying to estimate, selecting to a different solver, easing solver tolerances (only where possible, see also “Visually inspect data and model response”).

9. Are you using the proportional error model? The objective function for the proportional error model contains a term where your response data is part of the denominator. As response variables get close to zero or are exactly zero, this effectively means the objective function contains one or more terms that divide by zero, causing errors or at least very slow iterations of your optimization algorithm. You can try to change the error model to constant or combined to circumvent this problem. Alternatively, you can define separate error models for each response: proportional for those responses that don’t have measurements that contain values close to zero and a constant error model for those responses that do.

Dear all,

I am new to SimBiology. I am doing my research in Molecular Communication. Recently I have found out that SimBiology can be used for simulating the Bit Error Rate performance of molecular Communication systems. Please help me to find good reference materials/examples for using SimBiology as a simulation tool for Molecular Communications.

Thank you.

Tomorrow (Wednesday, January 23) during Rosa's Impact of Modeling & Simulation in Drug Development webinar series, Chi-Chung Li, a Senior Scientist at Genentech, will present a case study where SimBiology was used to create a QSP model that enhanced decision making in a Phase I trial.

Sign up now and have the ability to ask questions at the end of the webinar, or access the archived version later: https://www.rosaandco.com/webinars/2019/phase-i-clinical-decision-making-qsp-case-study

Iraj Hosseini, Ph.D., of Genentech will present a webinar on gPKPDSim , a MATLAB app that facilitates non-modelers to explore and simulate PKPD models built in SimBiology.

While model development typically requires mathematical modeling expertise, model exploration and simulation could be performed by non-modeler scientists to support experimental studies. Dr. Hosseini and his colleagues collaborate with MathWorks' consulting services to develop an App to enable easy use of any model constructed in SimBiology to execute common PKPD analyses.

Webinar will be hosted by Rosa & Co. on Wednesday October 24. To register, go to: https://register.gotowebinar.com/register/7922912955745684993?mw

Fulden Buyukozturk
Fulden Buyukozturk
Última actividad el 11 de Jun. de 2020

This project presents a SimBiology implementation of Mager and Jusko’s generic Target-Mediated Drug Disposition model (TMDD) as described in "General pharmacokinetic model for drugs exhibiting target-mediated drug disposition". Target-mediated drug disposition is a common source of nonlinearity in PK profiles for biotherapeutics. Nonlinearities are introduced because drug-target bindings saturate at therapeutic dosing levels.

Drug in the Plasma reversibly binds with the unbound Target to form drug-target Complex. kon and koff are the association and dissociation rate constants, and clearance of free Drug and Complex from the Plasma is described by first-order processes with rate constants, kel and km, respectively. Free target turnover is described by a zero-order synthesis rate, ksyn, and a first order elimination (rate constant, kdeg). The model also includes an optional Tissue compartment to account for non-specific tissue binding or distribution.

References [1] Mager DE and Jusko WJ (2001) General pharmacokinetic model for drugs exhibiting target-mediated drug disposition. J Pharmacokinetics and Pharmacodynamics 28: 507–532.

Fulden Buyukozturk
Fulden Buyukozturk
Última actividad el 11 de Jun. de 2020

This project presents SimBiology model implementation of the systemic Renin-Angiotensin-System that was first developed by Lo et al. and used to investigate the effects of different RAS-modulating therapies. The RAS pathway is crucial for blood pressure and kidney function control as well as a range of other organism-wide functions. The model describes the enzymatic conversion of the precursor protein Angiotensinogen to Angiotensin I and its downstream products Angiotensin 1-7, Angiotensin II and Angiotensin IV. Key pathway effects are triggered by the association of Angiotensin II with the AT1-Receptor. A positive feedback loop connects the Angiotensin II–AT1-Receptor complex with the Angiotensinogen conversion (not shown in the diagram). Enzymatic reactions are modeled as pseudo-unimolecular using enzymatic activities as reaction rates. Degradation reactions are described using protein half-life times. Drug pharmacodynamics are included in the model using the term (1-DrugEffect), where DrugEffect follows a sigmoidal dependence on the Drug concentration, to modify the target enzyme activity.

References [1] Lo, A., Beh, J., Leon, H. D., Hallow, M. K., Ramakrishna, R., Rodrigo, M., & Sarkar, A. (2011). Using a Systems Biology Approach to Explore Hypotheses Underlying Clinical Diversity of the Renin Angiotensin System and the Response to Antihypertensive Therapies. Clinical Trial Simulations, 1, 457–482.

This project presents a SimBiology implementation of a physiologically-based pharmacokinetic (PBPK) model for trichloroethylene (TCE) and its metabolites. It is based on the article, “A human physiologically based pharmacokinetic model for trichloroethylene and its metabolites, trichloroacetic acid and free trichloroethanol” by Fisher et al. [1].

The human PBPK model for TCE and its metabolites presented here was developed by Fisher et al. [1] in order to assess human health risks associated with low level exposure to TCE. TCE is a commonly used solvent in the automotive and metal industries for vapor degreasing of metal parts. Exposure to TCE has been associated with toxic responses such as cancer formation and brain disorders in rodents and in humans [1]. In this PBPK model, TCE enters the systemic circulation through inhalation. Its disposition is described by a six-compartment model representing the liver, lung, kidney, fat, and slowly perfused and rapidly perfused tissues. In the liver, TCE is metabolized to trichloroacetic acid (TCA) and free trichloroethanol (TCOH-f) via P450-mediated metabolism where a fraction of TCOH-f is converted to TCA. For simplicity, a four-compartment submodel was used to describe the disposition of metabolites, TCA and TCOH-f, in the lung, liver, kidney, and body (muscle). Both metabolites are described to be excreted in the urine. TCOH-f is glucuronidated in the liver, forming glucuronide-bound TCOH (TCOH-b), and excreted in the urine via a saturable process whereas TCA is excreted by a first-order process by the kidney.

Reference: Fisher, J. W., Mahle, D., & Abbas, R. (1998). A human physiologically based pharmacokinetic model for trichloroethylene and its metabolites, trichloroacetic acid and free trichloroethanol. Toxicology and applied pharmacology, 152(2), 339-359.

By typing ver I can see which toolboxes I have:
MATLAB Version 9.3 (R2017b)
Simulink Version 9.0 (R2017b)
Computer Vision System Toolbox Version 8.0 (R2017b)
Control System Toolbox Version 10.3 (R2017b)
Curve Fitting Toolbox Version 3.5.6 (R2017b)
DSP System Toolbox Version 9.5 (R2017b)
GSW Oceanographic Toolbox Version 3.05.5 (R2012a)
Image Processing Toolbox Version 10.1 (R2017b)
MATLAB Report Generator Version 5.3 (R2017b)
Mapping Toolbox Version 4.5.1 (R2017b)
Optimization Toolbox Version 8.0 (R2017b)
Signal Processing Toolbox Version 7.5 (R2017b)
Statistics and Machine Learning Toolbox Version 11.2 (R2017b)
TopoToolbox Version 2.0 (R2012a)
Wavelet Toolbox Version 4.19 (R2017b)
The list above includes official MathWorks toolboxes and user-generated toolboxes (GSW Oceanographic Toolbox and TopoToolbox). How did GSW and TopoToolbox get on this list?
I have created and installed my own Climate Toolbox as a .prj & .mltbx pair, but my Climate Toolbox does not appear on the list. My toolbox does appear if I type
toolboxes = matlab.addons.toolbox.installedToolboxes
but other toolboxes I've installed do not appear using this command. If I go to the Add-Ons manager, I see my Climate Toolbox listed along with official Mathworks Toolboxes, and curiously also Scott Lowe's MATLAB Schemer, but is identified as a "Collection" rather than a toolbox.
Can anyone clearly define the taxonomy Toolboxes, Collections, Add-Ons, Apps, and Packages? Why do some toolboxes only show up with ver, while others only show up with matlab.addons.toolbox.installedToolboxes?
Dear MATLAB community,
How can I help my close friend who's bad at math and programming learn MATLAB?
He's a final year chemical engineering student who struggles even to plot two functions on the same graph in his computational fluid dynamics class (there was no prereq for matlab skills).
In his first year, I saw him get dragged through the introductory engineering classes which was his first encounter with MATLAB. Students were taught a few rudimentary programming skills and then were expected to make a code for a 'simple' tic-tac-toe game. It took him hours of blank looks and tutoring to even understand the simplest of boolean operators. He was never able to write a working function without the supervision of a friend or tutor. Needless to say, he was permanently scarred by the experience and swore to avoid using it forever.
After 3 years of avoiding MATLAB, he realised how not knowing it hurt him during his final year project. He had to solve a system of pdes to model the performance of a reactor and practically speaking, MATLAB was the most suitable software at hand. He ended up having to get a friend to help him code the equations in while also having to oversimplify his model.
The weird thing is that: most students from his chemical engineering faculty were not expected or encouraged to use MATLAB, almost all of their prior assignments required no use of MATLAB except that infamous first year course, and most of his peers also avoided using MATLAB and resorted to Excel. It is my understanding that Excel cannot match MATLAB's efficiency and clarity when solving calculus problems so it was not uncommon to see extremely long Excel spreadsheets.
Anyway, my friend is, with the help of a friend's past year MATLAB codes, trying to finish up his computational fluid dynamics assignment that's due soon. He finishes university in 2 weeks time.
Even though he knows that not every engineer has to use MATLAB in the workplace, he somehow wishes he was able to learn MATLAB at his glacial pace. I find it such a pity that he was never able to keep up with the pace of learning that was expected which begs the question: are students who are too slow at learning programming better of in a different field of study?
If you've managed to read to the end of this, thank you so much. I just don't know how to help my friend and I'm hoping some of you might be able to suggest how I can help him be better at it. I believe he has potential but needs special help when it comes to MATLAB.
All helpful and constructive suggestions considered,
Thank You All
Axel Nordin Fürdös
Axel Nordin Fürdös
Última actividad el 26 de Dic. de 2020

Hi there! This is kind of an unusual question, but here it goes. I am a big time Matlab enthusiast and I met some of your representatives at Formula Student Germany back in August. There was a booth were your product was showcased but most importantly there was Matlab merchandise such as stickers, rub-on-tattoos and pens with the mathworks logo being handed out. This merchandise is increadibly popular with me and my nerdy friends. But sadly I didnt bring much with me from the event. Is it possible to get ahold some of it? Is it for sale? Are you willing to sponsor some geeky engineering students?

I am new in MATLAB programming. I want to learn matlab . I want to know about is any matlab or simulink contest available. Please answer me. Thanks
Jan
Jan
Última actividad el 9 de Ag. de 2013

Some of Matlab's toolbox functions are affected by magic strings or magic numbers, which are strings or numbers with a deeper meaning besides the normal value. Both are considered as bad programming patters, because they provoke confusions, when the magic keys appear with the normal meaning by accident. See http://en.wikipedia.org/wiki/Anti-pattern
Example 1:
clear('myVariable')
clear('variables')
While the 1st clears the variable myVariable, the later clears all variables. Here 'variables' has a meta-meaning. The problem appears, when 'variables' is an existing variable:
a = 1;
variables = 2;
clear('variables')
disp(a) % >> 1
Only variables is cleared, which cannot be understood directly when its definition is 1000 lines before.
Example 2:
uicontrol('String', 'default')
This creates a button with the empty string '' instead of the expected 'default', because this is the magic string to invoke the default value get(0, 'DefaultUIControlString'). The same concerns properties of other graphic objects also, e.g. the 'name' property of figure or the string of uimenu. There is a workaround which allows the user to display 'default': Simply use '\default'. Unfortunately this is doubled magic, because in consequence it is impossible to display the string '\default'. Obviously a bad idea.
Example 3:
Graphic handles are doubles (although gobject of the new R2013a seems, like this is subject to changes? [EDITED: Yes, it changed with HG2 in R2014a]). But then a handle can be confused with data:
a = axes; % e.g. 0.0048828125
plot(a, 2, '+')
But you cannot draw the point [0.0048828125, 2] by this way, because the 1st input is considered as handle of the parent. Here all possible values of handles are magic. Collisions are very unlikely, but there is no way to avoid them reliably - as long as handles have the type double.
Question:
Which functions are concerned by magic values? What are the pitfalls and workarounds?
Matt Fig
Matt Fig
Última actividad el 23 de Feb. de 2023

I am wondering what others use for those little short-cuts or niceties in MATLAB. I have in mind something you wrote or something somebody else wrote or an underused MW function.
Here are my two favorites.
This is a simple script I use. Here is the entire contents of CLC.m (yes, it is capitalized):
clear all,close all,clc
Very simple, but I use it all the time. Here is another one I use so often that I forget not every machine has it (though every machine should, IMO):
Here is an underused MW function that I occasionally employ when working on someone else's machine. The usual response is, "Wait, what did you just do?"
home
What are some of yours?
Adam Kaas
Adam Kaas
Última actividad el 6 de Jun. de 2012

As I'm becoming more and more familiar with MATLAB, I'm starting to fall in love with it. I was wondering what are the coolest things that you all know MATLAB can do? As for me so far, the auto-code generation into another language is the coolest thing.
It is not uncommon for students to be assigned questions which they are required to complete "without using any built-in functions". There is not a great deal that can be programmed in MATLAB without using any built-in functions, but a little can be done -- but what, exactly is possible?
What a "built-in function" is, exactly, is open to interpretation. In the below, I refer instead to "publicly visible routines". Keywords (see below) are not publicly visible routines (they are "statements" or components of statements.) Any documented operation or call that invokes a MATLAB-supplied .m or .p or mex file or built-in library to do its work is a publicly visible routines. If you can use documented methods override the normal meaning of a statement or expression in practice by supplying alternate code, then the code probably involves publicly visible routines. If the language design is such that you could use documented methods to override the normal meaning of a statement or expression in theory (such as the behavior of adding two double, the code for which is in practice bundled into an internal MATLAB library), then I would still consider that a call to a publicly visible routine.
A MATLAB-supplied routine that is not documented, which is used for internal MATLAB purposes, could perhaps be held not to be a publicly visible routine, but it certainly would still be a "built-in function".
I exclude from the list any routine which there is no direct way to access, and is only used for internal purposes, such as the memory allocation routines.
This is what I have come up with:
  • the names defined as "keywords" do not in themselves involve function calls to publicly visible routines. These keywords currently include 'break', 'case', 'catch', 'classdef', 'continue', 'else', 'elseif', 'end', 'for', 'function', 'global', 'if', 'otherwise', 'parfor', 'persistent', 'return', 'spmd', 'switch', 'try', 'while'. There is no functional form of any of these: for example, one cannot use global(s) to declare the name contained in the variable "s" to be global. (However, you can define an "end" method; https://www.mathworks.com/help/matlab/matlab_oop/object-end-indexing.html )
  • scalar numeric double precision real-valued constants are handled at parse time, including unary plus and unary minus in front of them
  • scalar numeric double precision constants followed immediately by "i" or "j" create a complex-value constant at parse time, including unary plus and unary minus in front of them
  • whether a complete complex constant with real and imaginary part is handled at parse time is unknown
  • literal character vectors and string objects are handled at parse time
  • in sufficiently new versions, int64() and uint64() around an integer constant is handled at parse time. This was a change from previous versions which handled it at run time (after the integer had been converted to double precision...)
  • whether any other casts such as uint16() or logical() are now handled at parse time is unknown
  • assignment of a compete variable (no indexing, no substructure references, etc.) to a plain variable (no indexing, no substructure references, etc.) does not involve any function calls to publicly visible routines (unless I have overlooked a case involving objects)
  • "if" or "while" applied to a scalar logical constant or to a scalar logical variable does not involve any function calls to publicly visible routines. However, it is not known whether there is any method to construct a logical value without calling a MATLAB routine: "true" and "false" are MATLAB routines, not constants, and logical() of a numeric constant might be handled at run time
  • "for" in which the range is named as a scalar constant or scalar variable do not involve any function calls to publicly visible routines; for example, "for K = 5"
  • defining an anonymous function does not involve any function calls to publicly visible routines
I may have overlooked something due to shortage of chocolate in my bloodstream.
The language described above is not Turing complete, and is not "sufficiently powerful" for the purposes of the Church-Rosser Theorem of general-purpose computability. It is also not possible to do any arithmetic in it, as arithmetic must be reducible to the Peano Postulates, and those require at the very least the ability to compare a value for equality with 0, which in MATLAB would require a call to the MATLAB routine "eq".
Paulo Silva
Paulo Silva
Última actividad el 12 de Ag. de 2022

We all know that MATLAB is probably the best software for engineering purposes, I think it's a little expensive unless you have it for free on your school or place you work, please share your opinion about MATLAB cost, including toolboxes, student versions... is it that expensive?
Doug Hull
Doug Hull
Última actividad el 17 de Feb. de 2015

I think a lot about how to more effectively teach MATLAB, internally to new hires, but also through my blog.
How did you learn MATLAB, what knowledge of programming did you have coming into learning MATLAB? When did you learn it is important also as the resources available have expanded radically in the last 15 years.
Answers from new users who are just beginning down this path are of particular interest, as those are who we can help the most.
Don't be shy, what was your matlab learning curve, how many years or months, what were the difficulties to begin with.
I think that the answers would be most valuable for new users, maybe you can also tell us the tricks that allowed you to master some parts or all matlab.
Now it's your turn...