Respondida
How do I create a row vector P, that contains the sum of the values in column 2 and the sum of the values in column 5 of matrix B.
B = rand(randi([10,20]),randi([5,30])) P = sum(B(:,[2,5]))

alrededor de 2 años hace | 1

| aceptada

Respondida
How do I graphic
eqn = @(x) (-3+3*x)./x <= 0 fplot(eqn,[-5 5])

alrededor de 2 años hace | 0

Respondida
I am trying to assign a pattern of alphabets to a sequence of alphabets that I have.
seq_file = fopen('insulinDNAseq.txt'); template5_3 = fscanf(seq_file,'%s'); seq_len = length(template5_3); template3_5 = [fli...

alrededor de 2 años hace | 0

Respondida
How can I solve Inecuations
syms x real eqn = (3-3*x)/x <= 0 sol = solve(eqn,x)

alrededor de 2 años hace | 0

Respondida
How to compare these two strings?
try using strcmp function FilteredCIV = CIV(strcmp(CIV.SYMBOL,UnderlyingSymbols.SYMBOL(1)),:); % try using strcmp

alrededor de 2 años hace | 0

| aceptada

Respondida
Manipulate elements in a matrix based on a mathematical condition using logical indexing
A = rand(26,500) % zeros() just used for illustration condition = ( A(26,:) - A(1,:) ) < 0.01; A(:,condition) = A(1); A

alrededor de 2 años hace | 0

Respondida
Creating an empty figure
tf = isempty(names); if tf == 1 figure % to generate empty plot elseif opt <1 | opt > 3 figure disp("In...

alrededor de 2 años hace | 0

Respondida
Array indices must be positive integers or logical values.
Matlab arrays are indexed using whole integers, when you give a fractional or decimal values as input it throws such errors cle...

alrededor de 2 años hace | 1

Respondida
from txt to dat file
Select the desired range in Range field box. i.e. Only the categorical column. It seems you have selected a array of columns in ...

alrededor de 2 años hace | 0

Respondida
How to make comparison plot in a struct
plot(egoStatesRefTrajectory(m).y(:,1),egoStatesRefTrajectory(m).y(:,2))

alrededor de 2 años hace | 0

| aceptada

Respondida
I am unable to get the deflection of beam correctly and the plot is incorrect.Even when i am using the right code. Also i tryed to distribute my beam into sections.
scale = 50; E= 1.999*10^11; % N/m2 nu = 0.3; I= 7.74.*10^-7; % m^4 H = 0.0762;% m R1 = 2224; % N R2 = 2224; % N P = 222...

alrededor de 2 años hace | 0

Respondida
how to solve and plot complex equation
b = 3; c = 4; x=0:180; a=b*pi*sin(deg2rad(x))/c; y=(sin(a).^2)./a.^2; plot(x,y)

alrededor de 2 años hace | 1

| aceptada

Respondida
Trying to make a Hiragana guesser
rand=randi(5) switch string(rand) case '1' disp('something') case '2' disp('something') end

alrededor de 2 años hace | 0

| aceptada

Respondida
Call function Callback into myfunction
Use simply the UpdateTableButton inside the function MPV_Calc_Draw_Graph.m file. app.UpdateTableButton and rename the functio...

alrededor de 2 años hace | 0

Respondida
search for the position of a number inside a cell (cell with existence of empty rows)
Use a | instead of &. OR in place of AND

alrededor de 2 años hace | 1

Respondida
Latex Font in MATLAB
xlabel('$E_{\it V_{1}}$', 'Interpreter','latex')

alrededor de 2 años hace | 0

| aceptada

Respondida
Converting a cell array to excel file using write table - how to add headers and sheet name?
sheetNames = {'2000', '2001', '2002','2003', '2004', '2005','2006', '2007', '2008','2009', '2010', '2011',... '2012', '2013...

alrededor de 2 años hace | 1

Respondida
stuck in a small issue related to implementation of an aircraft trim condition code with cost function: error is "TOO MANY INPUT ARGUMENTS"
Few syntax and typo errors that are persistent in your code need to checked. % TRIM.m clear; clc; close all; % x u gamma; ...

alrededor de 2 años hace | 0

| aceptada

Pregunta


Unable to comprehend "time" function output
d = caldays(8:10) + hours(1.2345) t = time(d) % this output Is this output returning the difference between time components ...

alrededor de 2 años hace | 1 respuesta | 0

1

respuesta

Respondida
Why is my function not recognized?
myEquation(2) function myEquation (x) a = 0.4361836; b = 0.1201676; c = 0.937298; r = exp(-0.5*(x^2))/(2*pi) t =...

alrededor de 2 años hace | 0

| aceptada

Respondida
remove data from fig file after plotting
|If you want to do it using figure properties alone, this is one way h = openfig('eps_mu_mu_34.fig') % figure properties ax =...

alrededor de 2 años hace | 0

Respondida
always process on first image of the image series where exist in a folder while using imwrite inside for loop
image = imread(sprintf('%d.gif',a)); Try using the above format. Is *a.gif* a multimage file from which you try to read individ...

alrededor de 2 años hace | 0

| aceptada

Respondida
Newmark-Beta in dynamic analysis for solving nonlinear stiffness matrix problem
clear all clc % Define parameters n = 3; % Number of degrees of freedom m = eye(n); % Mass matrix (identity matrix for simpl...

alrededor de 2 años hace | 1

| aceptada

Respondida
How to modify the code to compute data on multiple inputs?
theta = [15 30 45]; for i = 1:227 % size(vp,2) for k = 1:length(theta) data{i,k} = fwmod_vpvsrho(vp(:,i),vs(:,...

alrededor de 2 años hace | 0

| aceptada

Respondida
How to control pitch angle?
This link can be helpful for your question <https://in.mathworks.com/help/control/ug/wind-turbine-control-design.html>

alrededor de 2 años hace | 0

| aceptada

Respondida
Tangent Line and Normal Line
f(x) = x^3 - 3*x + 2 instead of f(x) = 3^x - 3*x + 2

alrededor de 2 años hace | 2

Respondida
Put letters as markers in a legend box
Use combination of LineStyle and Markers if you have lot of data series to represent in plot. Hopefully, legend box will not h...

alrededor de 2 años hace | 0

Respondida
Minimum value from a vector for x in the range: x= [-4:0.5:4]; Calculate f(x)=x2+1.3x+2.
x = -4:0.5:4; f = @(x) x.^2 + 1.3*x + 2 [F idx] = min(f(x)) xv = x(idx) % value of x at which minimum of f(x) occurs

alrededor de 2 años hace | 0

Respondida
error: Array indices must be positive integers or logic
y(i) = y(i) + 1; instead of y(II) = y(II) + 1;

alrededor de 2 años hace | 0

Respondida
index problem while sort
Here is another way to get the indices without overhead of using ismember function Omega=[1.528 -1.528 0.792 -0.792]; [NN,ind]...

alrededor de 2 años hace | 2

Cargar más