Answered
How to change a bit of matrix from 0 to 1
M(6:11:end)=1;%for your Matrix M

5 years ago | 1

| accepted

Answered
Output equation answer from 1 to 50
f=@(x)x.^2.*sin(x)-x.*cos(x);%any equation of one variable f(1:50)%prints to command window with no ;

5 years ago | 0

Answered
Compacting the code by using an for loop or maybe an struct?
a=Participant.GKMovement==0; GK{1}=Participant.KicksDependent(a); GK{2}=Participant.KicksIndependent(a); GK{3}=Participant.Ki...

5 years ago | 0

Answered
I need help with my code for Odd Vs Even
playerA=randi(2,1,10000); playerB=randi(2,1,10000); scoreA=or(and(playerA==1,playerB==2),and(playerA==2,playerB==2)); scoreB=...

5 years ago | 0

| accepted

Answered
How to create a distance matrix?
coord = [0 10 20 10 -20;0 0 10 20 -40]; c=nchoosek(1:size(coord,2),2); dist=zeros(1,size(c,1)); for k=1:size(c,1) dist(k)=n...

5 years ago | 0

Answered
How to call specific number from polyfit
T = [0 8 16 24 32 40]; Oxy = [14.621 11.843 9.870 8.418 7.305 6.413]; p = polyfit(T,Oxy, 5); figure(2); plot(T,Oxy,0:.1:40,p...

5 years ago | 0

Answered
For Loop - Homework Question
income = initial_income*(1+inflation).^(0:40);

5 years ago | 0

| accepted

Answered
Plotting for loop values
Try indexing h=.1:.1:1; for H = 1:length(h) syms r phi U=((n*EA)/2)*(L_ab*((2*(r/L_ab)*sin(pi/n)-1)^2)+L_bc*(((sind(...

5 years ago | 0

Solved


Draw a '8' in a zero matrix!

5 years ago

Solved


Draw a '9' in a zero matrix!

5 years ago

Solved


Draw a '0' in a one matrix!

5 years ago

Solved


Draw a '6' in a zero matrix!

5 years ago

Solved


Draw a '7' in a zero matrix!

5 years ago

Solved


Draw a '4' in a zero matrix!

5 years ago

Solved


Draw a '3' in a zero matrix!

5 years ago

Solved


Draw a '5' in a zero matrix!

5 years ago

Solved


Draw a '2' in a zero matrix!

5 years ago

Solved


Draw a '1' in a zero matrix!

5 years ago

Answered
How can I index nth item to appear within nested struct?
fields = fieldnames(data.streams);%will contain all the fieldnames in a cell array. x=fields{1}; y=fields{2};

5 years ago | 1

| accepted

Answered
Newton's Method Involving Elliptic Integrals
y=fzero(@nonLinear,[.999,.99999999999999]); function f=nonLinear(x) [k(1),k(2)]=ellipke(x); gN = 625; ...

5 years ago | 0

| accepted

Answered
Fast way to solve one nonlinear equation with large data parameters?
n1=1;%whatever you want for n1 n2=2;%whatever you want for n2 phi=-100000:.001:100000;%whatever you want for phi n12=sqrt((2*...

5 years ago | 0

Solved


Multiply Column
Given two input, one matrix and one scalar number For example A is a matrix given A = [ 1 2 2 5 2 5 2 3 4 6...

5 years ago

Solved


Matrix Construction I
Given n, construct a matrix as shown in the example below. Example For n=8, the output should look like this: 1 2 3 4 ...

5 years ago

Solved


Reshape a Vector
Write a function that accept three inputs. The first one is a row vector S. The second and third arguments are m and n which de...

5 years ago

Solved


Spherical Volume
Calculate the volume of a sphere.

5 years ago

Solved


Accurate Division
Given three integers x, y and d, return x/y (as a string) to d significant digits. Remove leading and trailing zeros. Example...

5 years ago

Solved


Determinant without using det()
Given a square matrix A, compute the <http://en.wikipedia.org/wiki/Determinant determinant> of A. Note that you may not use t...

5 years ago

Solved


Temperature Conversion Utility (Strings)
This is a follow-on problem to <http://www.mathworks.com/matlabcentral/cody/problems/2413-temperature-conversion-utility Problem...

5 years ago

Load more