解決済み


Counting Money
Add the numbers given in the cell array of strings. The strings represent amounts of money using this notation: $99,999.99. E...

5年以上 前

解決済み


Pangrams!
A pangram, or holoalphabetic sentence, is a sentence using every letter of the alphabet at least once. Example: Input s ...

5年以上 前

解決済み


Function Iterator
Given a handle fh to a function which takes a scalar input and returns a scalar output and an integer n >= 1, return a handle f...

5年以上 前

解決済み


Finding Perfect Squares
Given a vector of numbers, return true if one of the numbers is a square of one of the other numbers. Otherwise return false. E...

5年以上 前

解決済み


Remove the vowels
Remove all the vowels in the given phrase. Example: Input s1 = 'Jack and Jill went up the hill' Output s2 is 'Jck nd Jll wn...

5年以上 前

解決済み


Bullseye Matrix
Given n (always odd), return output a that has concentric rings of the numbers 1 through (n+1)/2 around the center point. Exampl...

5年以上 前

解決済み


Return the largest number that is adjacent to a zero
This example comes from Steve Eddins' blog: <http://blogs.mathworks.com/steve/2009/05/27/learning-lessons-from-a-one-liner/ Lear...

5年以上 前

解決済み


Find the longest sequence of 1's in a binary sequence.
Given a string such as s = '011110010000000100010111' find the length of the longest string of consecutive 1's. In this examp...

5年以上 前

解決済み


Find the numeric mean of the prime numbers in a matrix.
There will always be at least one prime in the matrix. Example: Input in = [ 8 3 5 9 ] Output out is 4...

5年以上 前

解決済み


Remove all the consonants
Remove all the consonants in the given phrase. Example: Input s1 = 'Jack and Jill went up the hill'; Output s2 is 'a ...

5年以上 前

解決済み


Who Has the Most Change?
You have a matrix for which each row is a person and the columns represent the number of quarters, nickels, dimes, and pennies t...

5年以上 前

解決済み


Sum all integers from 1 to 2^n
Given the number x, y must be the summation of all integers from 1 to 2^x. For instance if x=2 then y must be 1+2+3+4=10.

5年以上 前

回答済み
How can i write input variables from a text file into my script
It looks like you can simply use run to run this code as a script. I would encourage you to rethink this strategy for loading p...

5年以上 前 | 0

回答済み
mex -setup (SDK-7.1 for matlab 2020b)
The solution is to use a different compiler, as the SDK 7.1 is not supported for R2020b. You can find the full list here. I wou...

5年以上 前 | 1

| 採用済み

回答済み
.eps file is saved in black & white instead of a coloured image
Your commented code already contains the answer: you forgot the c in depsc.

5年以上 前 | 0

回答済み
How to use min function so that it stops at the first minimum value in a column matrix, stores values, and then continues going until it finishes the entire matrix? (details below)
If the minimum value you're after is the same throughout the array: data=[0.200 0.300 0.400 0.001 0.002 0.003 0.004 0.003 0.002...

5年以上 前 | 1

回答済み
I am trying to save the image at an specific size.
The better way is to calculate the appropriate value. However, you can also do this quick-n-dirty: [wt,f] = cwt(y,'amor',12000...

5年以上 前 | 0

| 採用済み

回答済み
Use same algorithm for different data
The source of your problem is that you chose to put data (i.e. the counter) in the variable name. You should consider storing H...

5年以上 前 | 0

| 採用済み

回答済み
How can I augment a toolbox to improve its capabilities?
The answer by dpb is what you should do, but the answer to the question as posed is this: Matlab is closed-source. Mathworks ...

5年以上 前 | 1

| 採用済み

回答済み
how can I display 3 row vectors as column vectors in front of eachother using fprintf?
Just use a loop: a=[1 2 3]; b=[11 22 33]; c=[111 222 333]; for n=1:numel(a) fprintf('%d %d %d\n',a(n),b(n),c(n)) e...

5年以上 前 | 0

回答済み
Error using / Matrix dimensions must agree.
If you make it an element-wise division, your code will run without errors. Since you still haven't really explained anything yo...

5年以上 前 | 0

| 採用済み

回答済み
How to read a numerical value from a static text box?
You need to strip the unit from the char array. Best practice is to keep numeric fields as pure as possible. With the uifigure-t...

5年以上 前 | 0

回答済み
umlauts character interpret differently based on Matlab version.
The reason is that Matlab switched the default encoding to UTF-8 in R2020a. The only difference is how Matlab interprets the fil...

5年以上 前 | 2

回答済み
how to write loop for dicom image
You can either list the file names, or properly create the file name: %clear all %clc %^^^^ These are not needed, and espe...

5年以上 前 | 0

| 採用済み

回答済み
How to put subscript/superscript in fprintf?
There are unicode <https://unicodelookup.com/#Subscript/1 subscript> and <https://unicodelookup.com/#Superscript/1 superscript> ...

5年以上 前 | 3

回答済み
How to use strings in function
You need to concatenate the output of the function you created. That way you get a single char vector as the range specification...

5年以上 前 | 0

| 採用済み

回答済み
C++ Call Matlab error
The way I read the documentation page you linked, you need to do this: // Call function with no output by using void as the...

5年以上 前 | 1

回答済み
How to input an image from the user using imread() command?
You can extract data from the clipboard with the clipboard function. If you want the user to supply a file so you can use imread...

5年以上 前 | 1

回答済み
Subscript indices must either be real positive integers or logicals.
Welcome to the wonderful world of floating point numbers. Just like 1/3 cannot be represented exactly with decimal values (meani...

5年以上 前 | 0

| 採用済み

回答済み
pass data from app designer to .m file
The easy solution is to never use scripts for importants things. Put the code in a function so you can call it from anywhere, in...

5年以上 前 | 0

さらに読み込む