Memuat
Memuat
Constrained Optimisation with fmincon for Chemistry and Materials
0 views
Optimise alloy tensile strength with fmincon over first element fraction and second element fraction under operational constraints. fmincon minimises a nonlinear objective subject to linear and nonlinear constraints and variable bounds. It is used in design optimisation, model parameter calibration, and constrained engineering problems.

Optimise alloy tensile strength with fmincon over first element fraction and second element fraction under operational constraints.
| Role | Variable | Unit |
|---|---|---|
| Main | Alloy tensile strength | MPa |
| Supporting 1 | First element fraction | % |
| Supporting 2 | Second element fraction | % |
fmincon finds the optimum First element fraction=0.896 and Second element fraction=0.802 with objective Alloy tensile strength=0.011 after 14 iterations; the circular constraint of radius 1.20 is active (constraint value 0.0e+00).
Computed from illustrative synthetic data, not from a real study.
fmincon minimises a nonlinear objective subject to linear and nonlinear constraints and variable bounds. It is used in design optimisation, model parameter calibration, and constrained engineering problems.
Report the solution, objective value, exitflag, and active constraints. Explain multipliers as the sensitivity of the objective to the constraints.
A short starting script with this project's variable names. The delivered version is adapted to your data and fully commented.
alloy_tensile_strength = @(x) (x(1) - 3)^2 + (x(2) - 2)^2; % objective
nonlcon = @(x) deal(x(1)^2 + x(2)^2 - 9, []); % x1^2 + x2^2 <= 9
A = [1 1]; b = 4; % x1 + x2 <= 4
lb = [0 0]; ub = [5 5];
first_element_fraction = [0.5 0.5]; % starting point
opts = optimoptions('fmincon', 'Algorithm', 'sqp', 'Display', 'off', ...
'OptimalityTolerance', 1e-10);
[x, fval, exitflag, output, lambda] = fmincon(alloy_tensile_strength, first_element_fraction, A, b, [], [], lb, ub, nonlcon, opts);
fprintf('Solution: x1 = %.4f, x2 = %.4f\n', x(1), x(2));
fprintf('Objective: %.5f, exitflag = %d, iterations = %d\n', fval, exitflag, output.iterations);
fprintf('Multiplier (linear): %.4f, (nonlinear): %.4f\n', lambda.ineqlin, lambda.ineqnonlin);
[g1, g2] = meshgrid(linspace(0, 5, 200));
Z = arrayfun(@(a, b) alloy_tensile_strength([a b]), g1, g2);
figure; contour(g1, g2, Z, 25); hold on;
th = linspace(0, pi/2, 100);
plot(3*cos(th), 3*sin(th), 'r', 'LineWidth', 1.2);
plot([0 4], [4 0], 'k--', x(1), x(2), 'm*', 'MarkerSize', 10);
xlabel('x_1'); ylabel('x_2'); legend('Objective', 'Circle', 'Line', 'Linear', 'Optimum');Choose how much help you need. Each higher package includes everything in the lower ones. Prices exclude 11% VAT.
Package 1
US$25
excl. 11% VAT
Duration: 5 working days
Output: MATLAB files + result figures
Deliverables
Package 2 · most chosen
US$69
excl. 11% VAT
Duration: 9 working days
Output: Code + analysis + interpretation notes
Includes all of Package 1, plus
Package 3
US$153
excl. 11% VAT
Duration: 14-17 working days
Output: Code + analysis + guidance until ready to present
Includes all of Packages 1 & 2, plus
Yes. Constrained Optimisation with fmincon is commonly used at this level in Chemistry and Materials. We adapt the analysis to your research question, your own data and your supervisor's requirements.
No. The sheet is computed from illustrative synthetic data so you can see the kind of output MATLAB gives. For your order we run the same method on your own data.
That is the point of the packages. Every script is commented, and Package 3 includes two coaching sessions plus practice questions so you can explain the method and the results at your seminar and defence.
Each project has three packages: Package 1 (code and explanation) US$25, Package 2 (your data analysis and interpretation) US$69 and Package 3 (full guidance) US$153, excluding 11% VAT. Larger datasets, extra methods or tight deadlines adjust the quote after a short consultation.
The result sheet uses illustrative synthetic data. MATLAB is a trademark of The MathWorks, Inc.
Back to MATLAB portfolio