Column norms of a matrix
Given a matrix M, return a vector y such that for each k
y(k)=norm(M(:,k))
(y(k) is the Euclidean norm of the k-th col...
2年弱 前
解決済み
Determine if input is a perfect number
A perfect number occurs whent the sum of all divisors of a positive integer, except the number itself, equals the number.
Examp...
2年弱 前
解決済み
Sum the 'edge' values of a matrix
Sum the 'edge' values of an input matrix (the values along the perimeter).
Example
[1 2 3
4 5 6
7 8 9]
Output = ...
First N Perfect Squares
*Description*
Return the first N perfect squares
*Example*
input = 4;
output = [ 1 4 9 16 ];
2年弱 前
解決済み
Spherical radius given four points
Determine the radius of a sphere provided four non-coplanar points on the surface of the sphere.
pts = [x1 y1 z1;
x...
2年弱 前
解決済み
Covering area
As an extension of the problem <http://www.mathworks.com/matlabcentral/cody/problems/416-polygon-area>, find the area, bounded b...
Are you in or are you out?
Given vertices specified by the vectors xv and yv, and a single point specified by the numbers X and Y, return "true" if the poi...
2年弱 前
解決済み
Volume of a Parallelepiped
Calculate the volume of a Parallelepiped given the vectors for three edges that meet at one vertex.
A cube is a special case ...