Answered

How to change values for variables that are defined in a equation

More like this perhaps (of course you will need to use your on values for the constants): a = [75, 96.4]; b = [13.8, 14.1]; c...

How to change values for variables that are defined in a equation

More like this perhaps (of course you will need to use your on values for the constants): a = [75, 96.4]; b = [13.8, 14.1]; c...

ongeveer 16 uur ago | 0

Answered

plotting is giving me multiple lines

A little more like this perhaps: %%%FIBER Ef=220e9;%[N/m] GPA to Newton/square meter Vf=.63; %fiber volume fraction vf=.33;%...

plotting is giving me multiple lines

A little more like this perhaps: %%%FIBER Ef=220e9;%[N/m] GPA to Newton/square meter Vf=.63; %fiber volume fraction vf=.33;%...

ongeveer 20 uur ago | 0

Answered

I try to find the air under the curve of this signal

Like this? datacq= load('Acquisition.txt'); datacq(:,1)=datacq(:,1)-datacq(1,1); t=datacq(:,1)*10^-3; accelerationz=abs(data...

I try to find the air under the curve of this signal

Like this? datacq= load('Acquisition.txt'); datacq(:,1)=datacq(:,1)-datacq(1,1); t=datacq(:,1)*10^-3; accelerationz=abs(data...

1 dag ago | 0

| accepted

Answered

ode45 second order

Matlab indices start at 1, so you want dy = [y(2); 3.6*sin(t) - 60*y(1) - 5*y(2)];

ode45 second order

Matlab indices start at 1, so you want dy = [y(2); 3.6*sin(t) - 60*y(1) - 5*y(2)];

2 dagen ago | 0

Answered

Implement the following formula

Change the square brackets, [ ], to curved brackets, ( ). Put a multiply sign, *, after the 3.

Implement the following formula

Change the square brackets, [ ], to curved brackets, ( ). Put a multiply sign, *, after the 3.

3 dagen ago | 0

Answered

How to Solve a Second-Order Differential Equation?

syms x y eqn2 = 'x*D2y+2*Dy-x*y=2*exp(x)'; dsolve(eqn2,x)

How to Solve a Second-Order Differential Equation?

syms x y eqn2 = 'x*D2y+2*Dy-x*y=2*exp(x)'; dsolve(eqn2,x)

3 dagen ago | 0

Answered

While solving with ode15 i want to put to the limit to variable.

Like this? opts = odeset('stats','on'); C0 = [6.21E-6, 0, 0, 0, 0]; %Initial Values (umol) tspan = 0:0.125:4400; %Time span...

While solving with ode15 i want to put to the limit to variable.

Like this? opts = odeset('stats','on'); C0 = [6.21E-6, 0, 0, 0, 0]; %Initial Values (umol) tspan = 0:0.125:4400; %Time span...

3 dagen ago | 0

Answered

How to get the factor format of a polynomial

syms x y=x^2-1; a = factor(y) b = a(1)*a(2)

How to get the factor format of a polynomial

syms x y=x^2-1; a = factor(y) b = a(1)*a(2)

3 dagen ago | 0

Answered

How to change values for variables that are defined in a equation

Since your equation is linear in x it's probably best to rewrite as in the following, and put all your a,b,c,d vaues into vector...

How to change values for variables that are defined in a equation

Since your equation is linear in x it's probably best to rewrite as in the following, and put all your a,b,c,d vaues into vector...

3 dagen ago | 0

Answered

Solve an exponencial equation

Plot a graph of your function first, to see roughly where the root is, then use fzero: f = @(k) exp((-3.8./sqrt(6.784-1221.21*k...

Solve an exponencial equation

Plot a graph of your function first, to see roughly where the root is, then use fzero: f = @(k) exp((-3.8./sqrt(6.784-1221.21*k...

4 dagen ago | 0

| accepted

Answered

Bessel problem "inf+ infi"

The following works with no inf or nan problems freq = linspace(4*1e6, 31*1e6, 100) ; w = 2*pi.*freq; % angular frequency p= ...

Bessel problem "inf+ infi"

The following works with no inf or nan problems freq = linspace(4*1e6, 31*1e6, 100) ; w = 2*pi.*freq; % angular frequency p= ...

6 dagen ago | 0

| accepted

Answered

Need help to solve 5 simultaneous first order differential equations with Initial Condition.

You have a stiff system (ka~10^6, kd~10^-4), so use ode15s rather than ode45. The following works. I'll leave you to decide if ...

Need help to solve 5 simultaneous first order differential equations with Initial Condition.

You have a stiff system (ka~10^6, kd~10^-4), so use ode15s rather than ode45. The following works. I'll leave you to decide if ...

6 dagen ago | 0

| accepted

Answered

How to avoid repetition in for loop that is using randi

Does randperm do what you want? help randperm

How to avoid repetition in for loop that is using randi

Does randperm do what you want? help randperm

7 dagen ago | 0

| accepted

Answered

Newton Raphson Method not solving

Try c3=-0.56; c4=0.182; c5=-0.09; c6=0.0102; Et=0.021; fn = @(x) c4*(2*x).^(c3) + c6*(2*x).^(c5) - Et; deriv = @(x) (c3)*...

Newton Raphson Method not solving

Try c3=-0.56; c4=0.182; c5=-0.09; c6=0.0102; Et=0.021; fn = @(x) c4*(2*x).^(c3) + c6*(2*x).^(c5) - Et; deriv = @(x) (c3)*...

7 dagen ago | 2

| accepted

Answered

Insert comment in the 4th quadrant of a subplot with Label and/or text

Like so? x = 0:0.1:10; y = sin(x); subplot(2,2,1) plot(x,y) subplot(2,2,2) plot(x,y+1/2) subplot(2,2,3) plot(x,y-1/2) s...

Insert comment in the 4th quadrant of a subplot with Label and/or text

Like so? x = 0:0.1:10; y = sin(x); subplot(2,2,1) plot(x,y) subplot(2,2,2) plot(x,y+1/2) subplot(2,2,3) plot(x,y-1/2) s...

7 dagen ago | 0

Answered

Creating and solving a polynomial equal to zero.

Something like this A = [-5000 1200 750 2000 1200; -200 150 60 40 50]; A = fliplr(A); % Do this in order to use the roots fun...

Creating and solving a polynomial equal to zero.

Something like this A = [-5000 1200 750 2000 1200; -200 150 60 40 50]; A = fliplr(A); % Do this in order to use the roots fun...

7 dagen ago | 1

| accepted

Answered

How can I solve a system of ODE's, in which the equations have a dependency on time, as well as the other ODEs?

By substituting the first into the second and then the second into the third you can write the last two as:

How can I solve a system of ODE's, in which the equations have a dependency on time, as well as the other ODEs?

By substituting the first into the second and then the second into the third you can write the last two as:

7 dagen ago | 0

Answered

Random dots to make a circle

Try something like n = 1000; t = 2*pi*rand(n,1); Ri = 1; Ro = 2; r = Ri + (Ro - Ri)*rand(n,1); x0 = 0; y0 = 0; x = x0 +...

Random dots to make a circle

Try something like n = 1000; t = 2*pi*rand(n,1); Ri = 1; Ro = 2; r = Ri + (Ro - Ri)*rand(n,1); x0 = 0; y0 = 0; x = x0 +...

7 dagen ago | 0

| accepted

Answered

PDF & CDF function

Use histogram to see the shape. Move_W_to_dBm has a double peak at low values, with an extremely long tail to the right (I dele...

PDF & CDF function

Use histogram to see the shape. Move_W_to_dBm has a double peak at low values, with an extremely long tail to the right (I dele...

7 dagen ago | 0

| accepted

Answered

I get 'error using sum' whenever I try to get the mean of some numbers.

mean([1.0411, 1.0184, ...etc]) Enclose the numbers within square brackets.

I get 'error using sum' whenever I try to get the mean of some numbers.

mean([1.0411, 1.0184, ...etc]) Enclose the numbers within square brackets.

8 dagen ago | 1

Answered

How to fit to an infinite series function when the independent variable contains an undetermined parameter?

fminsearch seems to do ok: x=[0 5 10 15 20 30 45 60 75 90 105 120]; y=[0 3.87 4.62 4.98 5.21 5.40 5.45 5.50 5.51 5.52 5.54 5.5...

How to fit to an infinite series function when the independent variable contains an undetermined parameter?

fminsearch seems to do ok: x=[0 5 10 15 20 30 45 60 75 90 105 120]; y=[0 3.87 4.62 4.98 5.21 5.40 5.45 5.50 5.51 5.52 5.54 5.5...

8 dagen ago | 0

| accepted

Answered

sequence convergence of sqrt(2)

I think you probably want X(k) = 0.5*X(k-1) + 1/(2*X(k-1)); with X(1) = 1;

sequence convergence of sqrt(2)

I think you probably want X(k) = 0.5*X(k-1) + 1/(2*X(k-1)); with X(1) = 1;

8 dagen ago | 0

Answered

Goertzel Algorithm for calculating amplitude and angle

Should it be more like this N = 80; % points/period f = 50; % Hz t = 0.02; % s TimeArray = 0:1/f/N:t; x = 2*cos(2*pi*f*Time...

Goertzel Algorithm for calculating amplitude and angle

Should it be more like this N = 80; % points/period f = 50; % Hz t = 0.02; % s TimeArray = 0:1/f/N:t; x = 2*cos(2*pi*f*Time...

9 dagen ago | 0

| accepted

Answered

The forward Euler scheme for an ordinary differential equation

More like this n=100; h=0.1; k=0; x(1)=0; y(1)=48; for k=1:n x(k+1)=x(k)+h; y(k+1)=y(k)+h*(9.8-0.196*y(k)); e...

The forward Euler scheme for an ordinary differential equation

More like this n=100; h=0.1; k=0; x(1)=0; y(1)=48; for k=1:n x(k+1)=x(k)+h; y(k+1)=y(k)+h*(9.8-0.196*y(k)); e...

9 dagen ago | 1

| accepted

Answered

Find values that put equation to zero

If your expression is equal to zero, then you can rearrange it to get gamma directly. A little algebra gives gamma = (C-M)./(S...

Find values that put equation to zero

If your expression is equal to zero, then you can rearrange it to get gamma directly. A little algebra gives gamma = (C-M)./(S...

10 dagen ago | 1

Answered

Finding X values of multiple lines for a given Y value

Never test for exact equality when dealing with floating point numbers. Use something like index_50 = find(abs(t_ind50-consta...

Finding X values of multiple lines for a given Y value

Never test for exact equality when dealing with floating point numbers. Use something like index_50 = find(abs(t_ind50-consta...

11 dagen ago | 0

| accepted

Answered

Normalized histogram with gaussian fit

Here's an example showing one possibility: gaussian = @(x, m,s) exp(-0.5*((x-m)/s).^2)/(s*sqrt(2*pi)); mu = 5; ...

Normalized histogram with gaussian fit

Here's an example showing one possibility: gaussian = @(x, m,s) exp(-0.5*((x-m)/s).^2)/(s*sqrt(2*pi)); mu = 5; ...

12 dagen ago | 0

| accepted

Answered

can you please help me solve this diffetential equation system?

You have log(t) in the definition of B. This causes problems at t = 0.

can you please help me solve this diffetential equation system?

You have log(t) in the definition of B. This causes problems at t = 0.

12 dagen ago | 0

Answered

How to solve an elliptical integral with the unknown in the integrand?

Here's how to use fzero to find C. However, with Re = 100 and alpha = 15deg, the boundary condition integral never reaches 1 fo...

How to solve an elliptical integral with the unknown in the integrand?

Here's how to use fzero to find C. However, with Re = 100 and alpha = 15deg, the boundary condition integral never reaches 1 fo...

12 dagen ago | 1

| accepted