Community Profile

Contact

Top 5% contributor

The ODE solvers actually return time... You don't need to do anything extra. [T,Y] = solver(odefun,tspan,y0) Where T is th...

1

Answered 2 years ago

My question has been answered here http://www.mathworks.com/matlabcentral/fileexchange/39354-device-drivers. I needed to change...

accepted

0

I am trying to use existing Arduino libraries with the S-Function Builder or Legacy Code Tool (same result). Particularly, I am...

1 Answers

Asked 2 years ago

I would like to use sfunctions to create function calls to a external c functions. I don't want to build the actual legacy code...

I am using the latest Arduino Simulink support package and am able to build my model and flash to my module using run on target....

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

Solve this!

2 years ago

Remove the nth column from input matrix A and return the resulting matrix in output B. So if A = [1 2 3; 4 5 6]; and ...

If you have two small strings, like 'a' and 'b', return them put together like 'ab'. 'a' and 'b' => 'ab' For extra ...

Suppose you go from position 7 to 10 to 6 to 4. Then you have walked 9 units of distance, since 7 to 10 is 3 units, 10 to 6 is 4...

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

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

Given a circular pizza with radius _z_ and thickness _a_, return the pizza's volume. [ _z_ is first input argument.] Non-scor...

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

Take as input an array of digits (e.g. x = [1 2 3]) and output an array of digits that is that number "incremented" properly, (i...

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

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

Return 1 if the input is sorted from highest to lowest, 0 if not. Example: 1:7 -> 0 [7 5 2] -> 1

Given an input number representing the number of bottles of beer on the wall, output how many are left if you take one down and ...

Return the first and last character of a string, concatenated together. If there is only one character in the string, the functi...

Again, as in "Is my wife right?" ( <http://www.mathworks.com/matlabcentral/cody/problems/149-is-my-wife-right> ), answer 'yes' r...

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.

Regardless of input, output the string 'yes'.

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

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

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

I am working on a Matlab function block in a Simulink model, and the auto-correct is re-naming some variables every time I go to...

0 Answers

Asked 5 months ago

I found some documentation that pertains to newer versions (2014a) for propagating signal names from inside of the model referen...

Asked 1 year ago

Try this code snippet I have in my inventory as an example. t = 0 ; x = 0 ; startSpot = 0; interv = 1000 ; % con...

It sounds like you are looking for the cell2mat function. This will convert a cell array to numeric array which you can use to ...

In the Variant Subsystem > Subsystem Parameters, there is a check box for "Override variant conditions and use the following var...

Load more