# Questions tagged [mathematical-optimization]

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

1,376 questions
Filter by
Sorted by
Tagged with
366 views

55 views

### Optimizing a nested function in mathematica getting stuck at local maximum and giving wrong answer

I am trying to maximize this function over the value "p": ...
37 views

### Nested maximum function not working

I am trying to maximize a function which is itself a maximized function. For example, see the below. Can someone explain this error: ...
39 views

### ArgMax problem with Piecewise function

I'm having an issue with finding the maximizer of a very simple piecewise function. ...
45 views

### How to solve an optimization problem with multiple constraints? [closed]

I would like to minimize a function in four variables with respect to multiple constraints. $a+b+c+d\leq 1$ and $a, b, c, d \geq 0$, i.e. minimizing on the unit simplex in 4D. How do I incorporate ...
54 views

### Maximizing Output from ParametricNDSolve [closed]

Given a system of differential equations that are dependent on two parameters, such as the system below (the equation below is not that important, I am interested in a general procedure given a ...
57 views

### Multiple agents routing optimisation problem

We are given an array of nodes of the form {{xcoordinate,ycoordinate}, weight, "name"}. This represents nodes on a 2D euclidean coordinate system. Further, we are given a number n which is the number ...
480 views

### How to make the computation of a minimum efficient?

I have a $80\times 80$ matrix $A$ and a vector $P$ and I want to compute efficiently the following minimum $$\min\{n\in \Bbb N :\|A^nP\|_\infty < 1\}$$ Then I defined my matrix and vector in ...
78 views

### Find (numerically) point where derivative is infinite

I have a function that is shown in the image, below. The point I am interested in extracting (numeric fine) is, in this case, 200. This appears to be the point at which one derivative is infinite. It ...
303 views

### Maximizing over a 1D region

Why does the following not compute? MaxValue[-y^2, y ∈ Interval[{-1, 1}]] I expect it to compute the maximum value of the funtion over the interval from -1 to 1 ...
41 views

### NDSolve with Events that reevaluate with different Discrete Variables

I have the following problem: I have a set of ODEs and some discrete variables which I can solve successfully. Now I want mathematica to check at every $0.1 \,t$ time step, wether it would increase ...
206 views

### Levenberg-Marquardt method for fitting

I have a model function: ...
63 views

### Using preconditioners efficiently

I am trying to numerically solve a linear system of equations of the form A x = a where A is really ill-conditioned and ...
187 views

### Maximizing efficiency of a power-tower (tetration) calculation

I'm working on a power tower $\displaystyle z^{z^{.^{.^{.}}}}$ and wish to maximize the efficiency of my algorithm to compute a cycle map. This is a color-coded diagram of the cycle period of each ...
58 views

### NDSolve with Functions Depending on time and time dependent Functions

EDIT: following the advice of using Raw Input Form, the equations have the following form ...
55 views

### Calculating the volume of a paraboloidal region

I have an inequality that defines a paraboloid. I would like to calculate the volume of the intersection of this paraboloid and a cylinder of radius R. ...
95 views

### Is it possible to minimize this function in Mathematica/wolframAlpha?

I want to minimize this function $f(x, y)=\left(n_{1}\right)\left(1-x(1-x)^{k_{1}}(1-y)^{k_{2}}\right)^{T}+\left(n_{2}\right)\left(1-y(1-x)^{k_{1}}(1-y)^{k_{2}}\right)^{T}$ Though it is a function in ...
406 views

### Finding a center and radius that minimizes total distance

I have a list of $d$-dimensional data points $x_i$, and I want to find a $d$-ball which minimizes the sum of the squares of distances between the surface of the ball and the points. In other words, I’...
104 views

### Find the minimum of an expression with multiple constraints

I need help to find a value for "d" which the expr has the minimum value at that "d" value. Constraints are added to the code ...
56 views

### Minimal and maximal angular separation of two spheres as viewed from surface of third sphere

Short version: find the values of theta and phi that make overlapValue (defined below) maximal and the values of theta and phi that make it minimal, given that all other values are constants and ...
88 views

### Finding the maxima of a function of two variables

I am trying to understand how Mathematica finds the local maxima of a function of two variables, but I am a bit lost here. For example, consider: ...
65 views

### Minimization problem!

Im probably not seeing the obvious question but i want to minimize an expression like: Func[A_,B_,θ_,θ1_]:= A Cos[θ-θ1] + B Sin[θ]^2 where i do to minimize in ...
100 views

### How can I find the coefficients which minimize my non elementary integral?

I have the integral which I express in Mathematica code as: Integrate[ (-((x^2 (c + x^2 (b + a x^2)))/(m + x^2 (v + d x^2))) + Abs[x])^2, {x, -1, 1}] I ...
111 views

### Finding the global maximum of a function

I've the following code: ...
53 views

### How to interpolate a set of points with given local extrema?

I have a set of points on the 0xy plane: say (-3,0), (-2,4), (-1,0), (1,2), (3,0), (5,1), (6,0), (8,-2), (10,0) I would like to use software, like Mathematica, ...
42 views

### Maximise a function over real and complex parameters [closed]

I have the function f[b_x_] := Exp[-I b] Sin[I x], where $x$ is real and $b$ is complex. I want to maximise the function $f$ over $x$ and $b$, but it is ...
65 views

### Plotting only one piece of an implicit 3d surface (the one value of the order parameter wich minimizes some free energy function)

I would like to plot a graphic of spontaneous magnetization vs T vs h for a Curie Weiss Model. The equation for stationary ...
55 views

### Question for function FindMaximum

I need some advice on using the function FindMaximum as follows. I find the function y(x) from a differential equation as below, and then for each c and each xMax I have different solutions y(x) and ...
47 views

### Prime Number Generator using Sieve of Eratosthenes

I was trying to apply the Sieve of Eratosthenes to find the prime numbers within the range of 100. I understand that Mathematica has a built in procedure to find prime numbers, but I was trying to ...