Answered
How to set a RAM limit, so that if it gets passed, the simulation gets killed?
https://de.mathworks.com/matlabcentral/answers/34923-limiting-matlab-memory-usage

4 years ago | 0

Answered
L’Hospital’s rule
syms x a=x+2; b=x^2+3*x+2; c=a/b; limit(c,-2)

4 years ago | 1

| accepted

Answered
i want to solve a 297 linear equations with 298 unknown variables
My guess is that your equations are linear in the unknowns. If this is the case, try https://de.mathworks.com/help/symbolic/sym...

4 years ago | 0

Answered
Finding the sum to n of 1/2^n
format long n = 1:20; b = 1./2.^n; Sn = sum(b)

4 years ago | 0

Answered
Euler method with tabular inputs and multiple ODE's
The best way to refer to time-dependent data vectors in integration problems is to use "interp1". In your case above, e.g., de...

4 years ago | 1

Answered
How to use ODE4 to solve second order ODE
ode4 works with 1st order systems of ODEs. Yours is a 2nd order equation. Can you write your equation as a system of two first...

4 years ago | 0

Answered
Find maximum of quadratically constrained quadratic problem using MATLAB
Is this the simplified version of the problem you are trying to solve ? It seems fmincon gives the correct solution. N = 4; h...

4 years ago | 0

| accepted

Answered
Reference for the optimizePath function?
https://de.mathworks.com/help/pdf_doc/nav/index.html

4 years ago | 0

| accepted

Answered
Reference for the optimizePath function?
https://de.mathworks.com/help/pdf_doc/nav/index.html

4 years ago | 0

Answered
how to solve logarithm equation
log10(4*x)-log10(3*x) = log10((4*x)/(3*x)) = log10(4/3) log10(5*x)-log10(2*x) = log10((5*x)/(2*x)) = log10(5/2) So you try to ...

4 years ago | 0

Answered
Unrecognized function or variable 'ode4'.
Look below at how k_1,...,k_4 must be computed in the case that your ODE function only depends on t, not y. The classical Runge...

4 years ago | 1

Answered
Can I use mvncdf for Y=P[V(1)<XU(1), XL(2)<=V(2)<=XU(2)]?
You set XL(i) = -Inf. What's the problem ? xl(1) = -Inf; xu(1) = 0; xl(2) = -5; xu(2) = -2; mu = [0 0]; sigma = [1 0;0 1...

4 years ago | 0

Answered
Faster implementation of laguerreL
Maybe len = 1:100; [I,J] = meshgrid(len,len); output = laguerreL(I,J,2)

4 years ago | 1

Answered
Matrix column selection based on vector with indices
k=ones(6,4); v=randi(size(k,2),1,size(k,1)); v(end) = 0 idx = find(v>0) k(sub2ind(size(k),idx,v(idx))) = 0

4 years ago | 0

| accepted

Answered
finding a function with 4 variables
I suggest you start with height = a + b * sugar + c * yeast + d * flour If height,sugar, yeast and flour are column vectors of...

4 years ago | 1

| accepted

Answered
compact way to calculate euclidean distance among points
% x_a, y_a a = [0,0]; % x_b, y_b b = [0,1; 2,1; 1,1; 1,3]; D = pdist2(a,b)

4 years ago | 0

| accepted

Answered
For loop skipping with if statement
The usual average would be pk(a,2) = ( pk(a-1,2)*(pk(a,1)-pk(a-1,1)) + pk(a+1,2)*(pk(a+1,1)-pk(a,1)) )/(pk(a+1,1)-pk(a-1,1)) ...

4 years ago | 0

Answered
Anyone know how to solve 2*x^2+2*y^2=5, x*y=1 without using command syms?
x = roots([2 0 -5 0 2]) y = 1./x res1 = 2*x.^2+2*y.^2-5 res2 = x.*y-1

4 years ago | 1

| accepted

Answered
May I ask what MATLAB code for expected value is by fitting a Poisson distribution?
A = 1:100; lambdahat = poissfit(A)

4 years ago | 0

| accepted

Answered
Linear Fitting starting from a value
Sure. Use l(x) = a*x + 100 as model function and fit the parameter a. xdata = ...; % your xdata as column vector ydata = ...

4 years ago | 0

| accepted

Answered
how to fill a matrix without using loop in matlab?
If you want to plot the partial sums of the Fourier series, you will have to keep the last loop, I guess. close all; clear; clc...

4 years ago | 0

Answered
How to plot the variations for integrating parameter
Note that integral(H2Ox, 183000, Inf) = Inf !! H2Ox = @(EA) -0.0023*(-8/(48000^8))*(EA-183000).^7; H2Oz = @(y) integral(H2Ox, ...

4 years ago | 0

| accepted

Answered
Solve the complex equations
syms x real syms y real a=2*(x+y*j)==6-3j; sol = solve(a,[x,y]); sol.x sol.y

4 years ago | 0

| accepted

Answered
I would like to make surface plot of my probability of failure curve?
clear all; mue=0.82; %mean of unbiased factor of study case sige=0.189; %SD of unb...

4 years ago | 0

| accepted

Answered
How can I put a loop here?
V = [0.5 1 2 3 4 6 10].'; del = 0:1:90; del_r = del.*pi./180; x = V.*tan(del_r); del_r2 = atan(x); del2 = del_r2*180./pi;...

4 years ago | 0

| accepted

Answered
WATERMODEL returns a vector of length 825, but the length of initial conditions vector is 3. The vector returned by WATERMODEL and the initial conditions vector must have the
% Load file with variables temperature, ET etc, %% data=readtable("https://de.mathworks.com/matlabcentral/answers/uploaded_fil...

4 years ago | 0

| accepted

Answered
can any one tell me why this error has occurred.
i is a vector (at least when the loop index LL is 2, for LL = 1 i is taken as the imaginary unit because it's not yet defined), ...

4 years ago | 0

| accepted

Answered
How can I use fzero on these two functions?
Use the original equation. Why do you take log on both sides - it only implies problems for x <= 3/4. f = @(x)4*x-3-exp(-0.1*x)...

4 years ago | 0

Answered
how do i get the the fifth and fourth number form behind?
x = [2361273621, 2937812378, 2367823827]; b = arrayfun(@(a)num2str(a),x,'uni',0); b = arrayfun(@(i)b{i}(end-4:end-3),1:length(...

4 years ago | 0

Answered
Plotting using MATLAB problem
https://www.youtube.com/watch?v=GrpDgOjR5ZA

4 years ago | 0

Load more