Solved


Find the mass of a rod
Determine the mass (in grams) of a rod of length L cm if it is in equilibrium per the diagram. In the diagram L1, L2, L3 are di...

4 years ago

Answered
Ho to subtract row from a row in a matrix?
P= [1 4.6 -7.6 2.2 1.4 6.8 18.2 12; 1 5.6 7.4 2.8 11.4 4.8 28.2 -13; 8 9.5 11.7 13.8 12.6 4.7 -8.8 -23]; p=P(2,:)-P(1,:)

4 years ago | 1

Answered
grabbing specific rows from matrix
idx=ismember(xy_index(:,3),index); extracted_xy_index=xy_index(idx,:);

4 years ago | 0

Answered
For Loop "Array indices must be positive integers or logical values"
matlab starts indexing at 1, you cannot index into an array at 0 for k = 2:nmr if a(k) < a(k-1) & a(k-1) < a(k-2) & b(k) >...

4 years ago | 0

| accepted

Answered
How do you integrate a very long equation on MATLAB?
Numerical integration. p=@(x)(7.593*x.^6 - 231*x.^5 + 2316.1*x.^4 - 10644*x.^3 + 21966*x.^2 - 16304*x + 1000000).*... sqrt...

4 years ago | 0

Answered
can you help me fix this moving average filter it keeps giving me errors, I suppose to design a moving average filter from the filter equation bellow
Did you look at movmean r=randi(100,1,100); M=6; m=movmean(r,M,'Endpoints','discard')

4 years ago | 0

Answered
finding a number between 2 numbers
m=[88 65 98 34 100]; m(m>=95&m<=100)

4 years ago | 0

| accepted

Answered
Angle between two planes given xyz coordinate data from each plane
P1 = [1,-1,3]; P2 = [2,3,4]; P3 = [-5,6,7]; normal = cross(P1-P2, P1-P3); P4 = [4,-2,4]; P5 = [1,7,5]; P6 = [-3,5,9]; nor...

4 years ago | 0

| accepted

Answered
What is the easiest way to calculate the triple definite integral of a symbolic vector over arbitrary domain without using for loop?
syms x y z V=[x,y,z]; I=int(int(int(V,x),y),z);%recognize the definite integrals do not exist for many integrals (this works b...

4 years ago | 0

| accepted

Answered
How to check multiple values in an equation in MATLAB?
L=1390./(6:6:1390); Lmin=L(find(L>5,1,'last'))

4 years ago | 0

Answered
Problem with exp() function
Make sure your clear your workspace and do not have any function names 'exp' clear format long exp(1) exp(6)

4 years ago | 1

Answered
finding the closest value
data3=data1; S=sort(data2); idx= find(~ismember(data1,data2)); for k=idx f=find(S>data1(k),1); data3(k)=S(f); end

4 years ago | 0

Answered
How do I compare two shuffled vectors, and get the indexes of one as it appears in the other?
b=["cond4","cond2","cond1","cond3"];%needs to be string array [~,idx]=sort(b)

4 years ago | 1

Answered
Combination of two values in a list to get the value of an input value
list = [ 200 300 500 800 1200]; num = 1850; d=50;%small difference A=[]; for k=1:length(list) n=nchoosek(list,k); ...

4 years ago | 0

| accepted

Answered
logic question regarding two vectors
Really have no idea what you are asking.... just guessing x=[0, -4, 7, 0, -1, 2]; y=[1, -4, 8, 0, 1, 6]; z=min(x,y)

4 years ago | 0

Answered
how to write a geometric series in command window
sum(1./[1,3:3:297])

4 years ago | 0

Solved


Calculate load on arm
A robot is designed with a motor directly attached at the pivot point of the lifting arm. The L inch arm has a weight of W1 lbs...

4 years ago

Solved


Magnitude of Balancing Force
A box weighing W1 pounds is placed where its center of mass is located d1 ft from the fulcrum. A balancing force is placed at th...

4 years ago

Answered
extract specefic data from zpd files
r=readtable('abmf0010.21zpd.txt'); trotot=r.TROTOT;

4 years ago | 0

Answered
Inconvenience working with matlabFunction
If you don't need to work in symbolics, don't. h=@(p1,p2,x,y)[x.*y+p1,y.^2-1;x.^3+p2^2, 1-x.^2+p1*p2]; h(1,2,[3 4],[5 6])

4 years ago | 0

Answered
why my conditional function is not what I expected?
[x,y] = meshgrid(-3:0.1:3); f=zeros(size(x)); f(x>=0&(x.^2+y.^2)<4)=1; f(x>-2&x<0&abs(y)<2)=.5; surfl(x,y,f)

4 years ago | 0

| accepted

Answered
Mulitply diffrent numbers in a vector by a corrsponding number.
v=[1 6 8 10 14 20 25]; v(ismember(v,[1 2 8 10]))=10*v(ismember(v,[1 2 8 10]));%similarly for others

4 years ago | 0

Answered
Converting a cell array containing more cell arrays with different sizes to one cell matrix
F = {{[0.04,0.2,0.56;0.31,0.67,0.22]},{... [6+6j,7+3j,8-6j;6+8j,7-6j,3-3j],... [5+6j,8+5j;6+8j,7-6j;5+6j,3-9j],... ...

4 years ago | 0

| accepted

Solved


Easy Sequences 71: A Nonlinear Function with Quadratic Domain
Consider the function: The outputs of this function are fed as domain to another function: ...

4 years ago

Answered
How do I delete a group of rows when a condition is met in one?
f=find(data>.25); idx=[]; for k=1:length(f) idx=[idx,(f(k)-10):(f(k)+10)]; end idx=unique(idx); idx=idx(idx>0&idx<=len...

4 years ago | 1

Solved


Fun with matrix
Disign a sample matrix as given in the test cases

4 years ago

Solved


Find the remainder - 02
Given an array of integers, find the remainder when the summation of all the elements is divided by N

4 years ago

Solved


Congruent
Given two numbers, check whether they are congruent to each other or not for a particular value N.

4 years ago

Answered
I am supposed to create a single x value then inside the while loop use the x-value it to calculate a y value. Then save the x & y values in in a storage array as x increases
x5start = 0; stepsize5 = 20; x5end = 20; x5 = x5start; i = 1; while x5 <= x5end y5 = 2 .* (x5).^3 - (35 .* (x5)).^2 +...

4 years ago | 0

| accepted

Load more