Community Profile

photo

David Hill


Last seen: Today Active since 2017

Electrical Engineering with minors in Computer Science and Mathematics. Working as an Undergraduate Research Assistant in the field of Robotics.

Programming Languages:
Python, C++, C, Java, MATLAB, HTML, Arduino
Spoken Languages:
English, Spanish
Professional Interests:

Statistics

All
  • MATLAB Mini Hack Participant
  • Treasure Hunt Participant
  • 36 Month Streak
  • Revival Level 2
  • Magic Numbers Master
  • Word Puzzles Master
  • Personal Best Downloads Level 4
  • 5-Star Galaxy Level 4
  • Promoter
  • Sequences And Series II Master
  • Cody5 Easy Master
  • Number Manipulation II Master

View badges

Content Feed

Answered
How to permute elements of jth column of a matrix iteratively
A=[1,2,3 ; 7,8,9 ; 13,14,15]; perms_of_(A,2) function A_perms = perms_of_(A,j) p=perms(A(:,j)); for i = 1:length(p) A_p...

etwa 4 Stunden ago | 0

| accepted

Answered
How To change Diagonal Elements with a string in matrix using FOR loop or other preferred method?
a='ALEX'; b=diag(double(a)); b(b==0)=48; string(char(b)) char(b)

etwa 12 Stunden ago | 0

Answered
Unier matrices de diferentes tiempos e interpolarlarlas
newMatrix=[A;B;C];%where A,B,and C are your current matrices.

7 Tage ago | 0

Answered
How to calculate rate constant if population vs time table data is given?
N=[1 2 3 4.5 7 10 16 29 56 104]; fit((1:length(N))',N','exp1')

12 Tage ago | 0

Answered
How to generate a specific number of values within a range ?
a=sort(rand(10,2),2); A=[]; for k=1:size(a,1) A=[A;linspace(a(k,1),a(k,2),60)]; end

12 Tage ago | 0

Answered
Better work through indecies in a for loop
Just use continue. for n = 1:length(start0) if start0(n)-240 < 360 % If the filter time is not big enough then move ...

12 Tage ago | 0

| accepted

Answered
Different answers when I do the same integration
They are not the same expressions. syms x int((1+cos(x))^2,0,pi) int(1+2*cos(x)+cos(x)^2,0,pi) int(1+cos(x)^2-2*(1-cos(x)),0...

12 Tage ago | 0

Answered
How to read x and y values from a text file?
Should attach file for us to test. m=readmatrix('points.txt'); x=m(:,1)';y=m(:,2)';

12 Tage ago | 0

| accepted

Answered
Find rows based on set of values/codes
for i = 1:size(data,2) if all(ismember(data(i,:),[0 1 13 31 42 53]))%include 0

12 Tage ago | 0

Answered
For loop error, not getting desired output
x = [1 2 3 5; 4 3 1 3; 1 3 3 4]; y = [1 2 3 5; 4 3 1 3; 1 3 3 4]; columns = 3; for i = 1:columns correct = 0; for j...

13 Tage ago | 0

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,:)

15 Tage ago | 0

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

16 Tage 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) >...

16 Tage 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...

16 Tage 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')

16 Tage ago | 0

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

16 Tage 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...

16 Tage 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...

16 Tage 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'))

16 Tage 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)

16 Tage 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

16 Tage 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)

16 Tage 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); ...

16 Tage 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)

16 Tage ago | 0

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

16 Tage ago | 0

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

17 Tage 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])

17 Tage 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)

17 Tage 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

17 Tage ago | 0

Load more