Feeds
已回答
How to multiply different size arrays and multiply each element by each element?
If nothing helps, make a 4-fold nested loop. for i=1:numel(Span) for j = 1:numel(MAC) for k = 1:numel(CoM) ...
How to multiply different size arrays and multiply each element by each element?
If nothing helps, make a 4-fold nested loop. for i=1:numel(Span) for j = 1:numel(MAC) for k = 1:numel(CoM) ...
1 day 前 | 0
已回答
Combine non integer time steps into daily values
@Cristóbal Looking at the volume values, I'm almost sure that these values are already cumulative values. Why should the increa...
Combine non integer time steps into daily values
@Cristóbal Looking at the volume values, I'm almost sure that these values are already cumulative values. Why should the increa...
3 days 前 | 2
已回答
Programming wave dispersion equation
Code taken from https://uk.mathworks.com/matlabcentral/fileexchange/156009-wavelength-calculation-based-on-dispersion-relations...
Programming wave dispersion equation
Code taken from https://uk.mathworks.com/matlabcentral/fileexchange/156009-wavelength-calculation-based-on-dispersion-relations...
4 days 前 | 0
| 已接受
已回答
Modelling a system of differential equations with recurrences in matlab
N = 20; k = 1; a = 1; b = 1; c = 1; d = 1; u0 = zeros(N,1); udot0 = 0.5*ones(N,1); v0 = zeros(N,1); vdot0 = 0...
Modelling a system of differential equations with recurrences in matlab
N = 20; k = 1; a = 1; b = 1; c = 1; d = 1; u0 = zeros(N,1); udot0 = 0.5*ones(N,1); v0 = zeros(N,1); vdot0 = 0...
5 days 前 | 0
| 已接受
已回答
How can received my license?
Either through the IT department of your university or - if you have an individual licence - by contacting MATLAB support: http...
How can received my license?
Either through the IT department of your university or - if you have an individual licence - by contacting MATLAB support: http...
5 days 前 | 1
已回答
Please help me to solve this simple error
@Walter Roberson answered the question about your MATLAB error. Concerning the problem you try to solve: I assume d1, d2 are ...
Please help me to solve this simple error
@Walter Roberson answered the question about your MATLAB error. Concerning the problem you try to solve: I assume d1, d2 are ...
5 days 前 | 0
已回答
Curve fitting with a custom equation
Only round brackets are allowed in your expression. But maybe there are additional problems. If the code does not work after r...
Curve fitting with a custom equation
Only round brackets are allowed in your expression. But maybe there are additional problems. If the code does not work after r...
7 days 前 | 0
已回答
Trying to figure out a algorithm to filter out some data, since I dont have any additional toolbox.
load("eeandv.mat") tol = 0.005; idx = abs(diff(e)) <= tol; e = e(idx); v = v(idx); plot(v,e) grid on; grid minor; xlim([...
Trying to figure out a algorithm to filter out some data, since I dont have any additional toolbox.
load("eeandv.mat") tol = 0.005; idx = abs(diff(e)) <= tol; e = e(idx); v = v(idx); plot(v,e) grid on; grid minor; xlim([...
8 days 前 | 1
已回答
I want to avoid fractions in my answer to the null space
Insert for i = 1:size(N_A,2) [~,d] = numden(N_A(:,i)); N_A(:,i) = N_A(:,i)*lcm(d); end after computing N_A.
I want to avoid fractions in my answer to the null space
Insert for i = 1:size(N_A,2) [~,d] = numden(N_A(:,i)); N_A(:,i) = N_A(:,i)*lcm(d); end after computing N_A.
13 days 前 | 0
已回答
Prevent "any Matlab service" from loading on Windows 11 startup.
Follow the instructions given here: https://uk.mathworks.com/matlabcentral/answers/101038-why-is-matlab-always-running-in-the-b...
Prevent "any Matlab service" from loading on Windows 11 startup.
Follow the instructions given here: https://uk.mathworks.com/matlabcentral/answers/101038-why-is-matlab-always-running-in-the-b...
19 days 前 | 0
已回答
why does set(gca) not working
The set command must be placed after the plot command, not before: FONT_SIZE = 16; max_iter = 10; x = 1:max_iter; % this is t...
why does set(gca) not working
The set command must be placed after the plot command, not before: FONT_SIZE = 16; max_iter = 10; x = 1:max_iter; % this is t...
20 days 前 | 0
| 已接受
已回答
Naming Table Variables of a File
load("T.mat") T1 = splitvars(T); T1 = renamevars(T1,["rows_1" "rows_2" "rows_3" "rows_4" "rows_5" "rows_6"],... ...
Naming Table Variables of a File
load("T.mat") T1 = splitvars(T); T1 = renamevars(T1,["rows_1" "rows_2" "rows_3" "rows_4" "rows_5" "rows_6"],... ...
20 days 前 | 1
| 已接受
已回答
Error using countOnes = sum(num); when trying to count how many zeros and ones are randomly generated.
Works in R2025A (see above). I suspect that somewhere in your code, you define a variable with name "sum". Rename it because it...
Error using countOnes = sum(num); when trying to count how many zeros and ones are randomly generated.
Works in R2025A (see above). I suspect that somewhere in your code, you define a variable with name "sum". Rename it because it...
21 days 前 | 1
已回答
Please i need to plot 3 dimension figure with (x axis is x, y axis is gamma function) and z axis is value of u for this simple attached relation
We don't know your problem, but it should work somehow like this. What do you mean by "the y-axis is the gamma function" ? Do ...
Please i need to plot 3 dimension figure with (x axis is x, y axis is gamma function) and z axis is value of u for this simple attached relation
We don't know your problem, but it should work somehow like this. What do you mean by "the y-axis is the gamma function" ? Do ...
22 days 前 | 0
已回答
Plot: index exceeds array bounds ("Index in position 1 exceeds array bounds. Index must not exceed 1.")
Rename the struct "plot" which appears in your workspace. It's probably in conflict with MATLAB's "plot" function.
Plot: index exceeds array bounds ("Index in position 1 exceeds array bounds. Index must not exceed 1.")
Rename the struct "plot" which appears in your workspace. It's probably in conflict with MATLAB's "plot" function.
27 days 前 | 1
| 已接受
已回答
Plotting sum of two vectors
%Parameters or =0.2; oc = 0.2; gamma = 0.01; gam=0.01; Gamma = 1; Gamma1 = Gamma; Gamma2 = Gamma; Gamma3 = 9/10; Gamm...
Plotting sum of two vectors
%Parameters or =0.2; oc = 0.2; gamma = 0.01; gam=0.01; Gamma = 1; Gamma1 = Gamma; Gamma2 = Gamma; Gamma3 = 9/10; Gamm...
27 days 前 | 0
| 已接受
已回答
ilaplace doesn't handle tanh()
You mean syms s T P2 = ilaplace( 1/s*(exp(s*T/4)-exp(-s*T/4))/(exp(s*T/4)+exp(s*T/4)) ,s); Tsteps = 0.1:0.5:20; num = vpa(su...
ilaplace doesn't handle tanh()
You mean syms s T P2 = ilaplace( 1/s*(exp(s*T/4)-exp(-s*T/4))/(exp(s*T/4)+exp(s*T/4)) ,s); Tsteps = 0.1:0.5:20; num = vpa(su...
27 days 前 | 1
已回答
Fitting 8 equations simultaneously with three parameters
If all 8 equations are linear in the fitting parameters like in your example from above, "lsqlin" instead of "lsqnonlin" would b...
Fitting 8 equations simultaneously with three parameters
If all 8 equations are linear in the fitting parameters like in your example from above, "lsqlin" instead of "lsqnonlin" would b...
28 days 前 | 2
| 已接受
已回答
Partial Differential equation: Createpde. f as afunction
Take a look at the example "Coefficient Handle for Nonconstant Coefficients" under https://uk.mathworks.com/help/pde/ug/pde.p...
Partial Differential equation: Createpde. f as afunction
Take a look at the example "Coefficient Handle for Nonconstant Coefficients" under https://uk.mathworks.com/help/pde/ug/pde.p...
1 month 前 | 0
已回答
Neumann boundary condition in a diagonal matrix
For fun, I computed eigenvalues and eigenfunctions for the full region with boundary condition u = 0 and for the quarter region ...
Neumann boundary condition in a diagonal matrix
For fun, I computed eigenvalues and eigenfunctions for the full region with boundary condition u = 0 and for the quarter region ...
1 month 前 | 0
已回答
Neumann boundary condition in a diagonal matrix
The Laplace operator is discretized as (u(x+h,y) - 2*u(x,y) + u(x-h,y))/h^2 + (u(x,y+h) - 2*u(x,y) + u(x,y-h))/h^2 If y = 0 an...
Neumann boundary condition in a diagonal matrix
The Laplace operator is discretized as (u(x+h,y) - 2*u(x,y) + u(x-h,y))/h^2 + (u(x,y+h) - 2*u(x,y) + u(x,y-h))/h^2 If y = 0 an...
1 month 前 | 0
已回答
Error while running my objective function by fmincon with nonlinear constraint for calculate optimization coordination overcurrent relay
So far, it seems to work. The constraint function is missing. % main_optimization.m % The main script for solving protective...
Error while running my objective function by fmincon with nonlinear constraint for calculate optimization coordination overcurrent relay
So far, it seems to work. The constraint function is missing. % main_optimization.m % The main script for solving protective...
1 month 前 | 0
已回答
Please help explain it
1) asks you to plot y1(x) = x + cos(x), y2(x) = -0.5 and y3(x) = 0.5 and see where y1 and y2 resp. y1 and y3 intersect. 2) a...
Please help explain it
1) asks you to plot y1(x) = x + cos(x), y2(x) = -0.5 and y3(x) = 0.5 and see where y1 and y2 resp. y1 and y3 intersect. 2) a...
1 month 前 | 2
已回答
I'm encountering the following error when I run my main program.
Do you see the problem ? a = rand(4,5) a(1:3,4:6) "ymax" is bigger than the second dimension of the array "topo", namely 1440...
I'm encountering the following error when I run my main program.
Do you see the problem ? a = rand(4,5) a(1:3,4:6) "ymax" is bigger than the second dimension of the array "topo", namely 1440...
1 month 前 | 0
| 已接受
已回答
Rotate 3D mesh plot to show 2D view of X data on vertical axis and Z data on horizontal axis
x = -2:0.1:2; y = 0:0.1:1; [X,Y]=meshgrid(x,y); Z = X.^2+Y.^2; mesh(Z,Y,X) xlabel('Z') ylabel('Y') zlabel('X') view(0,0)...
Rotate 3D mesh plot to show 2D view of X data on vertical axis and Z data on horizontal axis
x = -2:0.1:2; y = 0:0.1:1; [X,Y]=meshgrid(x,y); Z = X.^2+Y.^2; mesh(Z,Y,X) xlabel('Z') ylabel('Y') zlabel('X') view(0,0)...
1 month 前 | 1
| 已接受
已回答
Matlab numerical simulation for ode system by changing the parameter value in range graph not running error coming
Your ODE system is stiff. Use "ode15s" instead of "ode45". The reason for the error you receive seems to be that you interrupte...
Matlab numerical simulation for ode system by changing the parameter value in range graph not running error coming
Your ODE system is stiff. Use "ode15s" instead of "ode45". The reason for the error you receive seems to be that you interrupte...
1 month 前 | 1
| 已接受
已回答
function input arguments error
Don't use isreal as a variable name: isreal is a MATLAB function that you overwrite this way. [y, is_real] = myquad(1, -2, 1); ...
function input arguments error
Don't use isreal as a variable name: isreal is a MATLAB function that you overwrite this way. [y, is_real] = myquad(1, -2, 1); ...
2 months 前 | 0
| 已接受
已回答
How to assign the multiple outputs of a function to a single vector AVOIDING TO MANUALLY ASSIGN EACH OUTPUT?
https://uk.mathworks.com/matlabcentral/answers/1808900-multiple-outputs-of-a-function-into-a-single-vector
How to assign the multiple outputs of a function to a single vector AVOIDING TO MANUALLY ASSIGN EACH OUTPUT?
https://uk.mathworks.com/matlabcentral/answers/1808900-multiple-outputs-of-a-function-into-a-single-vector
2 months 前 | 1
已回答
define 300 function calls x1(t)---x300(t)
You shouldn't use the way described here https://uk.mathworks.com/help/symbolic/solve-semilinear-dae-system.html to define a D...
define 300 function calls x1(t)---x300(t)
You shouldn't use the way described here https://uk.mathworks.com/help/symbolic/solve-semilinear-dae-system.html to define a D...
2 months 前 | 0
已回答
Solve Semilinear DAE System
I am not sure what Y is in these two lines. Y is the (numerical) vector of unknowns - in the example Y = [x,y,T,dx/dt,dy/dt]. ...
Solve Semilinear DAE System
I am not sure what Y is in these two lines. Y is the (numerical) vector of unknowns - in the example Y = [x,y,T,dx/dt,dy/dt]. ...
2 months 前 | 0
| 已接受