답변 있음
Getting an error message when I use 'triangle()' function.
close all; clearvars; clc; t = 0:0.01:10*pi; f = 5; A = 10; y = A * sawtooth(2*pi*t); figure, plot(t,y); xlim([0 2*pi])

4개월 전 | 0

답변 있음
Plotting Elastic Modulus Surface for TPMS Structure
direction = [cos(Theta(i))*sin(Phi(i)); sin(Theta(i))*sin(Phi(i)); cos(Phi(i))]

4개월 전 | 0

답변 있음
How do I get this to display the maximum value of an array?
max = maxval(2:100) function max=maxval(x) a=1; N=length(x); for j=1:N %for loop is not correctly used if x(j)>a ...

4개월 전 | 0

답변 있음
How to fine numerical gradient
There is another way to find the numerical gradient for the given function clear; clc; xs = linspace(1,2,100); ys = linspace(...

4개월 전 | 0

답변 있음
problem of solving the PDE
Cut all the lines from 1 till 16 and place it after line 26. Function declarations must be done at the end of the code in your...

4개월 전 | 1

답변 있음
How to plot five figures with different values?
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % This is a program for 1-D Photonic crystal...

4개월 전 | 0

| 수락됨

답변 있음
How to plot different subplots changing y variable name on each iteration
title(name) If you want to plot the data need to be numeric arrays and not strings

4개월 전 | 0

답변 있음
Generate list of frequencies evenly spaced in logarithmic plot
F = linspace(0.2,628,100) semilogy(F)

4개월 전 | 0

답변 있음
Not enough input arguements
anz=height(matrix) Put this line after *readtable* function where you read the data from Excel. The input to the function h...

4개월 전 | 0

답변 있음
How can I use custom equation in cftool?
In the custom equation, function box , replace the x with z and define the equation as in your case in the box below

4개월 전 | 0

| 수락됨

답변 있음
can someone assist I am struggling to convert the DHI DNI and GHI from W/m^2 to kWh/m^2
% solar irradiation on a HORIZONTAL SURFACE Cn = 0.7; % Clearance index I0 = 1353; % Solar constant latit...

5개월 전 | 0

답변 있음
"Arrays have incompatible sizes for this operation" with for loop in integral2
input = @(y,s) y; N_it=10; output=cell(1, N_it); output{1}=input; density = @(z,t,s) exp( -(z.^2)./(2.*(s-t)) ./ (sqrt(2...

5개월 전 | 0

답변 있음
Too many input arguments error when cell2mat and mean functions are used
bb = cell2mat(iniclu(i,1:count(i))); Use a ( ) in place of { }

5개월 전 | 1

답변 있음
Why won't my function display any of the required text?
%FinalGrade = FinalMark;

5개월 전 | 0

| 수락됨

답변 있음
I I wrote a command but for some reason it only prints the enthalpy value of water
There is a missing semicolon in this line, which makes it to print for each iteration in for loop H_water = (hf_w + hs_w); % a ...

5개월 전 | 1

답변 있음
Need help to solve following problem.
X_ISMD = 995152.969208341; Y_ISMD = 996113.117131325; X_WGS84 =randn(172,1); Y_WGS84 =randn(172,1); for i = 1:172 D1(i...

5개월 전 | 1

| 수락됨

답변 있음
How to simplify this script
Use abs percentage for error calculation percentage = abs((delta_y_ori-delta_y_raw)/delta_y_ori)*100;

5개월 전 | 0

| 수락됨

답변 있음
how to make the contour line more curvy
xdata % your x data ydata % your y data zdata % your z data v = min(min(zdata)):1:max(max(zdata)) % add finer step size for ...

5개월 전 | 0

답변 있음
Error code: "Index in position 2 exceeds array bounds (must not exceed 1)." when running code for two-element spring system
K(i,i) = K(i,i) + y(1,1); K(i,j) = K(i,j) + y(1,2);

5개월 전 | 0

답변 있음
Please I need help on Translating the following formulae into statements: 1) V=10(1− e0.2t ) (2) y =[e3t +t2 sin(4t)]cos2 (3t) Assume t as the row vector
t = 0:0.1:10; x = 10*exp(-0.5*t).*sin(3*t+2); y =exp(3*t)+t.^2 .* sin(4*t).*(cos(3*t)).^2 v = 10*(1-exp(0.2*t))

5개월 전 | 0

답변 있음
I keep getting the error using '/'.
condition=readmatrix('cases.xlsx','Sheet',1,'Range','A2:C65');

5개월 전 | 0

답변 있음
Indexing Error Using 'dsolve'
syms t k1 k2 M A0 A(t) dA_dt = 1 * (20 - A) - 3 * diff(A,t) == 0; % Solving for A(t) with different initial conditions A_s...

5개월 전 | 0

답변 있음
I wrote a piece of code about Calculating the Enthalpy of H2, O2, and Water and the machine reports the error "Array indices must be positive integers or logical values".
R = 8.314; % Ideal Gas Constant T = 300 : 50 : 1000; % Temperature range from 300 K to 1000 K with increments of 50 % Create T...

5개월 전 | 1

답변 있음
How to workaround this problem with angle?
You have real and imaginary componens for variable Fi, so use only real angles %total range of omega delta_omega=20; %interv...

5개월 전 | 1

답변 있음
Error that X is used but not initalized.
syms I O = 14.6*10^(-3)*I % define this way O(I) = 14.6*10^(-3)*I

5개월 전 | 0

답변 있음
pause() function not running in realtime
dt = 0.05 change the timestep size and try

5개월 전 | 0

답변 있음
Why the last err is a row vector of all zeros instead of a single zero?
clear;clc u=[1 2 0.1 0.2 3 4 30 40 50 60]; b=[1.1 1.2 0.11 0.21 33 44 31 41 51 61]; a1 = u(1:2); r1 = u(3:4); f1 = ...

5개월 전 | 0

| 수락됨

답변 있음
equation code not getting right answer
% Given values %AInfinity = 1; %AInlet = 6.5; MInlet = 0.5; MInfinity = 2; gamma = 1.4; a = (1 + ((gamma-1)/2)* MInfinit...

5개월 전 | 0

| 수락됨

더 보기