Answered

How to draw the contour lines in MATLAB.

data = readmatrix('Sai.xlsx'); contour(data, 0.1:0.1:1) colorbar

How to draw the contour lines in MATLAB.

data = readmatrix('Sai.xlsx'); contour(data, 0.1:0.1:1) colorbar

ongeveer 3 uur ago | 0

Answered

Supress Warning in a Loop

X=X-inv(j)*f; replace with if rank(j)<length(j) X = nan; else X = X - j\f; end

Supress Warning in a Loop

X=X-inv(j)*f; replace with if rank(j)<length(j) X = nan; else X = X - j\f; end

ongeveer 4 uur ago | 1

Answered

How to reorder a vector one cell at a time?

Okay, so the problem is that the rules are not exactly as you describe. The algorithm Start at the top of the column, and reme...

How to reorder a vector one cell at a time?

Okay, so the problem is that the rules are not exactly as you describe. The algorithm Start at the top of the column, and reme...

ongeveer 13 uur ago | 0

Answered

how to solve an equation iteratively?

syms x eqn1 =200 == x*(1-(0.4*(x-1))/sqrt(2.8*2.4*x+0.4))^(-2.8/0.4); sol = solve(eqn1, x); sol = sol(imag(sol) == 0) vpa(so...

how to solve an equation iteratively?

syms x eqn1 =200 == x*(1-(0.4*(x-1))/sqrt(2.8*2.4*x+0.4))^(-2.8/0.4); sol = solve(eqn1, x); sol = sol(imag(sol) == 0) vpa(so...

ongeveer 16 uur ago | 0

| accepted

Answered

Inverse a cell of matrices

T1inv = cellfun(@inv, T1, 'uniform', 0); However, most of the time you should avoid using inv() . It is not common that you nee...

Inverse a cell of matrices

T1inv = cellfun(@inv, T1, 'uniform', 0); However, most of the time you should avoid using inv() . It is not common that you nee...

ongeveer 16 uur ago | 0

Answered

error: Unrecognized function or variable 'y', using ode45

function main a = 0.01725*exp(2660/300); E = 2660; T0 = 300; Cao = 2; cpa = 20; cpb = 20; nao = 2*1200; nbo = 2*1200; ...

error: Unrecognized function or variable 'y', using ode45

function main a = 0.01725*exp(2660/300); E = 2660; T0 = 300; Cao = 2; cpa = 20; cpb = 20; nao = 2*1200; nbo = 2*1200; ...

ongeveer 17 uur ago | 2

| accepted

Answered

while loop for changing vairable

theta = [-90:5:90] M = sind(theta); N = cosd(theta); T = arrayfun(@(m,n)[m^2 n^2 0 0 0 2*m*n; n^2 m^2 0 0 0 -2*...

while loop for changing vairable

theta = [-90:5:90] M = sind(theta); N = cosd(theta); T = arrayfun(@(m,n)[m^2 n^2 0 0 0 2*m*n; n^2 m^2 0 0 0 -2*...

ongeveer 18 uur ago | 0

| accepted

Answered

How to skip vpasolve empty sym inside a loop

Store the result of vpasolve into a variable. Test to see if it is empty before storing into the matrix.

How to skip vpasolve empty sym inside a loop

Store the result of vpasolve into a variable. Test to see if it is empty before storing into the matrix.

ongeveer 18 uur ago | 0

| accepted

Answered

Index exceeds array bounds... need some help please!

i= [1:100]; x(i)= 100; You initialize 100 elements for i=[1:100] Tf(i+1)=x(i+1); You try to access 100+1 elements Also...

Index exceeds array bounds... need some help please!

i= [1:100]; x(i)= 100; You initialize 100 elements for i=[1:100] Tf(i+1)=x(i+1); You try to access 100+1 elements Also...

ongeveer 19 uur ago | 0

Answered

covert data as matrix

Q =(unifrnd(0,1,5,15)) save('Q.txt', 'Q', '-ascii', '-double') !cat Q.txt

covert data as matrix

Q =(unifrnd(0,1,5,15)) save('Q.txt', 'Q', '-ascii', '-double') !cat Q.txt

1 dag ago | 1

| accepted

Answered

Why does symbolic integration return the wrong answer for this integral?

syms x a expr = 1/(1-x)^2 F = int(expr, x, 0, a) subs(F,a,x)

Why does symbolic integration return the wrong answer for this integral?

syms x a expr = 1/(1-x)^2 F = int(expr, x, 0, a) subs(F,a,x)

1 dag ago | 2

| accepted

Answered

Plot function adding line from last point in row to origin

In order to see that plot with multiple lines, your y_nudged must be 2D. The following code takes that into account. xt = x_nud...

Plot function adding line from last point in row to origin

In order to see that plot with multiple lines, your y_nudged must be 2D. The following code takes that into account. xt = x_nud...

1 dag ago | 0

Answered

Creating grid with incremental numbers around specific coordinate

N = 5; r = 2; c = 3; temp = true(N,N); gr = bwdistgeodesic(temp, c, r) + 1

Creating grid with incremental numbers around specific coordinate

N = 5; r = 2; c = 3; temp = true(N,N); gr = bwdistgeodesic(temp, c, r) + 1

1 dag ago | 0

| accepted

Answered

Table properties giving error

You have a third-party function named split on your MATLAB path. which -all split

Table properties giving error

You have a third-party function named split on your MATLAB path. which -all split

1 dag ago | 0

| accepted

Answered

need help with this summation

zeta = reshape(linspace(0,2), 1, [], 1); %row fo = reshape(logspace(-2,0,50), [], 1, 1); %column n = reshape(1:2:101, 1,...

need help with this summation

zeta = reshape(linspace(0,2), 1, [], 1); %row fo = reshape(logspace(-2,0,50), [], 1, 1); %column n = reshape(1:2:101, 1,...

1 dag ago | 0

Answered

'Matrix dimensions must agree' error in matlab app designer

function botonButtonPushed(app, event) if app.menu.Value=="engranaje" app.caja.Value=1 ...

'Matrix dimensions must agree' error in matlab app designer

function botonButtonPushed(app, event) if app.menu.Value=="engranaje" app.caja.Value=1 ...

1 dag ago | 0

| accepted

Answered

why matlab calls (pixel per inch "PPI") a (dot per inch "DPI") ?

the DPI term indicates to a something related to printing terminology which is dot ink per inch unit, Although it did certainly...

why matlab calls (pixel per inch "PPI") a (dot per inch "DPI") ?

the DPI term indicates to a something related to printing terminology which is dot ink per inch unit, Although it did certainly...

1 dag ago | 0

| accepted

Answered

How can I represent the following equation in code?

w = linspace(-5,5); hejw = abs(besselh(1, exp(1j*w))); mask = 0.7943 <= hejw & hejw <= 0.8913; plot(w, hejw, 'k-'); hold...

How can I represent the following equation in code?

w = linspace(-5,5); hejw = abs(besselh(1, exp(1j*w))); mask = 0.7943 <= hejw & hejw <= 0.8913; plot(w, hejw, 'k-'); hold...

1 dag ago | 0

Answered

how to save the output image

infile = 'ISIC_0024336.jpg'; citra=imread(infile); figure, fig1=imshow(citra); load mri V = squeeze(citra); citra3=montag...

how to save the output image

infile = 'ISIC_0024336.jpg'; citra=imread(infile); figure, fig1=imshow(citra); load mri V = squeeze(citra); citra3=montag...

1 dag ago | 0

| accepted

Answered

matlab gives wrong graphical display info

https://www.mathworks.com/help/matlab/creating_guis/dpi-aware-behavior-in-matlab.html

matlab gives wrong graphical display info

https://www.mathworks.com/help/matlab/creating_guis/dpi-aware-behavior-in-matlab.html

1 dag ago | 0

| accepted

Answered

Calculation of a precise point after indefinite integral

syms Sy IXX syms d R y_a = @(d,R) R*sin(d) ; q_o_a(d, R) = -(Sy/IXX)*int(y_a(d,R)*R*t,d) ; q_1 = q_o_a(pi/2, R) ; ...

Calculation of a precise point after indefinite integral

syms Sy IXX syms d R y_a = @(d,R) R*sin(d) ; q_o_a(d, R) = -(Sy/IXX)*int(y_a(d,R)*R*t,d) ; q_1 = q_o_a(pi/2, R) ; ...

1 dag ago | 0

Answered

how to estimate/evaluate the integral of a constant value function?

syms t a b real f = piecewise(0 < t & t < 1, 5, 0) int(f, t, a, b)

how to estimate/evaluate the integral of a constant value function?

syms t a b real f = piecewise(0 < t & t < 1, 5, 0) int(f, t, a, b)

1 dag ago | 0

| accepted

Answered

MATLAB no longer displaying fractions in symbolic calculation.

sympref('FloatingPointOutput', false)

MATLAB no longer displaying fractions in symbolic calculation.

sympref('FloatingPointOutput', false)

1 dag ago | 1

| accepted

Answered

An efficient way to compute many sums with different number of terms

cumsum() and index it by the values

An efficient way to compute many sums with different number of terms

cumsum() and index it by the values

1 dag ago | 0

Answered

Determine Critical Points Numerically

EA=30000; alpha=30; beta=30; gamma=180-(alpha+beta); a=20; n=6; L_ab=a; L_bc=(a*sind(alpha))/(sind(beta)); L_ac=(a*sind(...

Determine Critical Points Numerically

EA=30000; alpha=30; beta=30; gamma=180-(alpha+beta); a=20; n=6; L_ab=a; L_bc=(a*sind(alpha))/(sind(beta)); L_ac=(a*sind(...

1 dag ago | 0

Answered

Can we plot streamilnes, isotherms and isocontour plots in MATLAB?

streamline: https://www.mathworks.com/help/matlab/ref/streamline.html Isotherms would be https://www.mathworks.com/help/matlab...

Can we plot streamilnes, isotherms and isocontour plots in MATLAB?

streamline: https://www.mathworks.com/help/matlab/ref/streamline.html Isotherms would be https://www.mathworks.com/help/matlab...

1 dag ago | 0

| accepted

Answered

Need to figure out how to find the average.

You are intended to loop over the rows for this task, not process the entire data first. Extract a row. Take nanmean of the row...

Need to figure out how to find the average.

You are intended to loop over the rows for this task, not process the entire data first. Extract a row. Take nanmean of the row...

1 dag ago | 0

Answered

How do I only show 1 output instead of all the outputs as a result of the matrix

num = randi(10,3,2); [row1,col1]=size(num); foundit = false; for a=1:row1 for b=1:col1 if num(a,b) == 7 ...

How do I only show 1 output instead of all the outputs as a result of the matrix

num = randi(10,3,2); [row1,col1]=size(num); foundit = false; for a=1:row1 for b=1:col1 if num(a,b) == 7 ...

1 dag ago | 1

| accepted

Answered

What is wrong with this optimization code using fmincon?

OBJFUN = @(A) 1/N *sum ( ( ( GeRT_model(A) .- GeRT_exp ) ./ GeRT_exp ).^2 ); ^^ ...

What is wrong with this optimization code using fmincon?

OBJFUN = @(A) 1/N *sum ( ( ( GeRT_model(A) .- GeRT_exp ) ./ GeRT_exp ).^2 ); ^^ ...

1 dag ago | 0

Answered

How do I find the average/mean of each row if the data has 150 rows and 3 columns?

A = 'measurements'; That assigns the character vector ['m' 'e' 'a' 's' 'u' etc] to A, not the content of a variable named measu...

How do I find the average/mean of each row if the data has 150 rows and 3 columns?

A = 'measurements'; That assigns the character vector ['m' 'e' 'a' 's' 'u' etc] to A, not the content of a variable named measu...

1 dag ago | 0