MATLAB enthusiastic

Answered

Returning to start of statement if error

while 1 [file,path] = uigetfile('*.CSV'); % Prompting the user to select a .CSV file from their directory if isequal(f...

Returning to start of statement if error

while 1 [file,path] = uigetfile('*.CSV'); % Prompting the user to select a .CSV file from their directory if isequal(f...

1 hour ago | 0

Answered

Bar plots side by side in order to compare two results

You can display in many ways out of these stating two ways % side by side bar([Main_Result', Simulated_Result']), legend('Mai...

Bar plots side by side in order to compare two results

You can display in many ways out of these stating two ways % side by side bar([Main_Result', Simulated_Result']), legend('Mai...

3 hours ago | 0

| accepted

Solved

Find the maximum number of decimal places in a set of numbers

Given a vector or matrix of values, calculate the maximum number of decimal places within the input. Trailing zeros do not coun...

3 hours ago

Solved

Make roundn function

Make roundn function using round. x=0.55555 y=function(x,1) y=1 y=function(x,2) y=0.6 y=function(x,3) ...

5 hours ago

Answered

how to insert a value into the array in a consistent manner.

Are you asking for this ? A = ones(3, 1); if (size(A,2)>1) A = [0 A]; else A = [0;A]; end

how to insert a value into the array in a consistent manner.

Are you asking for this ? A = ones(3, 1); if (size(A,2)>1) A = [0 A]; else A = [0;A]; end

6 hours ago | 0

Solved

Matlab Basics - Rounding III

Write a script to round a large number to the nearest 10,000 e.g. x = 12,358,466,243 --> y = 12,358,470,000

10 hours ago

Solved

Matlab Basics - Rounding II

Write a script to round a variable x to 3 decimal places: e.g. x = 2.3456 --> y = 2.346

10 hours ago

Solved

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

10 hours ago

Solved

MATLAB Basic: rounding IV

Do rounding towards plus infinity. Example: -8.8, answer -8 +8.1 answer 9 +8.50 answer 9

10 hours ago

Solved

MATLAB Basic: rounding III

Do rounding towards minus infinity. Example: -8.8, answer -9 +8.1 answer 8 +8.50 answer 8

10 hours ago

Solved

MATLAB Basic: rounding II

Do rounding nearest integer. Example: -8.8, answer -9 +8.1 answer 8 +8.50 answer 9

10 hours ago

Solved

MATLAB Basic: rounding

Do rounding near to zero Example: -8.8, answer -8 +8.1 answer 8

10 hours ago

Answered

how to solve 'Error using | Matrix dimensions must agree. ' ?

You have used mrdivide not normal division here. correct one is clc; clear all; T=0:0.001:0.07; size(T); cm=1.; lo=-3.545-...

how to solve 'Error using | Matrix dimensions must agree. ' ?

You have used mrdivide not normal division here. correct one is clc; clear all; T=0:0.001:0.07; size(T); cm=1.; lo=-3.545-...

1 day ago | 0

Answered

[U,V]=eig(A) , AU won't equal UV

In general terms A*U and U*V are equal but in MATLAB it computes with difference in decimal points almost at 15th decimal value ...

[U,V]=eig(A) , AU won't equal UV

In general terms A*U and U*V are equal but in MATLAB it computes with difference in decimal points almost at 15th decimal value ...

1 day ago | 0

| accepted

Answered

Help With error code "WIDTH cannot be larger than the number of points."

See the help of controlchart plot_handle = controlchart([machine_1]', 'charttype', {'xbar', 'r'}'); % applied compliment to ...

Help With error code "WIDTH cannot be larger than the number of points."

See the help of controlchart plot_handle = controlchart([machine_1]', 'charttype', {'xbar', 'r'}'); % applied compliment to ...

1 day ago | 1

| accepted

Solved

Flip the vector from right to left

Flip the vector from right to left. Examples x=[1:5], then y=[5 4 3 2 1] x=[1 4 6], then y=[6 4 1]; Request not ...

1 day ago

Solved

Vector creation

Create a vector using square brackets going from 1 to the given value x in steps on 1. Hint: use increment.

1 day ago

Solved

Doubling elements in a vector

Given the vector A, return B in which all numbers in A are doubling. So for: A = [ 1 5 8 ] then B = [ 1 1 5 ...

1 day ago

Solved

Get the length of a given vector

Given a vector x, the output y should equal the length of x.

1 day ago

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

2 days ago

Solved

Find out sum and carry of Binary adder

Find out sum and carry of a binary adder if previous carry is given with two bits (x and y) for addition. Examples Previo...

2 days ago

Solved

There are 10 types of people in the world

Those who know binary, and those who don't. The number 2015 is a palindrome in binary (11111011111 to be exact) Given a year...

2 days ago

Solved

Relative ratio of "1" in binary number

Input(n) is positive integer number Output(r) is (number of "1" in binary input) / (number of bits). Example: * n=0; r=...

2 days ago

Solved

Converting binary to decimals

Convert binary to decimals. Example: 010111 = 23. 110000 = 48.

2 days ago

Solved

Given an unsigned integer x, find the largest y by rearranging the bits in x

Given an unsigned integer x, find the largest y by rearranging the bits in x. Example: Input x = 10 Output y is 12 ...

2 days ago