A répondu
Exact value in excel sheet of function
Hi, you can see on command window by enter following lines: format long y(783) In this way you can see on command wi...

environ 4 ans il y a | 1

| A accepté

A répondu
How to fix axes in dynamic plot
Hi, you can add in your code xlim and ylim functions close all x=@(t)(sin(4*t)).^2; y=@(t)cos(5*t); z=pi; figure(1) for...

environ 4 ans il y a | 0

A répondu
Specifying row and columns in writetable function
Hi, see https://www.mathworks.com/help/matlab/ref/writetable.html on how to use writetable function. writetable(T,'myData.xls'...

environ 4 ans il y a | 1

A répondu
Plot grided latitude and longitude as pixels on map
I obtain this result: by running the following code: load lati.mat load loni.mat [LONG, LAT] = meshgrid(loni,lati); Z =...

environ 4 ans il y a | 3

| A accepté

A répondu
Am I doing this right? (a Math formula to Matlab language)
Hi, A and B terms are wrong. What you wrote is the square of sum of differences. Instead formula is the sum of square of diffe...

environ 4 ans il y a | 1

A résolu


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...

environ 4 ans il y a

A résolu


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...

environ 4 ans il y a

A résolu


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

environ 4 ans il y a

A résolu


Remove any row in which a NaN appears
Given the matrix A, return B in which all the rows that have one or more <http://www.mathworks.com/help/techdoc/ref/nan.html NaN...

environ 4 ans il y a

A résolu


Return the 3n+1 sequence for n
A Collatz sequence is the sequence where, for a given number n, the next number in the sequence is either n/2 if the number is e...

environ 4 ans il y a

A résolu


Swap the first and last columns
Flip the outermost columns of matrix A, so that the first column becomes the last and the last column becomes the first. All oth...

environ 4 ans il y a

A répondu
my plot is not sinusoidal wave
Hi, the argument of cosine "(m*pi.*x)/el" returns you always one. This happens because your cosine argument is expressed in t...

environ 4 ans il y a | 1

A résolu


Find all elements less than 0 or greater than 10 and replace them with NaN
Given an input vector x, find all elements of x less than 0 or greater than 10 and replace them with NaN. Example: Input ...

environ 4 ans il y a

A résolu


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...

environ 4 ans il y a

A résolu


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...

environ 4 ans il y a

A répondu
Import variable names and vaues from a .txt file
Hi, you can try "eval" matlab function to solve your problem For example: T = readtable(filename,'Delimiter',' '); [r,c] =...

environ 4 ans il y a | 0

A résolu


Fibonacci sequence
Calculate the nth Fibonacci number. Given n, return f where f = fib(n) and f(1) = 1, f(2) = 1, f(3) = 2, ... Examples: Inpu...

environ 4 ans il y a

A résolu


Determine whether a vector is monotonically increasing
Return true if the elements of the input vector increase monotonically (i.e. each element is larger than the previous). Return f...

environ 4 ans il y a

A résolu


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...

environ 4 ans il y a

A résolu


Select every other element of a vector
Write a function which returns every other element of the vector passed in. That is, it returns the all odd-numbered elements, s...

environ 4 ans il y a

A résolu


Add two numbers
Given a and b, return the sum a+b in c.

environ 4 ans il y a

A résolu


Triangle Numbers
Triangle numbers are the sums of successive integers. So 6 is a triangle number because 6 = 1 + 2 + 3 which can be displa...

environ 4 ans il y a

A répondu
How do I stop patch from making my squares into rectangles?
Hi, you can add to your code the following line: axis equal In this way you obtain the following result: You can see: h...

environ 4 ans il y a | 0

| A accepté

A résolu


Find the sum of all the numbers of the input vector
Find the sum of all the numbers of the input vector x. Examples: Input x = [1 2 3 5] Output y is 11 Input x ...

environ 4 ans il y a

A résolu


Make the vector [1 2 3 4 5 6 7 8 9 10]
In MATLAB, you create a vector by enclosing the elements in square brackets like so: x = [1 2 3 4] Commas are optional, s...

environ 4 ans il y a

A résolu


Alphabetize by last name
Given a list of names in a cell array, sort the list by the last name. So if list = {'Barney Google','Snuffy Smith','Dagwood ...

environ 4 ans il y a

A résolu


Read a column of numbers and interpolate missing data
Given an input cell array of strings s, pick out the second column and turn it into a row vector of data. Missing data will be i...

environ 4 ans il y a

A résolu


Longest run of consecutive numbers
Given a vector a, find the number(s) that is/are repeated consecutively most often. For example, if you have a = [1 2 2 2 1 ...

environ 4 ans il y a

A résolu


Rescale Scores
Each column (except last) of matrix |X| contains students' scores in a course assignment or a test. The last column has a weight...

environ 4 ans il y a

A résolu


Calculate Inner Product
Given two input matrices, |x| and |y|, check if their inner dimensions match. * If they match, create an output variable |z|...

environ 4 ans il y a

Charger plus