Displaying 4 results from an estimated 4 matches for "nlopt_ln_cobyla".
2013 Feb 15
1
minimizing a numerical integration
...n( )
}
# objective function
eval_f0 <- function(x) {
romberg(f, 0.5, 0.5001)}
ARL1 <- nloptr( x0=c(0.653),
eval_f=eval_f0,
lb = c(0),
ub = c(6),
eval_g_ineq = eval_g0,
opts = list("algorithm"="NLOPT_LN_COBYLA", "maxeval"=1000),
)
print( )
Thanks
[[alternative HTML version deleted]]
2013 Feb 18
2
error: Error in if (is.na(f0$objective)) { : argument is of length zero
...21%*%y1)-500)-1)
}
eval_f0 <- function(x) romberg(function(s) f(x, s), 0, 6)
of <- nloptr( x0=c(0.653,0.09),
eval_f=eval_f0,
lb = c(0,0),
ub = c(6,1),
eval_g_ineq = eval_g0,
opts = list("algorithm"="NLOPT_LN_COBYLA", "maxeval"=1000),
)
print(of)
Regards,
Aya
[[alternative HTML version deleted]]
2013 Feb 27
0
A program running for a too long time
...rg(function(y) ((1+y*y)*f(x,y)/6),0,6, tol =
.Machine$double.eps^(2/3))$value
obj <- nloptr( x0=c(0.653,0.09),
eval_f=eval_f0,
lb = c(0,0),
ub = c(6,1),
eval_g_ineq = eval_g0,
opts = list("algorithm"="NLOPT_LN_COBYLA", "maxeval"=600))
obj(ARL1)
Thanks,
Emara
[[alternative HTML version deleted]]
2013 Jul 02
0
Optimización MINLP
...; x_i < b_i
y
\sum f(x_i) < Presupuesto
Vamos, es repartir un presupuesto forzando a que inviertas como poco a_i y
como mucho b_i para cada i
Esto lo hecho correctamente usando el paquete:
http://cran.r-project.org/web/packages/nloptr/index.html
Uso un algoritmo que no necesita gradiente: NLOPT_LN_COBYLA
(Aunque el gradiente se podría calcular, es fácil)
Ahora bien,
Quiero hacer una variación de este problema incluyendo que x_i pueda ser
cero (no se invierte en i) o si es mayor que cero ya tenga que ser como
mínimo a_i y como máximo b_i
Esto lo he puesto de la siguiente manera:
\sum w_i * f(x_...