Question

How to use lsqcurvefit to estimate parameters while using fsolve to solve an equation

Hi ebveryone, On the attached code I am trying to use lsqcurvefit to estimate the following constants: % Constants KSO2 = ...

7 mois ago | 1 answer | 0

Question

How can I write iterated data from a for-loop into excel file

Hi everyone, On the attached file I am trying to write iterated data into an excel file. The 'witing' works well for the firs...

7 mois ago | 0 answers | 0

Question

Why does odeset RelTol and AbsTol values truncate the results?

Hi everyone, On the attached code, I am trying to use odeset to smoothen the result. When I use 'RelTol' of 1e-2 and 'AbsTol' o...

7 mois ago | 0 answers | 0

Question

Why does matlab request me to define a for-loop indexing term?

Hi everyone, I am trying to run the attached code, but matlab gives this error: Undefined function or variable 'k'. Error...

7 mois ago | 1 answer | 0

Question

How can I use for loop to input values when solving ODEs using ode45?

Hi everyone On the attached code, I am trying to use a for loop to iteratively input values while solving ODEs using ode45. I t...

7 mois ago | 1 answer | 0

Question

Too many input arguments

Hi everyone, I know this is a self-explaining error. I know it is usually caused by: 1) Passing a function more input argume...

7 mois ago | 1 answer | 0

Question

Function value at starting guess must be finite and real

Hi everyone, I know that the question is self-explaning. I am supriced that I get this error: Error using fzero (line 328)...

7 mois ago | 1 answer | 0

Question

How can I prevent an infinite recursion within my program?

Hi Everyone, I am trying to run the code below, and I get very long error message stating: FZERO cannot continue because u...

8 mois ago | 1 answer | 0

Question

Why do I get an error message "Function value at starting guess must be finite and real." when my starting guess is 8?

Hi everyone, When I run the code given below, I get, I get the error message: Error using fzero (line 328) Function value a...

8 mois ago | 1 answer | 0

Question

What can I change on the code below to make it run faster?

Hello everyone, What can I change on the code below to make it run faster? function SlurryCaseODE45Jan31 function C...

8 mois ago | 1 answer | 0

Question

Why does a for-loop give different outputs when used in different scripts?

Hi everyone, I am trying to use a for-loop to get time that is spaced by 600 seconds for the first 4 steps, then spaced by 72...

8 mois ago | 0 answers | 0

Question

How to use fprintf

How can I use fprintf to print out NSO2; CSO2_bulkslurry; CHSO3; CSO3; CSO2_inter; ...

8 mois ago | 0 answers | 0

Question

Need a better guess y0 for consistent initial conditions.

Hi all, I get the the error message: Error using daeic12 (line 166) Need a better guess y0 for consistent initial conditi...

8 mois ago | 0 answers | 0

Question

Error using lsqcurvefit (line 262) Function value and YDATA sizes are not equal.

Hi all, I get the error message: Error using lsqcurvefit (line 262) Function value and YDATA sizes are not equal. Erro...

8 mois ago | 2 answers | 0

Question

Using lsqcurvefit to estimate parameters, while solving daes using ode15i

Hi all, I am trying to estimate 13 parameters using lsqcurvefit, while using ode15i to solve 4 daes. The attached script give...

8 mois ago | 0 answers | 0

Question

Using ode15s to solve daes and lsqcurvefit to fit a curve

Hello everyone, I am trying to use ode15s to solve 4 daes,and using lsqcurvefit to fit the curve. The attached code gives an ...

8 mois ago | 0 answers | 0

Question

Unable to perform assignment because the left and right sides have a different number of elements.

Hi all When I run the attached code, I get the error message: Unable to perform assignment because the left and right side...

8 mois ago | 0 answers | 0

Question

How can I increase the array elements of the optimization variable?

Hi all, I am trying to run a dynamic optimization script, and I get the error message: Index exceeds the number of array e...

8 mois ago | 0 answers | 0

Question

How can I resolve the Convergence failure in DECIC?

Hi everyone, I am trying to use ode15i to solve a system DAEs on the attached code. There seems to be a problem with my decic...

9 mois ago | 0 answers | 0

Question

Index exceeds the number of array elements (1)

Hi everyone, I am learning how to use lsqcurvefit when solving DAEs using a simple case on the attached code. At the moment I a...

9 mois ago | 0 answers | 0

Question

Why does lsqcurvefit runs forever?

Hi Everyone On the attached code, I am using lsqcurvefit for data-fitting. The code seems to run forever. I am on day 6 n...

9 mois ago | 0 answers | 0

Question

Why do I get an error stating "Matrix dimensions must agree", whilst the dimensions appear to be equal to me.

Hi everyone, I am runing the attached code, and for some reasons I get the error message stating: Matrix dimensions must a...

9 mois ago | 1 answer | 0

Question

Not enough input arguments.

Hi Everyone, I have a user-defined code that is based on Euler method, that runs successfully. However the output does not comp...

9 mois ago | 1 answer | 0

Question

Parameter estimation when using ODE15i

Hi everyone, I have an ODE15i code that runs successful. I have compared its results to the experimental results, the fitting i...

9 mois ago | 0 answers | 0

Question

Run a script 5 times whilst changing the value of one parameter each time.

Hi everyone I would like to run the attached script 5 times whilst changing the value of kga from 4e-1 to 4e-2, then 4e-3, then...

9 mois ago | 0 answers | 0

Question

Estimation of parameters for curvefit using lsqcurvefit

Hi everyone, On the attached script I am trying to use lsqcurvefit to estimate parameters x(1), x(2), x(3), x(4), x(5) and x(...

10 mois ago | 1 answer | 0

Question

Too many input arguments, which arguments should I remove?

Hi all, on the attached code, I am trying to use a for-loop and ode45 to solve odes and an algebraic equation in 31 iterations. ...

11 mois ago | 1 answer | 0

Question

Index exceeds the number of array elements (1)

Hi everyone, I know this error is self-explanatory. In line 34 of the attached code, I indexed to the end of the independent var...

11 mois ago | 1 answer | 0

Question

Why does my for-loop substitute only one value throughout 31 iterations?

Hi all, on the attached file, I am trying to use the for-loop to substitute values for every iteration. However, it seems like ...

11 mois ago | 1 answer | 0

Question

How can I fit data to a curve that is only defined implicitly

Hello everyone, I am learning how to fit data to a curve that is only defined implicitly. For practice, I am using the function ...

11 mois ago | 0 answers | 0