A résolu


Implement a counter
Write a function that returns a function that counts the number of times it is invoked. Example: >> h = counter; >> h() ...

presque 13 ans il y a

A résolu


2D - Mean Filter
Assume you are given an "image" matrix of size NxM. Reduce the image noise by implementing a mean filter window of size 9 (a 3x3...

presque 13 ans il y a

A résolu


magic solver
Create a function that returns _true_ and has a cody <http://www.mathworks.com/matlabcentral/cody/problems/256-return-the-size-o...

presque 13 ans il y a

A résolu


Two-output anonymous function?
Return a function handle that when applied to an input, it produces two outputs: the first is the same as the input, and the sec...

presque 13 ans il y a

A résolu


Vector Linear sum: (p1-m1)V1+(p2-m2)V2+...(pK-mk)Vk
Calculate the sum of a Vector times coefficients expressed as two strings. Example: Normal representation [ a b c ], [ p1 ...

presque 13 ans il y a

A résolu


Frobenius Norm
Write your own version of Frobenius Norm without using the 'norm' function.

presque 13 ans il y a

A résolu


Create incremental spiral WITHOUT USING EVAL or FEVAL
Constructions that use feval or eval are used to cheat with cody. This test-suite tries to avoid that trick. The goal of this...

presque 13 ans il y a

A résolu


Make a diamond
Given n, odd number > 1, return n by n matrix consist of "null" and "*" characters arranged like a diamond. No toolbox funct...

presque 13 ans il y a

A résolu


Spot the rectangle (Part 2)
This problem is related to the <http://bit-player.org/2009/the-17x17-challenge 17x17 challenge>. See also <http://www.mathworks....

presque 13 ans il y a

A résolu


All Humans are Created Equal - Pareto Equality
One way or the other two sets of identical types can come out ahead of the other by idea of Pareto equality. Pareto equality b...

presque 13 ans il y a

A résolu


Decrypt a secret message!
The crypto system in question is based on phone keyboard. We need two numbers in order to decrypt a word. First number represent...

presque 13 ans il y a

A résolu


Alias abs to asb
Create an alias of a built-in function name. Goal is to alias asb with abs for dyslexic typers. The test suite will be ...

presque 13 ans il y a

A résolu


How many palindromes?
* Given a set of letters, count all possible palindromes, using all of those letters. * For example, if the set is {'A' 'A' 'A'...

presque 13 ans il y a

A résolu


Bisection method of finding a root.
Test the bisection algorithm described in Chapter 5 of Steven C. Chapra's textbook, *Applied Numerical Methods with MATLAB for E...

presque 13 ans il y a

A résolu


What gear ratio does the cyclist need?
A cyclist (perhaps including our famed Codysolver the cyclist <http://www.mathworks.com/matlabcentral/cody/players/1841757-the...

presque 13 ans il y a

A résolu


Number of bytes required to store a sparse matrix
The input is always a *sparse* matrix : x = sparse(100,1000,0.01); >>whos x shows that 4016 bytes ares required . ...

presque 13 ans il y a

A résolu


Parse string and identify specific string sequence in algebraic equation
Given a string S that defines an algebraic expression such as: S= 'X= A1 + A2*(Y1 + A3*Y3)*exp( A4*Y12 + Y1) ;' return a...

presque 13 ans il y a

A résolu


Procrustean bed
Given a vector x and an integer n, convert x to a vector of length n by (1) chopping off the end if it is too long, or (2) addin...

presque 13 ans il y a

A résolu


Pi Estimate 2
Estimate Pi as described in the following link: <http://www.people.virginia.edu/~teh1m/cody/Pi_estimation2.pdf>

presque 13 ans il y a

A résolu


Math with Roman Numerals
Given a function R within (+,-,*,/) and two Roman numerals a & b, compute aRb in Roman numerals.

presque 13 ans il y a

A résolu


Create array of all Distances between two Sets of Points : No Neural Network Toolbox
This Challenge is a subsection of <http://www.mathworks.com/matlabcentral/cody/problems/1110-usc-fall-2012-acm-martian-pranks Ma...

presque 13 ans il y a

A résolu


Convert single-precision floating-point number to binary representation
Write a function which takes a scalar <http://en.wikipedia.org/wiki/Single-precision_floating-point_format single-precision floa...

presque 13 ans il y a

A résolu


Create array of all Distances between two Sets of Points
This Challenge is a subsection of <http://www.mathworks.com/matlabcentral/cody/problems/1110-usc-fall-2012-acm-martian-pranks Ma...

presque 13 ans il y a

A résolu


Golomb's self-describing sequence (based on Euler 341)
The Golomb's self-describing sequence {G(n)} is the only nondecreasing sequence of natural numbers such that n appears exactly G...

presque 13 ans il y a

A résolu


Greed is good - Simple partition P[n].
Find a simple partition P[n]. E.g. P[10] = 4 + 3 + 2 + 1. # There are many solutions, compute just one set. # Don't repeat ...

presque 13 ans il y a

A résolu


Find similar/related functions
The _help_ function can be useful for getting quick assistance on a particular function. For most built-in MATLAB functions, a p...

presque 13 ans il y a

A résolu


Finite Continued Fraction
Given an input real number x and a natural number n, output the row vector with the n first terms of the continued fraction. F...

presque 13 ans il y a

A résolu


Simple Decoder Ring
The stereotypical _decoder ring_ is remembered as a cereal box prize from the 1950s. Kids learned about cryptography by startin...

presque 13 ans il y a

A résolu


Make a logical diamond using GALLERY function
Inspired from <http://www.mathworks.com/matlabcentral/cody/problems/1078-make-a-diamond Problem 1078. Make a diamond> In thi...

presque 13 ans il y a

A résolu


Apply a function array to an array of numbers
It is required to apply a cell array of functions to a numerical array, where the functions accept only scalar inputs. Exampl...

presque 13 ans il y a

Charger plus