Risposto
Unable to perform assignment because the indices on the left side are not compatible with the size of the right side - Jacobi method inverse calculation
Function errnorm(vec) has inconsistent size. Try the following modifications: function [abserr] =errnorm(vec) vec = abs(ve...

oltre 6 anni fa | 1

| accettato

Risposto
Undefined function 'abs' for input arguments of type 'cell'.
It is saying A is a cell type. In order to check it, run the following code: class(A) If this is the case, the following shoul...

oltre 6 anni fa | 1

| accettato

Risposto
Rewrite for loop with find function
The function find returns the indeces according to the condition. So, in order to diplay the values, you might use the following...

oltre 6 anni fa | 1

Risolto


How to find the position of an element in a vector without using the find function
Write a function posX=findPosition(x,y) where x is a vector and y is the number that you are searching for.

oltre 6 anni fa

Risolto


Determine if input is a perfect number
A <http://en.wikipedia.org/wiki/Perfect_number/ perfect number> occurs whent the sum of all divisors of a positive integer, exce...

oltre 6 anni fa

Risolto


Is it an Armstrong number?
An Armstrong number of three digits is an integer such that the sum of the cubes of its digits is equal to the number itself. Fo...

oltre 6 anni fa

Risolto


First N Perfect Squares
*Description* Return the first N perfect squares *Example* input = 4; output = [ 1 4 9 16 ];

oltre 6 anni fa

Risolto


Project Euler: Problem 1, Multiples of 3 and 5
If we list all the natural numbers below 10 that are multiples of 3 or 5, we get 3, 5, 6 and 9. The sum of these multiples is 23...

oltre 6 anni fa

Risolto


Cell joiner
You are given a cell array of strings and a string delimiter. You need to produce one string which is composed of each string fr...

oltre 6 anni fa

Risolto


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

oltre 6 anni fa

Risolto


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

oltre 6 anni fa

Risolto


Create a vector
Create a vector from 0 to n by intervals of 2.

oltre 6 anni fa

Risolto


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

oltre 6 anni fa

Risolto


Whether the input is vector?
Given the input x, return 1 if x is vector or else 0.

oltre 6 anni fa

Risolto


Find max
Find the maximum value of a given vector or matrix.

oltre 6 anni fa

Risolto


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

oltre 6 anni fa

Risolto


Inner product of two vectors
Find the inner product of two vectors.

oltre 6 anni fa

Risolto


Arrange Vector in descending order
If x=[0,3,4,2,1] then y=[4,3,2,1,0]

oltre 6 anni fa

Risolto


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

oltre 6 anni fa

Risolto


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

oltre 6 anni fa

Risposto
Accessing data variables from another function
I did not get the final goal, but I fixed your code. F2([1,1,1 ; 2 2 2 ; 3 3 3]) function [Q,R] = F1(A) Q = 2*A R ...

oltre 6 anni fa | 1

| accettato

Risposto
I need a code to count how many raw in my matrix above zero?
You might use the function find (https://www.mathworks.com/help/matlab/ref/find.html). Check the following code: B = [1,-1; 2,...

oltre 6 anni fa | 0

Risposto
Index exceeds the number of array elements (2)
Hi Ali, Your dsolve function has 4 states variables: dx(1,1), dx(2,1), dx(3,1), and dx(4,1). Therefore you need an initial vari...

oltre 6 anni fa | 1

Risposto
How to define limit of quiver axis?
You could use axis function. For more information check here: https://www.mathworks.com/help/matlab/ref/axis.html See the follo...

oltre 6 anni fa | 3

| accettato

Risolto


Multiply 2 numbers
Very easy, you just have to multiply 2 numbers but you cannot use the following signs (*, /, - ,^) ,mtimes , times, cross, pro...

oltre 6 anni fa

Risolto


Angle between Two Vectors
The dot product relationship, a dot b = | a | | b | cos(theta), can be used to determine the acute angle between vector a and ve...

oltre 6 anni fa

Risolto


Is the Point in a Circle?
Check whether a point or multiple points is/are in a circle centered at point (x0, y0) with radius r. Points = [x, y]; c...

oltre 6 anni fa

Risolto


Calculate the area of a triangle between three points
Calculate the area of a triangle between three points: P1(X1,Y1) P2(X2,Y2) P3(X3,Y3) these three points are the vert...

oltre 6 anni fa

Risolto


Angle between two vectors
You have two vectors , determine the angle between these two vectors For example: u = [0 0 1]; v = [1 0 0]; The a...

oltre 6 anni fa

Risolto


Right and wrong
Given a vector of lengths [a b c], determines whether a triangle with those sides lengths is a right triangle: <http://en.wikipe...

oltre 6 anni fa

Carica altro