Beantwortet
How to plot equal equation at with 2 variable at each side. hard to simplift
For each value of albedo, you get 4 values for y that satisfy -900.*(1-albedo)==332.5-(y.^4).*(5.3865*10^-8)-((y-294.15)./3)-((...

fast 4 Jahre vor | 0

Beantwortet
Finding Unknown Parameters from Monod Equations
Works for me. t = [0 3 5 8 9.5 11.5 14 16 18 20 25 27]' ; x = [0.0904 0.1503 0.2407 0.3864 0.5201 0.6667 0.8159 0.9979 1.0673 ...

fast 4 Jahre vor | 0

Beantwortet
Newton Law - Cooling of a Cake
syms T(t) Tm k eqn = diff(T,t)==k*(T-Tm) T = dsolve(eqn) vars = symvar(T); C1 = vars(1); T = subs(T,Tm,70) eqn1 = subs(T,t...

fast 4 Jahre vor | 1

| akzeptiert

Beantwortet
how to solve this equation in matlab??
A = [3 0 -2;-1 2 0]; b = [-4;3]; sol_inhomogen = A\b; sol_homogen = null(A); sol = @(lambda) sol_inhomogen + lambda*sol_homo...

fast 4 Jahre vor | 0

Beantwortet
How can I calculate 5 lions in a row?
n = 1024; S = 0:(n-1); % 2^10 possible sequences of coin tosses. A = de2bi(S); A = [zeros(n,1),A,zeros(n,1)]; nn = 0; for i...

fast 4 Jahre vor | 0

| akzeptiert

Beantwortet
Runge kutta method (Variable Step)?
I don't know about the correctness of the code, but it claims to use adaptive time stepping: https://de.mathworks.com/matlabcen...

fast 4 Jahre vor | 0

| akzeptiert

Beantwortet
Problem of Symbolic function evaluation
u = sym('u',[2 1]); f = u.'*u result = subs(f,u,[1;2])

fast 4 Jahre vor | 0

| akzeptiert

Beantwortet
Why do I keep getting "no solution found" message?
Maybe a better code structure to debug the values "fsolve" gets from "sigmagap". You think that you know that "sigmagap" return...

fast 4 Jahre vor | 0

Beantwortet
How can one calculate Differentiation of matrix array with time as first column and data as second column ?
B = [A(:,1),gradient(A(:,2))./gradient(A(:,1)); plot(B(:,1),B(:,2))

fast 4 Jahre vor | 0

Beantwortet
How to select rows from an array?
B = [A(2,:);A(4,:);A(6,:)] or if you want the rows one by one: A2 = A(2,:); A4 = A(4,:); A6 = A(6,:);

fast 4 Jahre vor | 0

Beantwortet
I get an error when I try to run my logistic regression.
theta is not initialized - thus the theta(i) at the right-hand side of the assignment theta(i) = theta(i) - (alpha/m) * sum(er...

fast 4 Jahre vor | 0

Beantwortet
Curve fitting equation does not give the input z back
@Olaf Schipper Did you read that you have to use the normalized values for pA and T to evaluate mu(pA,T) ? f(x,y) = p00 + p10*...

fast 4 Jahre vor | 1

| akzeptiert

Beantwortet
calculate coefficients with linear regression
A = [ones(numel(xj),1),xj,xj.^2,exp(xj)]; b = yj; sol = A\b; a0 = sol(1) a1 = sol(2) a2 = sol(3) a3 = sol(4) where xj and...

fast 4 Jahre vor | 0

| akzeptiert

Beantwortet
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

fast 4 Jahre vor | 0

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

fast 4 Jahre vor | 1

| akzeptiert

Beantwortet
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...

fast 4 Jahre vor | 0

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

fast 4 Jahre vor | 0

Beantwortet
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...

fast 4 Jahre vor | 1

Beantwortet
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...

fast 4 Jahre vor | 0

Beantwortet
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...

fast 4 Jahre vor | 0

| akzeptiert

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

fast 4 Jahre vor | 0

| akzeptiert

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

fast 4 Jahre vor | 0

Beantwortet
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 ...

fast 4 Jahre vor | 0

Beantwortet
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...

fast 4 Jahre vor | 1

Beantwortet
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...

fast 4 Jahre vor | 0

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

fast 4 Jahre vor | 1

Beantwortet
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

fast 4 Jahre vor | 0

| akzeptiert

Beantwortet
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...

fast 4 Jahre vor | 1

| akzeptiert

Beantwortet
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)

fast 4 Jahre vor | 0

| akzeptiert

Beantwortet
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)) ...

fast 4 Jahre vor | 0

Mehr laden