Respondida
Save .fig file as .eps file
plot(1:10) saveas(gcf,'Linechart','epsc')

alrededor de 3 años hace | 0

Respondida
Subscript indices must either be real positive integers or logicals.
[XX,YY] = meshgrid(linspace((Lat1(minlat),(Lat1(maxlat),n),linspace((Lon1(minlon)),(Lon1(maxlon),n))

alrededor de 3 años hace | 0

Respondida
How to make x-axis logarithmic for errorbar plot?
Use *semilogx* function

alrededor de 3 años hace | 0

Respondida
Boxplot and Plot Overlay Problem
As you say, X, Y1 , Y2 are same size and since Y2 (c) is a vector with mean of each year, plot the graph using the unique va...

alrededor de 3 años hace | 0

Respondida
Reynolds stress plot error
clear all; close all; clc; U_inf = 100; % free stream velocity in m/s L = 1; % plate length in m nu = 1.5e-5; % kinematic v...

alrededor de 3 años hace | 0

| aceptada

Respondida
Why am I getting an error for mismatched number of elements?
Few changes that may be required are below. Test your code after those changes x = zeros(n,1); for i = 1:n .. S = ...

alrededor de 3 años hace | 0

Respondida
How to pass on arguments in the form of two grids and return a matrix the elements of which involve conditional statements?
N = 4; DT = 1/N; t = linspace(DT/2, 1-DT/2, N)'; r = t + 0.3 * DT; [rr, tt] = ndgrid(r, t); a = f(rr, tt) function ...

alrededor de 3 años hace | 0

Respondida
How to extend a vector continuously in a loop
ini_vector=[par.nN2_in par.nH2_in 0 0 0.01 0 0 0 0 0.999]; Initial = repmat(ini_vector,1,8)

alrededor de 3 años hace | 0

| aceptada

Respondida
2D array to 1D with rows appending after another row
A = A.' A(:)

alrededor de 3 años hace | 1

Respondida
I need help plotting using this while loop
xx = linspace(-5,9,85); w=0 while w<85 w=w+1; fxx(w) = ((xx(w)+1)^2)./(2+5*xx(w)); end plot(xx,fxx)

alrededor de 3 años hace | 1

| aceptada

Respondida
My Code is giving indexing error, I am unable to fix it.
one way to verify the exact and approximate solutions is to vary boundary conditions suitably , % Clear all variables and clos...

alrededor de 3 años hace | 0

Respondida
I am trying to do numerical integration to find the work out in a problem with less than 0.1% error.
From your comments in the code, as i understand if the temperature is < 300K , then efficiency is not possible to evaluate. I h...

alrededor de 3 años hace | 0

Respondida
I'm running into an error at line 40, which is prompting me that I have an "invalid or deleted object". I'm wondering how to mend this.
P0 = [1,2,3]; P1 = [2,4,5]; P2 = [3,4,5]; P3 = [50,2,3]; P = [P0;P1;P2;P3]; t = linspace(0,1,100); tint = length(t); A = one...

alrededor de 3 años hace | 0

Respondida
how to transform a table with column names into an double array without column names
X = table2array(X(:,2:end)) Try as above

alrededor de 3 años hace | 0

Respondida
im trying to model the drive train model of wind turbine, i need to get oscillation and the steady state waveform
Provide all inputs to the equations used for modeling the drive train, clc clear all close all a=3.2; %input('Enter the a =...

alrededor de 3 años hace | 1

| aceptada

Respondida
How to build a vector in MATLAB
Labels = 16; r = 6; C1 = 1:Labels C_labels_train = (repelem(C1,r))' C_labels_test = [C_labels_train; C_labels_train; C_labels...

alrededor de 3 años hace | 0

| aceptada

Respondida
Hi everyone, why do I receive "Test Results: Incorrect!" even if i'm doing exactly what is shown in the solution? MATLAB Onramp
You are plotting code from lines 9 to 14 if the condition *doPlot == 1*, Instead of 5 to 8. Place the if statement beginning fro...

alrededor de 3 años hace | 1

| aceptada

Respondida
Saving results of a for loop in a cell array
NewCell = cell(1,numel(DataFrame)); %creat an empty cell for the results for iAnimal = 1:numel(DataFrame) %repeat for each...

alrededor de 3 años hace | 1

| aceptada

Respondida
How to create cp-λ characteristics curve, for different values of the pitch angle β for Wind Turbine block?
c1 = 0.5176; c2 = 116; c3 = 0.4; c4 = 5; c5 = 21; c6 = 0.0068; Beta = linspace(-2,24,10); Lambda = linspace(0,15,20); ...

alrededor de 3 años hace | 1

| aceptada

Respondida
Why am I getting an error message on my code?
numThrows = 10; numTrials = 30; [estPiAve, estPiStD] = estPiStats(numThrows,numTrials) % provide all input arguments when ca...

alrededor de 3 años hace | 0

Respondida
How do I append my answers in an array, while using loop?
z = 6; w = 5; syms x y eqn1 = x + y + z + w == 13; eqn2 = 2*x + 3*y - w == -1; A = [6 5; zeros(10,2)]; % create matri...

alrededor de 3 años hace | 0

| aceptada

Respondida
When defining an anonymous function, how do I utilize cell indexing of an intermediate function?
Try something like below epsTarray = @(x1,x2,x3,x4,x5,x6,x7,x8,x9,x10) ... expression y = epsTarray(n(1),n(2),n(3),n(4),n(5...

alrededor de 3 años hace | 0

Respondida
How can I rectify this error? 'Invalid use of Operator.' 'Too many Output arguements'
%Input % MU_X [n x 1] Expected value of x. % SIGMA_X [n x n] Covariance of x. % A [m x n] Linear...

alrededor de 3 años hace | 0

Respondida
Issues plotting simple bar graph.
A = [0.1; 0.4; 1.1; 2.2; 2.5; 0.2; 2.5; 2.2; 1.1; 0.4; 0.1]; B = [25; 20; 15; 10; 5; 0; 5; 10; 15; 20; 25]; bar(A); xti...

alrededor de 3 años hace | 0

| aceptada

Respondida
The numbers do not appear in standard format despite the writing (format shortG)
Use %f format specifier format shortG Mf=6.480554950317725e+03 Cp_sea=3.976; t_out=100; t_in=25; Qu=Mf*Cp_sea*(t_out-t_...

alrededor de 3 años hace | 0

Respondida
what is the meaning of this error? how to stop this error?
If you have function % assuming the below line is not present as per your comments % For context, I am using this as a calli...

alrededor de 3 años hace | 0

Respondida
Getting Naan error while integrating with multiple parameters
h=6.63*(10^-34); k=1.381*(10^-23); c=3*(10^8); T=6000; fun = @(x) (2*h*(c.^2)).*(x.^(-5)).*(exp((h.*c)./(k*x*T))-1).^(-1);...

alrededor de 3 años hace | 0

Respondida
Error using plot. Data must be numeric, datetime, duration or an array convertible to double.
% syms n A0 = 5/4; An= 0; T = 2; Wo = pi; t=linspace(0,5*T,1000); Arm = 5; hold on for n=1:1:Arm Bn = (5*(-1)^n)/(...

alrededor de 3 años hace | 0

Respondida
Multiple subplots having same legend
Read this page https://in.mathworks.com/help/matlab/ref/sgtitle.html

alrededor de 3 años hace | 0

Respondida
How to put NaN in certain row of particular column according to another column having NaN in some row
data.Pyrn2_Avg(isnan(data.u_py)) = NaN; % assign NaN to this line

alrededor de 3 años hace | 0

| aceptada

Cargar más