Community Profile

photo

David Hill


Last seen: Today
1,697 total contributions since 2017

Contact

David Hill's Badges

  • 6 Month Streak
  • Pro
  • Knowledgeable Level 4
  • Indexing II Master
  • Sequences And Series III Master
  • Puzzler
  • 5-Star Galaxy Level 2
  • Personal Best Downloads Level 3
  • First Review
  • Scholar
  • First Submission
  • Revival Level 1
  • Creator
  • Leader
  • Computational Geometry II Master

View all

Contributions in
View by

Answered
About sub function............
function Soru6 aci=input('Lütfen açıyı giriniz : '); F=input('Lütfen kuvveti giriniz : '); mesnet function mesnet ...

4 hours ago | 0

Answered
my code won't run or publish
m = 2; n = 1; for i = 1:100000 q = 3*rand(1); if q < 1 m = m/2; n = n/2; elseif q < 2 m = m...

4 hours ago | 1

Answered
Replace single quotation with single quotation and double quotation
B=[char(34),A,char(34)]; B=['"',A,'"'];%or this as long as A is a character array

4 hours ago | 0

Answered
About sub function............
function out=showMe(in) n=1; out=executeSub(); function o=executeSub()%I assume you are talking about a nested fun...

4 hours ago | 0

Answered
for loop showing only last iteration and the graph shows dotted instead of lines
clc close all clear syms x y E v=[x y]; J=jacobian([y,E*(1-x^2)*y-x], v); p=[0 0]; j=subs(J,v,p); a=-8:0.1:8; for E=1:l...

8 hours ago | 0

Answered
Scatter plot of two matrix of same size
scatter(x(:),y(:));%after reading x and y in, make sure the matrix size is the same and of type double

9 hours ago | 0

Answered
Plot function with time step
I assume x is time then corresponding to your y-values with the given step starting at zero. x=0:.000999:4.057938;

1 day ago | 1

| accepted

Answered
Error when trying to run a function
function [g] = R(a,b,c,d) rou=880; Cd=0.7; Aorifice=1.963495408*(10^(-5)); Vo=7*10^(-5); Beta=1600*(10^5); Ap=(5.026...

1 day ago | 0

Answered
How iterate inside a excel file and every 21 rows store values in a matrix?
I don't understand your question completely, but, I would put them all in a single matrix. XY=reshape(XY(1:42,1:2),21,[]);

1 day ago | 1

Answered
How do I convert a cell array with different number of values to a matrix
for k=1:length(m) m{k}=[m{k},repmat(nan,1,5-length(m{k}))]; end m=cell2mat(m);

1 day ago | 1

| accepted

Answered
Return Indices for x Smallest/Largest Values in Array
[~,idx]=sort(x); minIdx=idx(1:3);%for minimum 3 maxIdx=idx(end:-1:end-2);%for maximum 3

1 day ago | 1

Answered
Function Requests and receives from the user the dimensions of the sampled matrix until a proper value is obtained
I would put your input into a continuous while loop and break the loop when the condition is met. function [m,n]=MatrixDimInput...

1 day ago | 0

Answered
Calculate a monthly average from 3-hour data
If you want to simplify slightly, 8 readings * 30 days/month = 240 readings per month ... = 377 months = 90480 readings. Truncat...

1 day ago | 0

Answered
How can I perform an operation on each element of a vector individually using a for loop?
No loop needed. [a,b]=pol2cart(Zp(:,3),Zp(:,2)); Zp=a+b.*i;

1 day ago | 1

| accepted

Answered
Assign a number of random elements to different variables?
v=randperm(40); k=[]; while isempty(k) a=randi(40,1000,6);%you could change 40 to something smaller if you want to limi...

1 day ago | 1

| accepted

Answered
How can I plot the following in MATLAB?
Not sure if this is what you are looking for or not. for n=0:8 f=@(x)exp((1-cos(pi*x))/pi.*cos(n*pi*x)); b(n+1)=2*int...

2 days ago | 0

| accepted

Answered
change the distance between grid lines
Look at the following function: zticks()

3 days ago | 0

Answered
Values substitution of intervals.
x(x>=1400&x<=1500)=0;

3 days ago | 0

Answered
Two vectors to matrix sorted on occurrence
labels=5; hours=6; x=histcounts2(a(:,1),a(:,2),[labels,hours]);

3 days ago | 0

Answered
how to get function value?
syms a; b=2; e=0.9; q=1.2; g=2; k=3; d=0.5; f=(q*b*e/a-d*e)/((q^2)*(e^2)/a+2*e*g); df=diff(f); fvals=eval(subs(f,1:10))...

3 days ago | 0

Answered
how to calculate a row of number to be calculate in if else statement matlab
units=[0 800.09 364.73 776.42 695.21 698 338.67 498.05 426.35 713.48]; results=zeros(size(units)); results(units>900...

3 days ago | 0

| accepted

Answered
How to use if-function for arithmetic properties properly?
If you are trying to comute the ramanujan sum it should be something like this: function s = ramanujanSum(a,n) f=factor(a); s...

3 days ago | 0

Submitted


RIPEMD160 Hash
RIPEMD160 Hash of character array input of maximum length 8191

3 days ago | 3 downloads |

Thumbnail

Submitted


privateKey2bitAddress Generator GUI
Generates both uncompressed and compressed Bitcoin addresses from private key (either WIF or Hexadecimal)

3 days ago | 7 downloads |

Thumbnail

Answered
How can i solve an equation with vector(s) and if this can be done using conditional statement
n=2.2; m=1.86; p=0.153; Qv=0.980; B=3.200; Rw=0.265; Rt=[4.05; 4.10; 4.22; 4.30; 4.38; 4.54; 4.82; 5.03; 5.23; 5.43; 5.64;...

3 days ago | 1

Answered
Rounding error when dividing
round(a/b,12);

3 days ago | 0

Answered
Output standard deviation and Mean
Function call. I would do the printing after the function call returns. But, this should work for you. [s,m]=mean_stdev(); Aft...

3 days ago | 0

| accepted

Answered
Confusion on Meshgrid and interp2
x = -0.5:0.1:0.5; y = -0.5:0.1:0.5; k = 0.77; [x,y] = meshgrid(x,y); z = k*(x.^2-y.^2); m = [-0.5 0 0.5]; n = [-0.5 -0.25...

3 days ago | 0

Load more