# Defining objective functions appropriately

7 visualizaciones (últimos 30 días)
okoth ochola el 2 de Feb. de 2023
Comentada: Torsten el 3 de Feb. de 2023
Hi community, I previously asked about grey wolf optimizer and the guidance I got was much helpful,am eternally grateful for you all. I wanted to use the code to estimate Weibull parameters. I have a slight problem, when defining weibull function, do we consider it as maximization problem or minimization problem? Being that my objecive function has to be Weibull function. I will appreciate any clue or any help.
##### 0 comentariosMostrar -2 comentarios más antiguosOcultar -2 comentarios más antiguos

Iniciar sesión para comentar.

Matt J el 2 de Feb. de 2023
Editada: Matt J el 2 de Feb. de 2023
It depends what environment you are formulating the problem in. fmincon and fminunc will only minimize functions, so you cannot present the problem to them as a maximization. However, if you set up the problem with optimproblem(), then it allows you to specify through ObjectiveSense whether you are minimizing or maximizing,
##### 0 comentariosMostrar -2 comentarios más antiguosOcultar -2 comentarios más antiguos

Iniciar sesión para comentar.

### Más respuestas (1)

Torsten el 2 de Feb. de 2023
Usually, you maximize the corresponding log-likelihood function. So it's a maximization problem.
To maximize, use one of MATLAB's optimizers. Instead of maximizing f, you can then minimize -f so that every optimizer in MATLAB can also be used as a maximizer.
##### 4 comentariosMostrar 2 comentarios más antiguosOcultar 2 comentarios más antiguos
okoth ochola el 3 de Feb. de 2023
Thank you @Torsten, It's because am fairly new to parameter estimation techniques using metaheuristics algorithms. That is why I can be so annoying with my questions. However, your response opened my eyes and I think have gotten the lead on what to do. I knew about the inbuilt mle() for parameter estimation, but the resaerch am doing requires me to obtain the parameters using grey wolf, then compare with the results of mle().
Torsten el 3 de Feb. de 2023
but the resaerch am doing requires me to obtain the parameters using grey wolf, then compare with the results of mle().

Iniciar sesión para comentar.

### Categorías

Más información sobre Weibull Distribution en Help Center y File Exchange.

### Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by