# Tagged Questions

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

108 views

### Simulated Annealing, SearchPoints and InitialPoints options set at the same time

I have a function that needs to be minimized. Since the function depends on real-time data (which is fetched every few hours, and the function is redefined according to the new data), I have to run ...
150 views

### NMinimize Example from Wolfram Documentation Center

Here is the third example of NMinimize function from Wolfram Documentation Center at Possible Issues section. ...
370 views

### Speeding up the non-negativity algorithm for multilinear function with interval probabilities?

The algorithm is a branch-and-bound algorithm that calculates the non-negativity of a multilinear function with interval probabilities. The lines 9-11 has an optimization that is explained on the 10-...
106 views

### Customized StepSize control in unconstrained gradient-descent optimization

I have a type of minimization problem I frequently solve that involves warping a large 2D triangle-mesh (~25,000 vertices) to fit a model. In the mesh, vertices carry the empirical measurements (each ...
256 views

### How to determine reason for kernel crash? -> Nelder Mead optimisation

I am making use of the Nelder Mead algorithm inside Mathematica's NMaximize to find a parameter set by solving the Schrodinger equation for a given system. (see ...
80 views

### Listable compiled functions used in NMinimize [duplicate]

This is an example from MMA: cListable = Compile[{x}, (x-1)^2, RuntimeAttributes -> {Listable}] In case of single entry: ...
296 views

### Problems extending NelderMeadMinimize into 2D

Update The eventual route I followed was to adapt a version of the NM-simplex written in C and link to it with MathLink. Once I've tested this out fully I'll post it here. I've been playing around ...
173 views

### Issue with FindCurvePath

I have a problem with the function FindCurvePath. In some cases it crashes the Mathematica 9 Kernel. Here an example, where it crashes the kernel: ...
461 views

### Minimal overlap area of circles

I have 20 points in the 2D plane with $(x_i,y_i)$ coordinates. I want to use Mathematica to optimally distribute 10 circles with equal radius of a given positive value $R$, i.e. to determine with the ...
185 views

### Finding the maximal t at which u[x,t] == 1?

Given the smooth function u[x,t] on a domain, how do I find the maximal t at which ...
357 views

### Finding minimum and maximum of implicit functions

The equations of the system are ...
312 views

### Is there any strategy to have a compiled version of FindFit or NonlinearModelFit?

Disclaimer: This is not a precise question with a definite answer. I know that neither FindFit nor NonlinearModelFit is in the ...
377 views

### Optimum number of cog teeth for two step helical gearbox

Note: Cross-posted at http://community.wolfram.com/groups/-/m/t/137895?p_p_auth=8QnKtT9I. I am to design a two step gearbox. The first step is to choose the number of teeth in each cog wheel in ...
540 views

### What alternative notation of subscripts/superscripts that are also treated as SYMBOLS in Mathematica?

I tried to avoid using the subscript $A_0$ in the Module, and get an error with $A[0]$. ...
824 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 ...
299 views

### Extrema of a function of three variables

To identify and classify the critical points of the function $f(x,y,z)=x^3+xz^2-3x^2+y^2+2z^2$, I used the Hessian matrix method. ...
256 views

### Optimizing a rank 3 tensor

Assume we have the following elements $$F_i{}^j \;and\; S_{ij}{}^k,$$ which represent the components of tensorial objects of ranks 2 and 3 respectively, with Complex ...
99 views

### How to find alignments of interlocking shapes?

I'm searching for the ways to align interlocking shapes, that is, finding the locations and rotations that maximize the arc length at which they touch. For simplicity, I'm assuming 'shapes' are one ...
108 views

### Parallel function evaluation for minimal value

I am asking myself, if the evaluation of a function f looking for a minimal value over a discrete set of values can be parallelize (brute scan for a potential ...
168 views

### FindMinimum's WorkingPrecision behaviour

I discovered the following behaviour when using FindMinimum for constrained optimization: ...
166 views

### NMinimize in one-dimensional Interval

An Interval should be a one-dimensional region, so a region. I tried to minimize a function over an interval, e.g.: ...
118 views

### Optimization problems over the Integers

Should be an easy question. How can I define a function which gets only integers in a form that I can use to find max and min for instance? Example: Find the Max of the expression ...
172 views

### Optimizing code containing an infinite sum

I have the following expression. It's based on the negative-log-likelihood of a Poisson-Gaussian noise model, i.e. a convolution of a Poisson & Normal distribution. The value $x_{i}$ is the ...
301 views

### Slow-down encountered when using NMinimize with a compiled function

I'm minimizing a large function. Evaluating the function is very slow symbolically but using Compile I can get ~100x speed-up on this step. However, despite this, the NMinimize process is only ...
324 views

### FindMaxValue specifics

I'm using FindMaxValue to study the distribution of maxima of Abs[RiemannSiegelZ[t]] between consecutive values of ...
107 views

### Simple minimization not evaluating

I tried to solve a rather simple optimization problem, which Mathematica apparently cannot handle. A minimal example is the following: ...
86 views

### Softmax Regression Classification Algorithm

I'm following the Stanford Machine Learning course while simultaneously developing my Mathematica abilities. I'm having issues with my Softmax Classifier implementation (for ref, have a look at these ...
59 views

### “PostProcess” and “Tolerance” in DifferentialEvolution? [closed]

What is "postprocess" option in DifferentialEvolution method (for instance when using ...
231 views

### Visualizing the Lagrange Multiplier Solution

This question is based on work in Susan Colley's Vector Calculus, 4th ed. The question is to find and classify critical points of $f(x,y,z)=3xy-4yz+5xz$ subject to the constraint $g(x,y,z)=3x+y+2z=13$...
94 views

### How to perform Bayesian optimization with Mathematica? [duplicate]

Does Mathematica have any Bayesian optimization methods for learning hyper-parameters? Practical Bayesian Optimization of Machine Learning Algorithms Jasper Snoek, Hugo Larochelle and Ryan P. ...
176 views

### Custom Methods for NMinimize/NonLinearModelFit

Is there a way to write custom methods for NonLinearModelFit or NMinimize? To give background, I currently have a batch of code ...
335 views

### Packages for Semidefinite programming

This question has already been asked here. I am not sure, whether I should have asked this question as a comment of an old question or in the general programming forum of stackexchange. Moderators ...
184 views

### NMinimize seems to call function with the same values multiple times

I have to minimize a function where the evaluation of one parameter set takes very long (around 5sec) and discovered alongside, that NMinimize seems to call this ...
888 views

### When using NMinimize[…,Method->“DifferentialEvolution”] is an “iteration” different than a “step”?

Hopefully this question has a simple answer. I have the following bit of code: ...
697 views

### Semidefinite Programming

I want to solve a numerical optimization problem using semi-definite programming. Is there a package or add-on that equips mathematica with this functionality?
293 views

### How can I name “a[[i]]” the parts of Table “a”? Or how to make Table “a” grow inside FindMinimum?

Let's say I want to minimize a function that uses a Table named a with the Conjugate Gradient Method of ...
594 views

### How to find the minimum of this constrained expression?

Let $x$, $y$, $z$ be three nonegative real numbers and $x^2 + y^2 + z^2 = 5.$ Find the minimum of the expression $$E=\dfrac{1}{2}x^2 y^2 + y^2 z^2 + z^2 x^2 + \dfrac{96}{x + y + z + 1}.$$ I tried <...
183 views

### NMinimize fails on Mesh?

Context I want to identify the minimum of a solution of a PDE found on a mesh. Problem I do not understand why NMinimize fails on a mesh? As a test case, ...
348 views

### Maximization in Mathematica using matrix and vector notation

I am trying to solve a simple maximization problem in Mathematica, using matrix and vector notation. ...
368 views

### $L_\infty$ norm minimization

I write supplemental explanation to render my aim of optimization. First Consider discrete time linear system below: $$G(z)=\frac{1-e^{-0.3T}}{z^{100}(z-e^{-0.3T})}$$ ...
204 views

### Reordering numerically calculated eigenvalues assuming smooth dependence on a parameter

As was discussed in a different question here on SE (link) if you compute eigenvalues numerically of a matrix which depends on a parameter y, the resulting plot of ...
934 views

### How to solve a quadratic integer programming problem?

I want to solve a quadratic integer programming problem in Mathematica. My first attempt looks like this: ...
91 views

### Writing a function that finds the difference between two maxima

Suppose i have two functions: $\qquad -2x^2 +5x+3$ and $\qquad -5x^2 +2x+3$ To solve the point where the functions are at maximum i use the command NMaximize ...
334 views

### FindRoot constrained to maximum

I am using FindRoot to find the local maximum op some function, by examining where its derivative is zero. However, keeping the starting value the same, sometimes <...
1k views

### Inequalities with assumptions and constraints

I'm using Mathematica 8 I've been searching the net without luck for this specific solutions: Suppose I have an inequality f(x;M,m)>0 where I KNOW that M>4m and m>0. How can I let Mathematica know ...
3k views

### Determining the local extrema of discrete data [duplicate]

Possible Duplicate: Local max/min of Mathematica data sets If I have a continuous function f (for example f = Sin[x]), I ...
199 views

### Why is this minimization with Boole functions failing?

I am running this command in Mathematica 8.0.4.0: ...
651 views

### Finding minimal distance between two surfaces

This code will display two parametric surfaces: ...
I want to find the greatest of the expression $$P=a \sqrt{12-b}+\sqrt{b\left(12+a^2\right)}+66\sqrt{a^2+b+3}-\left(a^2+b\right)^2$$ with $a >0$, $0<b\leq 12$. I tried ...