# Questions tagged [mathematical-optimization]

Questions on the optimization functions of Mathematica such as FindMinimum/FindMaximum, Minimize/Maximize, NMinimize/NMaximize, etc.

1,379 questions
Filter by
Sorted by
Tagged with
2k views

### ParallelEvaluate for function minimization

Is there a parallelized version of a minimization routine available in Mathematica? The objective function is non-linear and the gradients have to be numerically computed. Every function evaluation ...
168 views

### Minimum value with two factors

Approximate the minimum value of $2e^{x-2}-6x+xe^{x-2}$. Is my input correct? If not can you please correct it? ...
681 views

### Maximize over permutations

I have a set $S=\{s_1,\ldots,s_k\}$ and would like to maximize a fixed expression over permutations of $S$: $\max f(x_1,\ldots,x_k)$ with $x_i\in S$ and $x_i=x_j\Rightarrow i=j$. Is there a ...
1k views

I am trying to solve a (Sequence) Quadratic Programming (SQP) problem in Mathematica. Here’s the problem setup: ...
2k views

### Cannot find the maximum value of a function

Consider the following function: $a Sin(x)+b Cos(x)$ I tried to obtain the maximum value of this function using MaxValue[]: ...
168 views

### Function optimization errors

I have the following Mathematica code (Mathematica version 9): ...
847 views

### Is there any fast way to solve a quadratic matrix equation in Mathematica approximately?

Let the square nonsingular matrix $M$ is a given convergent matrix. What are the best scalar values for $\alpha$ and $\beta$ (in the real numbers domain), at which the following quadratic matrix ...
561 views

### Linear Integer Programming with absolute values in objective function

I'm trying to solve a problem of the form $$\left|a_{1,0}+a_{1,1} x_1 + a_{1,2}x_2\right| + \left|a_{2,0}+a_{2,1} x_1 + a_{2,2}x_2\right|\to\min,$$ where $a_{i,j}$ are real-valued coefficients and ...
215 views

### Constraint syntax compaction

Is there a more compact way to represent these constraints: NMaximize[{a+b+c,a <= 5 && b <= 5 && c <= 5...
2k views

### Packing squares into a circle

I am currently trying to solve and understand a problem about packing the maximum of squares into a circle. What I am trying to do, is to calculate the maximum number of variable sized squares (with ...
544 views

### A problem on generating convex hull

For example, I typed the following: ...
674 views

### NMaximize problem

Could anybody explain to me why the following code fails ? ...
389 views

### NMaximize and Conditional Loop

I have developed the following code that simulates a process that decays over time and then returns to its initial state periodically. When I pass a list of random integers in the interval $(1,0)$ as ...
925 views

658 views

### FindShortestTour for charity (or: How can I optimize meal delivery with FindShortestTour?)

I've been wondering about this for a while - but never got around to asking - until I saw faleichik's incredible answer to Mathematica Minecraft. I did some work at a not-for-profit a little while ...
235 views

### Trouble with Minimize

Minimize[{t^2, 1 == 3*t + 16*u}, {t, u}, Integers] It does not give the solution t = -5 and u = 1. Am I missing something? The solution being known and ...
241 views

### Feasibility of Linear Program

I have a set of (real) linear equations/inequalities and I want to know whether they have a solution, and to find at least one. The goal is to do this quickly. ...
246 views

### How to solve this simple equation?

I want to minimize a quadratic equation, but Mathematica does not solve it and only rewrites the solution. I wonder if there exist any way I can skip the computation by hand (I can solve it using ...
2k views

### using array elements in minimization

I have switched from mupad to Mathematica, however the syntax is completely different here. I want to ...
1k views

### Can I use GoogleMap or other GPS data in creation of the Graphs?

I have following graph. ...
137 views

### How can I say that all quantities need to be positive (and real)? [duplicate]

Can you say at the beginning of a script in Mathematica that you want all the quantities to be positive (and real)? So that in all calculations, only the real values of these quantities will be ...
5k views

### Using NonlinearModelFit to fit data with errors

Assume we have some data of measurements SeedRandom[9]; data = Table[{i,2*(1 + 5*RandomReal[])*Exp[-0.01*(1 + RandomReal[])*i]}, {i, {0, 100, 200, 400, 700}}]; ...
852 views

### Optimizing functions taking matrix arguments

I'm looking for general information on how to optimize matrix valued functions, I have the following function I'm looking to maximize (or figure out if this is possible at all). ...
471 views