search for: log1ab

Displaying 4 results from an estimated 4 matches for "log1ab".

2017 Jun 18
3
R_using non linear regression with constraints
...geom_point( x=objdtassmin$a , y=objdtassmin$b , colour="green" ) + scale_fill_continuous( name="SumSq", breaks = brks ) # Green point is brute-force solution # Red point is optimizer solution for myfun ############## myfun2 <- function( a, log1ab, r, t ) { ab <- 1000 - exp( log1ab ) ab * ( 1 - exp( -ab/a * r * t ) ) } objdta$log1ab <- with( objdta, log( 1000 - a * b ) ) objdta$myfun2 <- with( objdta , myfun2( a = a , log1ab = log1ab , r = 2...
2017 Jun 18
0
R_using non linear regression with constraints
..., y=objdtassmin$b > , colour="green" ) + > scale_fill_continuous( name="SumSq", breaks = brks ) > # Green point is brute-force solution > # Red point is optimizer solution for myfun > > ############## > > myfun2 <- function( a, log1ab, r, t ) { > ab <- 1000 - exp( log1ab ) > ab * ( 1 - exp( -ab/a * r * t ) ) > } > > objdta$log1ab <- with( objdta, log( 1000 - a * b ) ) > objdta$myfun2 <- with( objdta > , myfun2( a = a > , log1ab = log1ab &...
2017 Jun 18
0
R_using non linear regression with constraints
I ran the following script. I satisfied the constraint by making a*b a single parameter, which isn't always possible. I also ran nlxb() from nlsr package, and this gives singular values of the Jacobian. In the unconstrained case, the svs are pretty awful, and I wouldn't trust the results as a model, though the minimum is probably OK. The constrained result has a much larger sum of squares.
2017 Jun 18
3
R_using non linear regression with constraints
https://cran.r-project.org/web/views/Optimization.html (Cran's optimization task view -- as always, you should search before posting) In general, nonlinear optimization with nonlinear constraints is hard, and the strategy used here (multiplying by a*b < 1000) may not work -- it introduces a discontinuity into the objective function, so gradient based methods may in particular be