This is a simple problem. Normaly I use two for-loops in GNU Octave to find the parameter $a$ and $b$ and $K$.

The cost function I'm going to minimize is:

$V=\sum _{i=0}^{N}(|{u}_{i}-K-{u}_{0}{a}^{-b{t}_{i}}|)$

Where ${u}_{i}$ is a vector for measurement and ${t}_{i}$ is also a measured vector. ${u}_{0}$ is known so only $a$,$b$,$K$ is unknow.

Is there any other way to minimize $V$ instead of using three for-loops in GNU Octave?

In my case, two-variables can solve the problem too. The $K$ is just a correction factor. Not necessary to 100%.

The cost function I'm going to minimize is:

$V=\sum _{i=0}^{N}(|{u}_{i}-K-{u}_{0}{a}^{-b{t}_{i}}|)$

Where ${u}_{i}$ is a vector for measurement and ${t}_{i}$ is also a measured vector. ${u}_{0}$ is known so only $a$,$b$,$K$ is unknow.

Is there any other way to minimize $V$ instead of using three for-loops in GNU Octave?

In my case, two-variables can solve the problem too. The $K$ is just a correction factor. Not necessary to 100%.