Hey hi,

I am a new user of CADET, and I want to learn how to estimate parameters of the model by inverse fitting, so i am trying it with singleGRM on the breakthrough curve. I am getting the following error.

I have attached .m file for reference. Can you please suggest the way.

Thank you.

BTfitting.m (4.9 KB)

BTfitting

Error using MexSimulator/setParameters (line 718)

Expected valid parameters, but parameter 1 is invalid or does not exist.

Error in BTfitting (line 12)

sim.setParameters(params, true(4, 1));

Solved the above issue, but not getting the correct values of parameters.

Is there a need to change tolerance. Can you suggest what should be a way to get the correct values of parameters after a fit?

Thank you.

BTfitting

```
Norm of First-order
```

Iteration Func-count f(x) step optimality

0 1 0.000254756 0

Initial point is a local minimum.

Optimization completed because the size of the gradient at the initial point

is less than the selected value of the optimality tolerance.

optimalParams =

1.0e-05 *

```
0.0032 0.0000 0.0000 0.1550
```

Hi Prashant,

I’ve fixed the file you provided.

- The parameters were not correct (the component index for the axial dispersion should be -1 but needs to be 0 for this model with one component).
- The parameter fit starts with the true values. The optimizer has nothing to do because the residual is bascially
`0`

. So I’ve perturbed the values slightly to get the optimizer to do something.
- When analyzing real data, you should ramp up the discretization. Using only 16 axial cells adds a lot of numerical dispersion.

Please open a public thread so that others can also benefit from the discussion.

BTfitting2.m (4.9 KB)

1 Like

Thank you so much, Samuel.

Actually, i want to ask is there any option in forum to open this discussion thread in public or i need to ask the same question under CADET troubleshooting topic.

Thank you.

I’ve moved this topic to the CADET Troubleshooting category.

1 Like