# 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
42 views

### Position of maximum element in list under optimisation

For a list of several functions: functions = {a[x,y,z],b[x,y,z],c[x,y,z],d[x,y,z]}; I want to maximize the maximum value of a function of three variables. This ...
21 views

### NMaximize scrambles constraints

There have been lots of questions around regarding the issue that NMaximize/NMinimize may give results - or at least evaluate ...
45 views

### Simultaneous Peak and Background Fit

I'm not sure if this is the proper way to do this, but I have a question related to another open question of mine. In this post, I'm looking at analyzing some quantum dot UV-Vis absorbance spectra (...
72 views

### Proving the positive semidefiniteness of a 6X6 symbolic matrix

Specifically, I want to check the positive semidefiniteness of the following 6X6 symbolic matrix ...
99 views

### Maximize this function

For the following matrix $$M = \begin{pmatrix} f1[x,y,z] & f2[x,y,z]\\ g1[x,y,z] & g2[x,y,z]\\ h1[x,y,z] & h2[x,y,z] \end{pmatrix}$$ with ...
38 views

### Maximise over functions in Mathematica

Define the functions $h$, $j$, and $k$ that are each functions of 3 variables: h[x,y,z] j[x,y,z] k[x,y,z] How can I find the max of these functions? I want the ...
887 views

### Possible bug in NMaximize function?

Bug introduced in 12.0 In 12.0.0 for Microsoft Windows (64-bit) (April 6, 2019) writing: ...
54 views

### How to find, for a temp. equation, Maxmum valus of position and time?

I have to find the position x and the time t for which the temperature is a maximum. I have a function ...
48 views

### ArgMin over intervals and discrete sets

I was playing with ArgMin but I'm not sure how to use it for constrained optimization. For example, ArgMin[x^2, x] returns <...
124 views

### Minimizing expression over symmetric matrices

I'm trying to solve the following maximization problem over space of symmetric matrices A and positive definite H $$R=\max_{A\in S(R^d)}\frac{\text{tr}(HA)^2+2\text{tr}(HAHA)}{\text{tr}(AHA)}$$ So ...
55 views

### FindMinimum diverges

I just enocountered following issue, FindMinimjum explicitly diverges — final result is WORSE than initial supplied conditions. During evaluation of In:= ...
38 views

### Plot global maximum point and differential equation

I have two questions: (1) I found the global maximum point of the following function ...
36 views

### Arrow key problem with mathematica 12 and bash version 5

I want to know if anyone experiences the issue with mathematica-12 with bash-5? I am using the command line interface of mathematica. Now when I do up arrow or down arrow to go to history, it does ...
54 views

### NMinimize cannot be used within RegionPlot

My version of Mathematica (11.1) apparently cannot do NMinimize within RegionPlot. It did work before (!) my last software update. Here is an example from user GioMott having the same (unanswered) ...
43 views

### Find maximum of x given a bunch of constraints [closed]

Trying to find maximum of x given that '''0<=x<=3''' and some other stuff. This works fine: Clear[x, y] FindMaximum[{x, 0<=x<=3}, x] But this does ...
47 views

### Function of Maximum and Minimum Functions of Two Functions

I try to answer this question The Maximum and Minimum Functions of Two Functions I wrote the following code ...
41 views

### Numerical maximization

I am facing a numerical maximization problem with constraints. Using Method -> {"RandomSearch", "SearchPoints" -> 3}, AccuracyGoal -> 2 often does not find ...
35 views

### Is there a feasible computation?

I have to find the values of $p_1$ and $p_2$ which minimizes the expression $G$. However, when I took the partial differentiation of $G$ with respect to $p_1$ and $p_2$, the equations I obtained were ...
38 views

### Nested optimization problem 3

thanks to Ulrich Neumann I am getting close to the solution of my problem... However, Mathematica tells me that no points satisfy the constraints of the following problem: ...
34 views

### Nested optimization problem 2

I would like to solve a maximization problem which itself depends on a maximization. I came up with this code, ...
57 views

### Nested optimization problem

I would like to solve a maximization problem which itself depends on a maximization. I came up with this code, ...
68 views

### Linear map of unit cube (generalized)

This question is a slight generalization of this question. Let M be a fixed rational m $\times$ ...
96 views

### Minimize fails to find a minimum [closed]

I am trying to find, analytically, the $\theta,\phi$ that minimize the function U($\theta,\phi$) ...
35 views

### Get default values used in an Option of a NMinimize Method

I fear the answer is trivial, but I have extensively searched without any success. Say I perform a Nminimize minimisation using the Method "Simulated Annealing", e.g. the following from the ...
83 views

### The Maximum and Minimum Functions of Two Functions

Suppose I have two functions f(x,y)=1 + 2*x +3*y^3 and g(x,y)=y + x^2. I want to have maximum function of ...
31 views

### Constrain values to numeric during Minimize

I understand, that similar questions have been asked before, but I am absolutely new to Mathematica and can not solve it myself: In nuce it is the following: I want to calculate ...
113 views

44 views

### How to use StepMonitor in NMinimize when using vector variable

Bug persists through 12.0 For example, when I call this code ...
101 views

### Implement gradient method in functional programming style

I implemented the gm for quadratic function in Mathematica, but it looks like more in an OOP style, as the pic shows. How to rewrite it in Mathematica style? I tried with following code: ...
26 views

### Making a density plot for an expression

I have defined a function the energy $E$ of a given system by ...
52 views

### LinearProgramming with constraint on result

I need to solve a bunch of Diophantine Equations that takes so looong with FindInstance/Reduce, so I tried LinearProgramming and it's very fast. Here is a simple one: ...
64 views

### Computing RMSE (Root Mean Square Error) [closed]

I have the following data: ...
36 views

### Check whether a given quantity is negative

Given four numbers $n0, n1, n2, n4$ such that $n1+n2+n3+n4 = 1$. How can we check the sign of $A - 2 B$ (where $A$ and $B$ are defined below), i.e., whether this quantity is positive or negative? <...
16 views

### Apply Conditions on the Derivative of a Model with More Equations than Data in FindFit

Looking to combine the two approaches from these two posts here: How to Add a Constraint on the Derivative of the Model in FindFit How to fit 3 data sets to a model of 4 differential equations? ...
32 views

### How to have NonlinearModelFit not evaluate a function too early?

This is a follow up of my previous question How can I define the following function for arbitray values of the arguments? that received no attention so here I will try to be more concise with the ...
34 views

### Maximize and minimize R6 function using Lagrange Multipliers

I've been trying to maximize and minimize the following function using Lagrange Multipliers, in Wolfram Mathematica 11.3: d = Sqrt[x^2 + y^2 + z^2 + u^2 + v^2 + w^2] Subject to the following ...
61 views

### Status of DualLinearProgramming

DualLinearProgramming is referenced in this tutorial tutorial/ConstrainedOptimizationLinearProgramming It exists in ...
47 views

### How to Add a Constraint on the Derivative of the Model in FindFit

I would like to add constraints on a model and its derivatives and then use FindFit to fit some parameters. An example is below: ...
I have a very simple problem that Mathematica is giving a wrong answer to. I want to minimize the following function: $\frac{3+t^2+6\theta +3 \theta^2}{6 t^3}$ in $\theta$ and $t$. Now, plotting the ...