Gelöst


Steal, Share, or Catch
You, I, and a few other characters are going to play a game of *Steal, Share or Catch*. We are going to play it 10,000 times vs...

fast 13 Jahre vor

Beantwortet
Is there a function or method that rounds a value towards a entries of a vector?
v = 1.25:10.25; x = 5.5; v(find(x-v>0,1,'last')); %round to nearest lower v(find(x-v<0,1,'first')); %round to nearest...

fast 13 Jahre vor | 0

| akzeptiert

Beantwortet
Help with 3D plot and meshgrid
You could use the *reshape* command to turn your matrix v into one with the same size as your mesh, then plot using a command li...

fast 13 Jahre vor | 0

Beantwortet
If I am given a image of black circle with white background, how can I find the exact center of that circle?
Is this a binary image? If not, you'll need to do some thresholding. Once you do that, you can use *regionprops* (if you have th...

fast 13 Jahre vor | 2

Gelöst


Angle of triangle
For three unknown points a b c, given three sides ab bc ca, find three angles abc bca cab in radians. Your function should b...

fast 13 Jahre vor

Beantwortet
Set GUI sliders to parameters?
In the callback for whatever GUI control is activated to perform your calculations, add in code that looks something like this: ...

fast 13 Jahre vor | 0

Gelöst


Guess Cipher
Guess the formula to transform strings as follows: 'Hello World!' --> 'Ifmmp Xpsme!' 'Can I help you?' --> 'Dbo J ifmq zpv...

fast 13 Jahre vor

Gelöst


Change a specific color in an image
The ability to change colors can be a useful tool in image processing. Given an m x n x 3 array (much like CData in images), fin...

fast 13 Jahre vor

Beantwortet
how to find out number of rows in particular matrix of the cell?
>> a = {[1 2] [1 2; 3 4]}' >> cellfun('size',a,1) ans = 1 2 For more: help cellfun

fast 13 Jahre vor | 0

| akzeptiert

Gelöst


Clock Hand Angle 1
Given a time in HH:MM:SS, find the smallest angle (in degrees) between the hour and minute hand

fast 13 Jahre vor

Gelöst


Find matching parenthesis
One of the most indispensable things about a great text editor for programming is the ability to quickly jump between matching p...

fast 13 Jahre vor

Gelöst


Circumscribed circles
Given the lengths of the 3 sides of a triangle, output the radius of the circumscribed circle. Example: [3 4 5] -> 2.5

fast 13 Jahre vor

Gelöst


Can you beat the lottery?
Well this one you may not get every time, but it is a lottery! Here is the code that generates the lottery numbers (you can try ...

fast 13 Jahre vor

Beantwortet
set NaN as another color than default using imagesc
You can use the *isnan* function to find the indices of all NaNs, then set those elements to another value: Example: >>A...

fast 13 Jahre vor | 0

Gelöst


NO _________ ALLOWED....
So you're given a sentence where if there is a particular word in the sentence then the output is 1, if it is not there then the...

fast 13 Jahre vor

Beantwortet
How to display image above threshold?
mask = rawImage > N; %simple thresholding--adjust for your needs maskedImage = rawImage; %copy image maskedI...

fast 13 Jahre vor | 1

Gelöst


Equidistant numbers containing certain value in an interval
Given a lower and upper bound of an interval, distance between numbers, and one particular number from that interval, create an ...

fast 13 Jahre vor

Gelöst


Wilf-Zeilberger pairs
Take as inputs two functions _F_ and _G_, and two scalar values _n_ and _k_. Test whether the functions are candidates to be a W...

fast 13 Jahre vor

Gelöst


Matrix with different incremental runs
Given a vector of positive integers a = [ 3 2 4 ]; create the matrix where the *i* th column contains the vector *1:a(i)...

fast 13 Jahre vor

Gelöst


Symmetric matrix
You must create a n-by-n *symmetric* matrix such that A(row,col) = row/col for col >= row. Example if n =3 : output is : ...

fast 13 Jahre vor

Gelöst


Bit Reversal
Given an unsigned integer _x_, convert it to binary with _n_ bits, reverse the order of the bits, and convert it back to an inte...

fast 13 Jahre vor

Gelöst


"Look and say" sequence
What's the next number in this sequence? * [0] * [1 0] * [1 1 1 0] * [3 1 1 0] * [1 3 2 1 1 0] This a variant on the w...

fast 13 Jahre vor

Gelöst


Half?
If you toss an even number (x) of coins, what is the probability (y) of 50% head and 50% tail?

fast 13 Jahre vor

Gelöst


Create a function handle that reverses the input arguments of another function handle
Given a function that takes two input arguments and returns one output, create another function handle that performs the same op...

fast 13 Jahre vor

Gelöst


Convert String to Morse Code
Convert a given string to international <http://en.wikipedia.org/wiki/Morse_code Morse Code> * Strings will only have [A-z], ...

fast 13 Jahre vor

Gelöst


Test if a Number is a Palindrome without using any String Operations
*Description* Given an integer _X_, determine if it is a palindrome number. That is, _X_ is equal to the _X_ with the digits ...

fast 13 Jahre vor

Beantwortet
GUI 'uitable' with option to add or remove rows depending on 'textbox' value
It looks like you just need to put the following i the callback of your editbox (I'm assuming you meant editbox instead of textb...

fast 13 Jahre vor | 2

| akzeptiert

Beantwortet
How to I plot this?
Does this do what you need? X = [1 2 3 1 1; 6 6 6 2 1; 9 8 7 1 0; 3 3 3 2 0]; hold on plot(X...

fast 13 Jahre vor | 1

Beantwortet
popupmenu in GUI, string call backs.
Are you using GUIDE for this GUI? If so, you'll need to access the "value" property of each of your popupmenus from within your ...

fast 13 Jahre vor | 1

| akzeptiert

Beantwortet
How to use axis(axis_handle...)?
Try putting your desired axis bounds inside a bracket. Axis accepts this as a single argument rather than four. axis(axes_ha...

fast 13 Jahre vor | 0

| akzeptiert

Mehr laden