Solved


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

ungefär 4 år ago

Question


How to save a callback function
I need to save a datacursormode callback function, as a local variable (at least the syntax) . The argument of this function is...

ungefär 4 år ago | 0 answers | 0

0

answers

Solved


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

ungefär 4 år ago

Solved


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

ungefär 4 år ago

Solved


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

ungefär 4 år ago

Solved


Interpolator
You have a two vectors, a and b. They are monotonic and the same length. Given a value, va, where va is between a(1) and a(end...

ungefär 4 år ago

Solved


Make a checkerboard matrix
Given an integer n, make an n-by-n matrix made up of alternating ones and zeros as shown below. The a(1,1) should be 1. Examp...

ungefär 4 år ago

Solved


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

ungefär 4 år ago

Solved


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

ungefär 4 år ago

Answered
how to upload a random excel file and read it
The trick is that your functions have local variables, you need to send them out using the handles. you may use the import da...

ungefär 4 år ago | 0

Question


How to create an object using class name
In my function, I am getting the class name from an object to create a new one. What is the right syntax to creat the new Object...

ungefär 4 år ago | 3 answers | 0

3

answers

Question


Icon (start, finish, waypoint,checkflag) on plot
Is there any graphical icon already implemented in MATLAB for 2D /3D plots?

ungefär 4 år ago | 1 answer | 0

1

answer

Answered
Mqtt toolbox in Matlab unable to process all mqtt messages
I also confirm that the function readall is not performing as expected, causing a downsampling. I am generating a sinus wave 2H...

ungefär 4 år ago | 0

Answered
Mqtt toolbox in Matlab unable to process all mqtt messages
I suspected the Quality Of Service set to 2, but it is not influencing the number of readings

ungefär 4 år ago | 0

Answered
How to connect local host with mqtt client/broker??
Check your IP adress of your localhost (ipconfig or ifconfig if you are linux user): this would be the address to use : 'tcp://0...

ungefär 4 år ago | 0

Question


How to pass the object name as a selectable property?
Hi all, I have started to use some hgtransform objects and started to group them. The idea is to build generic configurable gr...

ungefär 4 år ago | 1 answer | 0

1

answer

Answered
How to plot the real time data from arduino?
With a bit of delay, the issue is in your Arduino code: Serial.available will return the number of bytes you can read. So you ...

ungefär 4 år ago | 0

Solved


Weighted average
Given two lists of numbers, determine the weighted average. Example [1 2 3] and [10 15 20] should result in 33.333...

ungefär 12 år ago

Solved


Is my wife right?
Regardless of input, output the string 'yes'.

ungefär 12 år ago

Solved


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

ungefär 12 år ago

Solved


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

ungefär 12 år ago

Solved


Determine if input is odd
Given the input n, return true if n is odd or false if n is even.

ungefär 12 år ago

Solved


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

ungefär 12 år ago

Solved


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

ungefär 12 år ago

Solved


Times 2 - START HERE
Try out this test problem first. Given the variable x as your input, multiply it by two and put the result in y. Examples:...

ungefär 12 år ago