Respondida
Plot an going down exponential curve by using values only
clear clc Vin=10; Vs=5; Vd=0.7; R1=2200; R2=3300; R3=linspace(0,1e5); x=R2/R1; for m=1:100 I(m)=R3(1,m)/R1; Vout(m)=(...

más de 3 años hace | 0

Respondida
MATLAB VECTOR FIELDS j COMPONENT
syms x y z i j k t r f = dot([x y z],[i j k]) ff = symfun(f,[x y z i j k]) subs(ff,{x y z},{1 0 0})

más de 3 años hace | 1

Respondida
Use a for loop to generate function arguments
data_i(i)=myfunction(d,d,d,...)

más de 3 años hace | 0

Respondida
Invalid expression. Check for missing multiplication operator, missing or unbalanced delimiters, or other syntax error. To construct matrices, use brackets instead of parenthe
fun = @(x) [0.00 0.00 0.01 -0.01 -0.01 -0.05 0.12 0.16 0.20 0.05 -0.02 0.11 0.06 0.04 -0.08 0.43 -0.26 -0.18 -0.12 -0.12]; ...

más de 3 años hace | 0

Respondida
Using listdlg, with muitlple selection to plot graphs
list = {'Rain','Sun','Snow','Wind'}; [indx,tf] = listdlg('ListString',list) if tf if strcmp(string(list(indx(1))),"Rai...

más de 3 años hace | 0

| aceptada

Respondida
I have these two errors when i try and run my script. Any help greatly appreciated
T = [T tmpt] From the error, it is possible that this condition T(find(T==-9.99)) = NaN; % is not satisfied in the last(...

más de 3 años hace | 0

Respondida
Putting a capacitor in the thread of the load distribution (backward and forward method)
You can obtain it by multiplying the Iline and V and display them in table LD = [%Line no. From To R ...

más de 3 años hace | 0

| aceptada

Respondida
I want to insert a matrix into RowNames that exist in a table.
h=[2,4,6,8,10,12,14,20,30,50,100,1000]'; t=[2,4,6,8,10,12,14,16,18,20]; u=h*t; q=strcat("T=",string(t'))'; p=strcat("h=",s...

más de 3 años hace | 0

| aceptada

Respondida
I want to send output values from MATLAB to an Excel file
FreqFinal = mean(freq) PeriodFinal = mean(period) error = midline-t amplitudeFinal= mean(max(y)-midline) Data_export = [Fr...

más de 3 años hace | 0

| aceptada

Pregunta


How can i use intersect function correctly ?
I tried the following code to use intersect function available in Matlab f=@(x)1+cos(x); g=@(x)sin(x); x=-8:.01:8; A = inter...

más de 3 años hace | 2 respuestas | 0

2

respuestas

Respondida
Using While Loop For Grouping Pie chart "Slices"
x= [0.66,0.38,0.01,0.01,0.13,0.01,1.38,3.96,1.04,0.01,0.39,0.38,0.36,0.32,2.61,2.73,0.01,0.95,1.94,0.01,0.01,1.18,1.42,0.01,0.37...

más de 3 años hace | 1

| aceptada

Respondida
Adding prefix to indexe
SourcePath ='/subf1/subf2/subf3/subf4/subf5/subf6/'; index = 1001 : 1002; %iteration for the 7th subfolder for i = 1 :...

más de 3 años hace | 0

| aceptada

Respondida
Why do I receive 'Error using sym>tomupad' in Line 6 when plotting impulse signal with right time shifting?
%create symbolic functions x, a, b, c, d, e, f_c with independent variable t syms x(t) a(t) h(t) b(t) c(t) d(t) e(t) f_c(t) x(...

más de 3 años hace | 1

| aceptada

Respondida
Contour not being rendered for non-finite data??
%crack length - for Kanalytical a = 0.1; K = sqrt(pi*a)*1000; %grid for results to look like plate, adjusting for crack edg...

más de 3 años hace | 0

Respondida
Physics costing electricity, KW/KWh
% assume P_rating = 2e3; % 2000 W = 2kW number_units = 50/7.5 % since each unit is treated as 1kWh @ 7.5p per unit run_time...

más de 3 años hace | 0

Respondida
Adding multiple cylinders into the same model PDE Toolbox
model.Geometry = [SC3d VS3d]

más de 3 años hace | 0

| aceptada

Respondida
How do I exit a for loop after logical index is found true in an array?
use inside the if-end statement % check if trajectory goes through the zone result = false; for i = 1:length(xNormalized) ...

más de 3 años hace | 0

| aceptada

Respondida
How to parameterize function.
syms x y z P = [x^2 +2*y +3*z; x*y -2*z^2] subs(P,{x,y,z},{t,t,t})

más de 3 años hace | 1

Respondida
"Matrix dimensions must agree" when trying to plot the sum of a sin function
s2 = sin((2*m-1)*x)./(2*m-1); Use element wise division

más de 3 años hace | 1

| aceptada

Respondida
Incorrect dimensions for raising a matrix to a power. Check that the matrix is square and the power is a scalar. To perform elementwise matrix powers, use '.^'.
The element wise power for a scalar should not affect much on your calculation unless vectors are multiplied or raised to power ...

más de 3 años hace | 0

Respondida
Z must be a matrix, not a scalar or vector.
t=0:30 % a vector x=(1+0.25.*cosd(45.*t)).*cosd(t); y=(1+0.25.*cosd(45.*t)).*sind(t); [X,Y] = meshgrid(x,y) % X and Y matr...

más de 3 años hace | 0

Respondida
Could anyone tell me why I am getting an error with "else" in my code. This is my first time using this software and I am very confused.
This is standard syntax for if-else statements in matlab if condtion ... elseif condition ... else ... end

más de 3 años hace | 1

| aceptada

Respondida
error: Index in position 2 exceeds array bounds (must not exceed 31).
clear all clc %Geometry definition L=0.3; %Length of the The rectangular bar in meter W=0.4; ...

más de 3 años hace | 0

Respondida
Is there a way of getting displayFormula to print multiplication (×) symbols in an equation?
syms a b strEquation = "a*b"; disp(strEquation)

más de 3 años hace | 0

Respondida
Hello all please help me to plot this function
The conditions seem wierd, considering random number series .as inputs m=4 syms i; % t = 50; for t=2:50 x(t)=randi([0...

más de 3 años hace | 0

Respondida
My code is giving me a straight line for values of N other than 5
clear variables close all M = 250; % The length of each function t = -5:0.1:5; y = zeros(1,M); % Initiallize the sum to zero...

más de 3 años hace | 0

Respondida
For loop not stopping
if ismember(-9999,aspect(i,1)) Check using ismember

más de 3 años hace | 0

Respondida
Bar graphs don't group bars if there is only one group in the data
like this ? % Artificial data: Two vertical vectors of height 3 x=reshape(randperm(6),3,2) % Correct grouping into pairs s...

más de 3 años hace | 1

| aceptada

Respondida
Using listdlg along with case statement
A = [15 22 25 17 7 3 2 2]; B = [17 23 27 15 5 2 1 1]; % ---^^^^^^^^ these values in B are higher compared to A length(B) le...

más de 3 años hace | 0

| aceptada

Respondida
Change plot scale y axis
u21=[224 224 224 223 218 218 217]; beta1=[0 0.19 0.26 0.38 0.76 0.83 0.9]; plot(beta1,u21,'-*'); xlabel('beta') ylabel('U[V]...

más de 3 años hace | 1

Cargar más