Réponse apportée
Plotting the outcome of a 3D fit
x = 0:0.1:1; y = -1:0.1:1; [X,Y] = meshgrid(x,y); Z = X.^2+Y.^2+0.1*(-1+2*rand(size(X))); [Xout,Yout,Zout] = prepareSurfaceD...

presque 3 ans il y a | 0

| A accepté

Réponse apportée
Goodness of fit for weibull distribution
https://www.spcforexcel.com/knowledge/basic-statistics/deciding-which-distribution-fits-your-data-best https://stats.stackexcha...

presque 3 ans il y a | 0

Réponse apportée
How can I generate a vector like this 1,2,2,3,3,3,4,4,4,4 by using for loop?
Start with y = [] and in each step of the for-loop running from 1 to n, concatenate y and i*ones(1,i).

presque 3 ans il y a | 0

| A accepté

Réponse apportée
Hello, I have problem with odeToVectorField in ODE second order system of equations.
dydt = fun(0.1,ones(12,1)).' function dydt = fun(t,y) g= 9.81; m= 0.468; Ix= 4.856e-3; Iy= 4.856e-3; Iz= 8.801e...

presque 3 ans il y a | 0

| A accepté

Réponse apportée
Why am i getting the error 'The first input to exist must be a string scalar or character vector' while solving 4 ode using ode45 solver ??
ode45 is a numerical integrator. It doesn't accept symbolic inputs. b = deg2rad(45); tspan = [0 pi]; y0 = [0.10 3.14e-06 1.4...

presque 3 ans il y a | 0

