Beantwortet
I couldn't understand why this program is not working, is my all variable algorithm is correct?
You need to interchange the variables to the function rate_eq. Try this: ti = 0; tf = 10E-4; tspan=[ti tf]; y0=[9;9;1;1;0].*...

fast 4 Jahre vor | 0

| akzeptiert

Beantwortet
How to do Taylor expansion without commands?
Check the formula for exp(x), you made few mistakes.... n = input('ingrese valor de n '); x = input('ingrese valor de x '); ...

fast 4 Jahre vor | 1

| akzeptiert

Beantwortet
how to write a code using while end loop for display of number from 10 to 1 descending order ?
n = 10 ; while n ~= 1 n = n-1 end

fast 4 Jahre vor | 0

| akzeptiert

Beantwortet
How to combine the discrete bands of x-values to a continous plot?
load('X.mat') ; load('Y.mat') ; load('C.mat') ; X = T_mag3 ; Y = E3(1,:)' ; Z = FESA3 ; pcolor(X,Y,Z) shading interp

fast 4 Jahre vor | 0

| akzeptiert

Beantwortet
generate pair numbers randomly
Say you want to pair numbers randomly between 1 to 20. n = 10 ; iwant = zeros(n,2) ; for i = 1:n iwant(i,:) = randper...

fast 4 Jahre vor | 0

Beantwortet
how to remove arrows in streamslice plot?
clc, clear, close; X = linspace(0,1.5); Z = linspace(-3,3); [z,x] = meshgrid(Z,X); ui = -0.04545*x.^2.*z; vi = x.*(...

fast 4 Jahre vor | 0

| akzeptiert

Beantwortet
How to mask a data using the contour closed line?
Read about inpolygon. Using this you can get the indices lying inside and outside the closed shape. Using tese indices you can m...

fast 4 Jahre vor | 0

Beantwortet
How to plot the surface of the parabolic cylinder $y^2=8x$ in the first octant bounded by the planes $y=4$ and $z=6$?
y = linspace(0,4) ; z = linspace(0,6) ; [Y,Z] = meshgrid(y,z) ; X = Y.^2/8 ; surf(X,Y,Z)

fast 4 Jahre vor | 0

| akzeptiert

Beantwortet
Plot x(t) by calling a function
You are entering t as single number into the function. Try this: clc clear close all m=input('Please enter mass : ') ; c=in...

fast 4 Jahre vor | 0

| akzeptiert

Beantwortet
simplifying kinda-eye matrix of NxN, how?
A = rand(3) ; [m,n] = size(A) ; iwant = zeros(4*m,4*n) ; for i = 1:4 idx = (1:m)+(i-1)*3 ; iwant(idx,idx)=A; end...

fast 4 Jahre vor | 0

| akzeptiert

Beantwortet
I just want to plot these two graphs on top of each other! When I run, I get one but not both. Thank you!
You are getting two plots, but your T_a abd T_b are exactly equal. Thats why they are lying one above the other. clear all; c...

fast 4 Jahre vor | 0

Beantwortet
Plot an equation by calling a function
It looks like your e in the function is exp. Change the function to: function [y]=myfun(a,b,c,t) if (a*b/c>1) y = (exp(a)...

fast 4 Jahre vor | 0

Beantwortet
I am just trying to plot the distance x v. Temp function below. I want it to take the x values from 0 to 0.15. Thank you!
Presently in your code x is a single number 0. You need to change that line. clc; clear all ; clear all; close all; clc; %...

fast 4 Jahre vor | 1

| akzeptiert

Beantwortet
how to give value stress from excel give color in my mesh thin cylinder
You have extracted the stress at the mid point of the element. You need to extract the stress values at every node. warning of...

fast 4 Jahre vor | 0

Beantwortet
Change only coordinates of a georeferenced tif file from utm to degree
You may use the following file exchange function to convert utm to degree. https://in.mathworks.com/matlabcentral/fileexchange...

fast 4 Jahre vor | 0

Beantwortet
To find the maximum value column index of a cell array
[m,n] = size(A) ; val = cell(m,n) ; id = cell(m,n) ; for i = 1:m for j = 1:n [val{i,j},id{i,j}]=max(A{i,j}) ; ...

fast 4 Jahre vor | 0

| akzeptiert

Beantwortet
Changing numbers summed together in for loop
t = 1:1:30; %increasing time intervals of interest up to Trw nt = 28594; Qt = 0 ; for a = 1:length(dt) Qtime = (Q_ots(a+1)-...

fast 4 Jahre vor | 0

| akzeptiert

Beantwortet
Error in multiplication of arrays
Check this: nchoosek(m1-(2.*s2),j1) this is giving you an expty matrix. A = rand(1,5) ; B = zeros([],1) A*B Use nchoosek...

fast 4 Jahre vor | 0

Beantwortet
I want to need (maxY(:,1)) for different value of k, how the for loop will help?
ti = 0; tf = 100E-4; tspan=[ti tf]; y0=[1;1;1;1;1].*10E-2; k =[0:0.1E-3 : 3E-3] ; iwant = zeros(length(k),1) ; for i = ...

fast 4 Jahre vor | 1

| akzeptiert

Beantwortet
Why it is not making plot for different values of "M"?
You have to use hold on. syms x warning off alpha = -0.1; sigma = 0.1; eps = -0.1; e = 0.2; a = 2; lambda = 2; psi = ...

fast 4 Jahre vor | 0

| akzeptiert

Beantwortet
How to get the neural network outputs after nftool in R2022a
After training and testing with your data, when you click on Next button, you will get option of Deploy Solution, at this stage ...

fast 4 Jahre vor | 0

Beantwortet
Find intersection of points in a graph
You can consider using this: https://in.mathworks.com/matlabcentral/fileexchange/22441-curve-intersections?requestedDomain=

fast 4 Jahre vor | 0

Beantwortet
How to plot a box onto an existing convex hull graph?
XData = rand(100,1) ; YData = rand(100,1) ; figure(1); scatter(XData,YData); hold on; Hull = convhull(XData,YDa...

fast 4 Jahre vor | 1

| akzeptiert

Beantwortet
create a sparse multidimensional matrix
A = sparse(12,3) ; A(3,1) = 1 ; A(7,2) = 1 ; A(11,3) = 1 ; A full(A)

fast 4 Jahre vor | 0

Beantwortet
mpower doesn't work with symbolic matrix
syms A 2 matrix syms n assume(n, {'integer', 'positive'}) A.^n

fast 4 Jahre vor | 0

Beantwortet
How can I create a quadratic matrix with variables?
syms q [1 5] real iwant = q'*q

fast 4 Jahre vor | 1

Beantwortet
Mean of an Array Containing some NAN Elements
Read the doc of mean, there is option of omitting nan. A = [1 2 NaN 3 4 NaN] ; mean(A,'omitnan') In older versions it is nanm...

fast 4 Jahre vor | 0

| akzeptiert

Beantwortet
Find duplicate of first xx entries and average associated values
Read the file into MATLAB using readtable. See to it that your dates i.e. thirs column is in datetime class. For this read abou...

fast 4 Jahre vor | 0

Beantwortet
To find the maximum value in each column of a cell array.
Let A be your cell array of size 3072*2 where each cell has a matrix of size 5x1295. [m,n] = size(A) ; iwant = cell(m,n) ; fo...

fast 4 Jahre vor | 2

| akzeptiert

Beantwortet
Align signals of different length using Peak
According to the plot, the peak value which has longest id is third array. So, I would allign signals w.r.t to third array. ...

fast 4 Jahre vor | 0

Mehr laden