Questions tagged [minimization]

Minimization is a subclass of mathematical optimization where given a cost or objective function, the goal is to choose the best set of parameters that will minimize the value given by this function.

529 questions
1
vote
1 answer

minimizing boolean function heuristic for A* algorithm

I have to write a program in python which minimizes a boolean function, but the catch is that I have to use search algorithms for example A* or simpler algorithm BFS or something like that. I wrote a program using Iterative deepening, it solves…
1
vote
1 answer

Find best minima for initial conditions for past solution to match present values known

I have in Python an ODE system to solve and it is splitted in 2 parts : a past time solution and a future time solution : Here is the ODE system : # defining system def sys_to_solve(t, funcs): return [ funcs[0] * funcs[1], ( …
1
vote
1 answer

JAX code for minimizing Lennard-Jones potential for 2 points in Python gives unexpected results

I am trying to practice using JAX fo optimization problem and I am trying to do a simple problem, which is to minimize Lennard-Jones potential for just 2 points and I set both epsilon and sigma in Lennard-Jones potential equal 1, so the potential is…
1
vote
0 answers

Julia, optim.jl fails to converge, residual function

I'm currently attempting to minimize a function in Julia using the Optim.jl library. However, I'm facing some difficulties as I'm unable to obtain the desired results for some unknown reason Optim.jl fails to converge to the correct solution. Here's…
1
vote
1 answer

Optimizing a funcation using Scipy to estimate fitting parameters

I am trying to optimize a function by finding its minimum value using Scipy. The code must find the values of the variables g and tau that will give the minimum value of MSE. However, These values must be arrays not scalars. Below is the code import…
1
vote
0 answers

Minimization passing a nasty Jacobian. Is it a convenient move?

Imagine I want to minimize a function F with scipy.optimize.minimize (Python). F is quite cumbersome, the jacobian J can be computed analytically but its expression is extremely nasty (lengthy). My question is: is it always best to pass J to…
IgnoranteX
  • 11
  • 3
1
vote
1 answer

Differences in the standard error of parameters computed via the hessian inverse and via QR decomposition

I have solved a nonlinear optimization and I am trying to compute the standard error of the parameters obtained. I found two options: One uses the fractional covariance matrix formed from the inverse of the hessian while the other uses QR…
richinex
  • 365
  • 3
  • 10
1
vote
2 answers

Minimum number of operations to make two arrays equal

Given 2 arrays of integers, A and B, an operation on array B is defined as follows: B[i] = B[i]+2 and B[j] = B[j]-2, where i != j i and j can be any indices and the above operation can be performed any number of times such that i and j are not…
1
vote
4 answers

Algorithm to do Minimization in Integer Programming

I understand that doing minimization in integer programming is a very complex problem. But what makes this problem so difficult? If I were to (attempt) to write an algorithm to solve it, what would I need to take into account? I'm only familiar…
jmnwong
  • 1,577
  • 6
  • 22
  • 33
1
vote
1 answer

Task assignment to least possible people

In a given hour, I have a set of tasks that need to be completed and the time it takes for completion of each. This could be, for example: Task Time to complete (hrs) A 0.2 B 0.25 C 0.1 D 0.5 E 0.5 F 0.5 Assume I have infinite…
Elis
  • 70
  • 10
1
vote
1 answer

Using BigM equations to minimize a variable

I am trying to minimize the following equation: P_ch_max = min(22, E_need*m_int) where E_need*m_int can be bigger or lower than 22 depending on the data. I am using the following equations in pyomo to do it: m.C6 = ConstraintList() for t in m.ts2: …
1
vote
2 answers

How to estimate the correlation between two functions with unknown variables inside?

I need to solve this optimization problem in order to estimate lambda: Basically, I need to find the correlation between these two functions: f1 <- function(lambda, tau){slope = (1-exp(-lambda*tau))/(lambda*tau) return(slope)} f2…
1
vote
1 answer

Scipy optimise minimize

I am trying to solve the optimization problem with 4 variables. I have to give constraint in the scipy.optimize, the constraint is x[1] < x[2] < x[3] < x[4]. Is there any methodology to solve this problem in scipy.optimise
1
vote
1 answer

SciPy minimization of a SimPy simulation says 'Inequality constraints incompatible' when using only an eq constraint

So I'm trying to maximize the output of a queue chain, and after building the whole simulation I applied the "- minimization" approach. The code does run, but when I check the results, all I see is fun: -76.0 jac: array([2.68435456e+08,…
user18368547
1
vote
2 answers

Integer Programming - If then statement

I am new to linear/integer programming and I am having a hard time formulating constraints for a specific if-then statement in a fixed charge problem. Suppose that there are five manufacturers of t-shirts, and a customer wishes to purchase 400…