Answered
Error getting the max value of a 3D matrix and its indexes
I cannot reproduce your claim. I ran your code and got Cpmax = 8.1949. I got the same result for C. Your final three lines look ...

8 years ago | 0

| accepted

Answered
How do I used data exported from the PDE toolbox in order to create specific XY plots?
Depending on your toolbox version, there are differing ways to plot things. If you have a relatively recent version, then use <h...

8 years ago | 0

| accepted

Answered
Constraint dependent in mutatuon
I'm not sure what you want to know. The built-in |mutationadaptfeasible| function is briefly described <https://www.mathworks.co...

8 years ago | 0

Answered
How to obtain the correct steady-state solution to the heat equation by solving the Laplace equation using the PDE toolbox
This solution is correct, zero is a solution. And, as you note, you can add any constant to the solution because you have not sp...

8 years ago | 0

Answered
Using Bayesopt for TreeBagger Classification
I think that you are pretty close. You just have to define what your objective function is as a function of the parameters you u...

8 years ago | 0

Answered
Help please with MATLAB ga toolbox (Not enough input arguments)
Try this command: which -all pallab Also try type pallab The reason I ask is that using exactly your stated func...

8 years ago | 0

Answered
How to provide part of the gradient analitically and the other part numerically in fmincon
I am sorry, but I do not think that |fmincon| has the ability to use analytic gradients for a subset of the nonlinear constraint...

8 years ago | 0

| accepted

Answered
When solving pde, can I use a modified nodal solution as the initial condition for the next pde?
So take the solution and modify it: sol = results.NodalSolution(:,end); highvalues = sol >= 5; lowvalues = sol <= -2;...

8 years ago | 0

Answered
Error "OptimizeHyperparameters is not a valid parameter name." while using fitcsvm(X,Y,'OptimizeHyperparameters','auto').
As stated in the <https://www.mathworks.com/help/stats/release-notes.html Release Notes>, Bayesian Optimization was introduced i...

8 years ago | 1

Answered
Nummerical derivative or gradient
|fmincon| estimates derivatives automatically by taking finite differences. Your FEM is like a simulation, so be sure to follow ...

8 years ago | 0

| accepted

Answered
If I want to apply PSO for a 100 matrices each matrix of 60x60 dimensions , what will be the fitness function ,object function and the particles?
The <https://www.mathworks.com/help/gads/particleswarm.html#inputarg_fun |particleswarm| documentation> states that the objectiv...

8 years ago | 0

Answered
Optimizing with X as a vector
You cannot minimize a vector-valued function. You can only minimize a scalar-valued function. You can minimize the norm of a ...

8 years ago | 0

Answered
How to use solvepde with non constant coefficient?
If you have a relatively recent toolbox version, you can find out how to write coefficients <https://www.mathworks.com/help/pde/...

8 years ago | 0

Answered
Solving pde for geometry with concentric rings. Error: Invalid geometry detected. Edges overlap or intersect at non-end points.
I believe that <https://www.mathworks.com/matlabcentral/answers/327922-how-to-use-the-pde-toolbox-combined-with-the-script this ...

8 years ago | 0

Answered
how to formulate constraints in GA
You say that you are not all that familiar with optimization, and yet you have already decided on using a genetic algorithm. In ...

8 years ago | 0

Answered
Skip lsqnonlin run if error
If you have Global Optimization Toolbox, then use |MultiStart| to run |lsqnonlin| several times. |MultiStart| automatically cont...

8 years ago | 0

| accepted

Answered
Is there a way to import 2D meshes (nodes and triangles) into PDE model objects?
There is currently no functionality for creating geometry from a 2-D mesh. Sorry. You might be able to use legacy functions t...

8 years ago | 0

| accepted

Answered
I have a multiobjective optimization problem with three objective functions. I want to plot pareto front of all the 3 objectives in a 3 dimensional space. How do I do it?
<https://www.mathworks.com/matlabcentral/answers/110723-is-it-possible-to-generate-surface-pareto-front-for-3-objective-function...

8 years ago | 0

| accepted

Answered
When to use cost function or error function for fitting
I'm sorry that you don't find the documentation clear on this issue. * If you are using |lsqnonlin| or |lsqcurvefit|, then yo...

8 years ago | 0

| accepted

Answered
Default settings in ga function
According to <https://www.mathworks.com/help/gads/mixed-integer-optimization.html#bs1cihn the documentation>, there are "special...

8 years ago | 0

Answered
Matlab: 2d linear elasticity PDE
You can find the theoretical information <https://www.mathworks.com/help/pde/ug/structural-mechanics--plane-stress.html here>. A...

8 years ago | 0

Answered
Writing Constaints for simulannealbnd
The constraint you have is not a bound, it is a <https://www.mathworks.com/help/optim/ug/linear-constraints.html linear inequali...

8 years ago | 0

| accepted

Answered
fmincon objective function problem
You need to put ALL of your control variables in one vector or matrix |x|. function f = objfun(x,a,b,I) x1 = x(1:24); ...

8 years ago | 1

Answered
sinusoidal time dependent boundary condition - pde toolbox
Depending on your software version, that looks correct. The relevant documentation is <https://www.mathworks.com/help/pde/ug/ste...

8 years ago | 0

| accepted

Answered
PDE Toolbox - How to specify coefficient for temperature-dependent properties ?
I believe that the error comes from a misunderstanding on your part: the |state.u| field is a row vector. So when you want to sq...

9 years ago | 0

| accepted

Answered
Output function for particleswarm command
Try this function: function stop = pswoutfun(optimValues,state) persistent hist stop = false; switch state ...

9 years ago | 1

Answered
Error using pde.EquationModel/solveStationaryNonlinear (line 104) Stepsize too small.
Are you giving nonzero initial conditions for the solution? It looks like your equations might be singular where the solution gr...

9 years ago | 0

| accepted

Answered
How can I convert equality constraints into inequality constraints?
Did you see the <https://www.mathworks.com/help/gads/mixed-integer-optimization.html#bs1clc2 documentation dealing with equality...

9 years ago | 0

Answered
i am using simulated annealing optimization toolbox matlab and i want to display current function value,best function value and best iteration so far at each iteration of my program.
Write an <https://www.mathworks.com/help/gads/simulated-annealing-options.html#bq26j8s-7 output function> that returns |optimval...

9 years ago | 0

Answered
scheduled optimtool removal date?
Currently, there is no scheduled removal date. We will remove it when the underlying supporting software ceases to work. Alan...

9 years ago | 0

Load more