Réponse apportée
Too many input arguments error
Your function xa and xn have three inputs (n,x,g), not two (n,g). Thus x_func = @(n, g) (xa(n, g)/xn(n, g))^(1/3); % Example T...

presque 2 ans il y a | 0

Réponse apportée
Why Does My Custom SA not Work for Mixed-integer Problem?
This is the problem structure of "simulannealbnd". I cannot find "IntVars". problem — Problem structure structure Problem st...

presque 2 ans il y a | 0

| A accepté

Réponse apportée
solving symbolic equations with partial derivatives
syms Cf(zf,zr) cf(z,theta) L zref = zf; thetaref = (zf - zr)/L; dCfdzf = diff(cf,z) * diff(zref,zf) + diff(cf,theta)*diff(the...

presque 2 ans il y a | 0

Réponse apportée
Calculations with distributions of variables only
Look up "Monte-Carlo-Simulation".

presque 2 ans il y a | 0

Réponse apportée
Time-dependent dynamic problem with nonlinear stiffness using ode45
You solve for U and Udot - thus you get values for U and Udot from ode45. Simply compute the matrix K(U) with these values and p...

presque 2 ans il y a | 0

Réponse apportée
Error: Data must be numeric, datetime, duration, categorical, or an array convertible to double.
% Declaring Theta and Phi Variables theta = 0:0.1:pi/2; % Phi Values phi_E_Plane = 0; phi_H_Plane = pi/2; % Declaring x...

presque 2 ans il y a | 0

Réponse apportée
How to solve this differential equation? I got ''Warning: Unable to find symbolic solution.'' error. What am I missing ?
You don't miss anything - your equation is just too complicated to have an analytical solution. You will have to use a numerica...

presque 2 ans il y a | 0

| A accepté

Réponse apportée
fsolve error: Unable to perform assignment because the indices on the left side are not compatible with the size of the right side.
Include the line size((2.*x_SW(2).*dfreq_SW_vr.*w(1).*g2) + ((1./4).*x_SW(1).*nu).*(f1b.*zet_0_0 + f2b.*eta_0_0).*g1.*cos(gamm...

presque 2 ans il y a | 0

Réponse apportée
Hi All. Just wondering why answer to (i) is not 4.9e+4. an why answer to (iii) is not (9x)/2 or 4.5 x. Many thanks. Brian
For (iii), use syms x real instead of syms x

presque 2 ans il y a | 1

Réponse apportée
Overwriting the maximum function evaluation
You didn't include the structure "optim_lsq" in the call to lsqcurvefit.

presque 2 ans il y a | 0

Réponse apportée
Operands to the logical AND (&&) and OR (||) operators must be convertible to logical scalar values. Use the ANY or ALL functions to reduce operands to logical scalar values.
if all(abs(grad_g1_val) < tol) && subs(g1, {x1, x2, x3}, x') <= 0 activeSet = [activeSet, 1]; % Constraint 1 is ac...

presque 2 ans il y a | 0

| A accepté

Réponse apportée
ODE45 and dsolve result difference
dydx(2)=2-2*y(2)-8*x; instead of dydx(2)=2-2*y(2)-8*y(1);

presque 2 ans il y a | 1

| A accepté

Réponse apportée
Intersection condition between two ellipses
I'm surprised that we get a division by zero by the below solution method if the aspect ratio of the two ellipses is equal. Bu...

presque 2 ans il y a | 0

Réponse apportée
Arrayfun with Extra Parameters
Test3 = arrayfun(f,a,b) instead of Test3 = arrayfun(@f,a,b)

presque 2 ans il y a | 0

| A accepté

Réponse apportée
Extract the indices based on the minimum absolute value
Maybe you mean %define the number of random numbers n = 10; %define the min and max ranges of random values stvar = [0 4]...

presque 2 ans il y a | 0

Réponse apportée
How to fit a distribution whose parameters depend on other parameters?
In this case, you must assume a parametric expression for T(z) as well (e.g. T(z) = a + b*z) and add a and b to the parameters t...

presque 2 ans il y a | 0

Réponse apportée
Solve and plot system in x and y with varying constants e and t
basically i would like to obtain on the same graph different curves in x and y for a fixed number of combinations of e and t. I...

presque 2 ans il y a | 0

| A accepté

Réponse apportée
sol2 = bvp4c(@bvpexam2, @bcexam2, sol);
Ibrardual() function Ibrardual Nt=0.5; Nb=0.5; Le=2; Pr=1; Alpha=[-0.2138;-0.4]; s=1; A=1; %% solution in structure form %...

presque 2 ans il y a | 0

| A accepté

Réponse apportée
What is the most computationally efficient factorization of a matrix A?
Prove that the matrix is positive definite and count the number of FLOPs of Cholesky compared to the other factorizations. Sect...

presque 2 ans il y a | 0

Réponse apportée
what is the error here?
The error is that the parameter "S" is not an input to function "odeBVP" and thus undefined in f =[y(2);y(3);(1/3)*D1*((y(2)^2...

presque 2 ans il y a | 0

Réponse apportée
Runge kutta giving complex numbers
It doesn't make sense to use such discontinuous input data for the solution of a differential equation. Solving a differential ...

presque 2 ans il y a | 0

Réponse apportée
How does Matlabs Symbolic Math Toolbox always finds an analytical eigendecomposition for arbitrary polynomial matrices?
For me this begs the question, is the eigenvalue polynomial from eig(...) truly analytic? What do you mean for a polynomial to ...

presque 2 ans il y a | 1

| A accepté

Réponse apportée
Want to understand how to implement in matlab the following differential equation?
If you know P1 over time, you don't have a differential equation, but simply an algebraic relation to determine Q: Q = (P1-P2)/...

presque 2 ans il y a | 0

Réponse apportée
Coding the Thomas algorithm for a heat and mass transfer problem
When I run the function, I get: Not enough input arguments. Error in solvePDEs (line 27) y(n) = linspace(y_span(1), y_s...

presque 2 ans il y a | 1

| A accepté

Réponse apportée
Mapreduce with tall array in matrix multiplication
Would this work for you ? B = ones(2,3); A = tall(ones(200,2)); values = A*B; gather(values)

presque 2 ans il y a | 0

Réponse apportée
Does pdepe accept 'Vectorized', 'on' as an option? If so, what does it do?
If you look into the documentation for "pdepe", you will find that the "Vectorized" option cannot be chosen: Cited from the doc...

presque 2 ans il y a | 0

| A accepté

Réponse apportée
Complex Integration in MATLAB with symbolic integration limits
Does this help ? Note that no distiction is made about the R-value. But you should keep in mind that the answer is incorrect i...

presque 2 ans il y a | 0

| A accepté

Réponse apportée
how i can change column vector into row vector??
Simply converting a row vector into a column vector needs the usual transpose operator which is .' You used only ' with is conju...

presque 2 ans il y a | 0

Réponse apportée
Does cummax works in a sde solver?
My question is: does here cummax works on all previous values of X(2)-X(1), or it takes it as a scalar at every iteration? It t...

presque 2 ans il y a | 0

Charger plus