Differential equations I
Given a function handle |f| an initial condition |y0| and a final time |tf|, solve numerically the differential equation
dy...
Calendar Matrix
Return a calendar matrix for the given values of month and year. Assume that Sunday is the first day of the week. The resulting ...
1 year 前
已解决
Rainbow matrix
Create a "rainbow matrix" as described in the following examples
Input = 3
Output = [ 1 2 3
2 3 2
...
1 year 前
已解决
Generate this matrix
For a given odd integer n, generate a matrix as follows:
Input: n = 5;
Output:
[ 2 1 0 0 0
1 ...
1 year 前
已解决
ZigZag matrix with reflected format
ZigZag MATRIX with REFLECTED format.
We have only input x. We have to create a matrix in the following pattern.
input n=5...
1 year 前
已解决
The Matrix Construction
Given two input ,first one is CN (Column Number), Second one is Dim
Can you produce such a matrix for example
CN=6; Dim=2
...
1 year 前
已解决
Toeplitz Matrix
For a given square matrix of order n-by-n check whether this is a Toeplitz matrix or not. Return true if it is.
1 year 前
已解决
Generate this matrix
Generate the following matrix.
n = 2;
out = [-4 -3 -2 -1 0
-3 -2 -1 0 1
-...
1 year 前
已解决
Create a block diagonal matrix
A block diagonal matrix is a square matrix that can be written as
A = [a 0 0 0
0 b 0 0
0 0 c 0
...
1 year 前
已解决
Matrix Construction I
Given n, construct a matrix as shown in the example below.
Example
For n=8, the output should look like this:
1 2 3 4 ...
1 year 前
已解决
Matlab Basics - Rounding II
Write a script to round a variable x to 3 decimal places:
e.g. x = 2.3456 --> y = 2.346
2 years 前
已解决
Check that number is whole number
Check that number is whole number Say x=15, then answer is 1. x=15.2 , then answer is 0. http://en.wikipedia.org/wiki/Whole_numb...
2 years 前
已解决
MATLAB Basic: rounding IV
Do rounding towards plus infinity.
Example: -8.8, answer -8
+8.1 answer 9
+8.50 answer 9
2 years 前
已解决
MATLAB Basic: rounding III
Do rounding towards minus infinity.
Example: -8.8, answer -9
+8.1 answer 8
+8.50 answer 8