Réponse apportée
How to find the intersection values?
format long d1 = 0.4;d2 = 0.6;d = d1 + d2; n1 = sqrt(12);n2 = 1; D1 = @(lambda)(2*pi*n1*d1)./lambda;D2 = @(lambda)(2*pi*n2*d2...

presque 3 ans il y a | 0

Réponse apportée
2nd order differential equation with two 1st order differential equations boundary condtions
This is the code for the equation and boundary conditions you posted: xmesh = 6:0.005:6.5; solinit = bvpinit(xmesh, [6.55 0.57...

environ 3 ans il y a | 0

| A accepté

Réponse apportée
in the below mentioned code, i get an error in finding some elements (not in all) : 0×1 empty double column vector
k = find(abs(x-0.3)==min(abs(x-0.3)))

environ 3 ans il y a | 0

Réponse apportée
What can I do if Matlab never stops calculating a system of equations?
I'd suggest you don't use the symbolic toolbox for your problem, but to define an optimization problem: min: any function you l...

environ 3 ans il y a | 0

Réponse apportée
Solve the integral in the point where the function is singular
I'd suggest syms x func1_symb=sqrt(0.025)/(8*sqrt(pi*(x-x_approach(1)))); value_integral = 0.0; for i = 1:numel(x_approach)-...

environ 3 ans il y a | 0

Réponse apportée
Solving a problem with the Shooting Newton Method in Matlab
sol = fsolve(@fun,23,optimset('TolFun',1e-12,'TolX',1e-12)); fun(sol) [X,Y] = ode_solver(sol); figure(1) hold on plot(X,Y(:...

environ 3 ans il y a | 0

Réponse apportée
Doubt in a program
Why ? In order to plot a time-location curve after the while-loop, the intermediate results for time and location are saved in ...

environ 3 ans il y a | 0

| A accepté

Réponse apportée
2D diffusion equation for a laser heat source
qdot is 1x51, T(Sy,Sx) is a scalar. Thus Tn(Sy,Sx)=Tn(Sy,Sx)+dt*q_dot/rho/cp; tries to assign an array to a scalar which thro...

environ 3 ans il y a | 0

Réponse apportée
yy3 is generating a straight line while it should generate a curve, i don't understand what is wrong!!!
As initial condition for y(7), you set y(7) = 0, and you define the differential equation for y(7) as dy(7)/dx = y(7). The solut...

environ 3 ans il y a | 0

| A accepté

Réponse apportée
Solve non linear equation with vector
x(k1) = 45+dados.mass(k1)*sqrt(-2*log(dados.par(k1))) or x(k1) = 45-dados.mass(k1)*sqrt(-2*log(dados.par(k1)))

environ 3 ans il y a | 1

Réponse apportée
Heat Flow in PDEToolbox: Uniform Heat Flux does not give uniform temperature.
Either you presribe heat flux or convection coefficient and ambient temperature on Face 3. I don't understand how both options c...

environ 3 ans il y a | 0

Réponse apportée
Exponential fitting of data not working
A = load("T_A.mat"); A = A.T_A; A = [linspace(0,83.3,1666).',A]; plot(A(:,1),A(:,2),'o') hold on p0 = [25 1 1]; f = @(p)p(...

environ 3 ans il y a | 0

Réponse apportée
Unable to perform assignment because the size of the left side is 1-by-1 and the size of the right side is 0-by-1.
rand(-1,1) tries to create a matrix of uniformly distributed random variables on [0,1] with dimensions -1 and 1. A negative matr...

environ 3 ans il y a | 0

Réponse apportée
How to calculate empirical cumulative distribution function of a dataset? If I use ecdf function then why the number of datapoints are decreasing? Is there any other formula?
If I use ecdf function then why the number of datapoints (the matrix f1 becomes (1564x1) and x1 becomes(1564x1) matrix) are decr...

environ 3 ans il y a | 0

Réponse apportée
Hello folks, I need help regarding visualization of solutions for a transient thermal analysis done using PDE solver on a 3D geometry.
ad 1) Face 2 is an internal boundary. You don't need to set a boundary condition on it. The internal boundary condition is T_le...

environ 3 ans il y a | 0

Réponse apportée
Nonlinear overdetermined equation systems
By using "lsqnonlin", e.g. sol0 = [0 0 0 0]; sol = lsqnonlin(@fun,sol0) norm(fun(sol)) function res = fun(u); x = u(1);...

environ 3 ans il y a | 0

Réponse apportée
can anyone help me about Error using optim.problemdef.OptimizationProblem/solve Invalid argument at position 2. Value must be finite.
Above your error - written out more clearly so that you as the coder should be able to understand the problem. In nodestr=dec...

environ 3 ans il y a | 0

| A accepté

Réponse apportée
Problem to solve nonlinear Eq. with Newton's Method
i=sqrt(-1); n1=1; n3=1.515; lambda=632.8; %nm alpha0=-deg2rad([50 55 60]); teta1=deg2rad(50); phi0 =deg2rad([75.357 68...

environ 3 ans il y a | 0

Réponse apportée
How to plot two concentric spheres with radius1=1 and radius2 =10 in MATLAB and filled with fluid flow (I have one velocity component only)
lambda=1.5; eta=1; beta1=10;beta2=10; alpha=.00001; eta1=0.0;w=0.1;k=(1/eta.^2).^(0.5); a=1; % w=w2/w1 alpha1=((k.^2+(k....

environ 3 ans il y a | 1

| A accepté

Réponse apportée
How to plot two concentric spheres with radius1=1 and radius2 =10 in MATLAB and filled with fluid flow (I have one velocity component only)
I'm surprised that velocity increases with growing r. Continuity equation should force velocity to decrease. But maybe my parame...

environ 3 ans il y a | 0

Réponse apportée
levenberg-marquardt with linear constraints
x = lsqnonlin(fun,x0,lb,ub,A,b,Aeq,beq,nonlcon) A,b,Aeq,beq define the linear constraints.

environ 3 ans il y a | 2

Réponse apportée
measurement based optimization using fmincon
"fmincon" is not a stochastic, but a deterministic optimizer. You are not allowed to use random inputs for it that change every ...

environ 3 ans il y a | 0

| A accepté

Réponse apportée
Error: Limits of integration must be double or single scalars. While solving equations numerically with symbolic integral limits
I guess this is what you mean. initial_guess = [0.5, 0.1, 2]; % Use fsolve to solve the equation system result = fsolve(@(var...

environ 3 ans il y a | 1

| A accepté

Charger plus