Answered
how to write the script file for condition statement and loops?
If your data is in a Table array format, then it is best to use logical indexing that is many times faster and efficient than lo...

5 years ago | 0

Answered
solve function results come as function not numbers
Here is the corrected part of your code: ... n= double(S(double(S)>0)); P_out=subs(Po/1000, n); R=double([f VLL n P_out])

5 years ago | 1

Answered
How to loop on several inputs and variables?
Your calcs are quite simple and your code has to work ok with any number of input data points. To ease the input process, you ma...

5 years ago | 1

| accepted

Answered
Handwritten recognition using CNN
The error with your employed fcn called net() that is not defined as a function and considered in your code as a variable. Thus,...

5 years ago | 0

| accepted

Answered
Study of oscillations and how to solve in MATLAB
for all w's: clearvars syms y(t) Dy = diff(y, t); D2y = diff(Dy, t); w0 = 10; b = 0.1; F = 10; w = [10.0, 5.0, 3.0, 0.0]; %...

5 years ago | 1

Answered
How can I solve this matrix problem?
You can start working with eye() and rot90() Then you can try with for loop, i.e. [for .. end] and [while .. end]

5 years ago | 0

Answered
How to extract a particular colour from an RGB image?
(1) Image read: imread('traffic.png') (2) Select and Find out the pixel value ranges of a red color, e.g.: I = imread('traffi...

5 years ago | 0

Answered
How do I run simulink in matlab script and use that result of simulation in matlab again?
Run these edited comands instead: OUT = sim('Project_quartercar_example.slx'); y1=max(OUT.simout(:,1)); t = OUT.tout; plot...

5 years ago | 0

| accepted

Answered
How to extract the parameters through curve fitting
(1) Import the data using readtable(), e.g: D = readtable('IdVg.xlsx'); v=table2array(D(:,1)); TR=table2array(D(:,2)); (2) U...

5 years ago | 1

| accepted

Answered
Solving non-linear differential system
You can use: syms to introduce the variables and then employ dsolve to get symbolic solutions, e.g.: syms S(t) M(t) I(t) T(t)...

5 years ago | 0

Answered
Histogram2 tile(Indicating the values of each tile inside the tile)
Hi, This discussion demonstrates explicitly how to show histogram2 data points within plotted tiles and provides codes (fcn fi...

5 years ago | 0

| accepted

Answered
find the minimum distances of all points from neighboring points
Here is a nice discussion on this issue with some well developed scripts: https://www.mathworks.com/matlabcentral/answers/30949...

5 years ago | 0

Answered
3d compass plot
In this case, quiver() plot would be more appropriate to employ. SInce you are trying to demonstrate directions of vectors. htt...

5 years ago | 0

Answered
How to insert transparent background image behind several line plot?
First, your display your image and then plot on top of that image, e.g. x = imread('MYimage.jpg'); imshow(x),colormap jet hol...

5 years ago | 0

| accepted

Answered
Select repeating elements in an matrix
A = [???] % Your data B = A(A(:,1)==1, :) Good luck

5 years ago | 1

| accepted

Answered
Trying to build a new nx4 array from an existing nx4 array using logical values
Don't use MATLAB's builtin function and comamnd names for variables, e.g.: min is builtin fcn of MATLAB.

5 years ago | 0

Answered
Gradient Computation of Matrix
[Gx, Gy] = gradient(G) And dont forget elementwise operation: ./

5 years ago | 0

Answered
how do i solve this summation ?
Use of loop: [for .. end] and [while ... end]. If the numbers get large and accuracy is a concern to use: vpa()

5 years ago | 1

Solved


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

5 years ago

Solved


Min of a Matrix
Return the minimum value in the given matrix.

5 years ago

Solved


Love triangles
Given a vector of lengths [a b c], determines whether a triangle with non-zero area (in two-dimensional Euclidean space, smarty!...

5 years ago

Solved


Beginner's Problem - Squaring
Try out this test problem first. Given the variable x as your input, square it by two and put the result in y. Examples: ...

5 years ago

Solved


01 - Scalar variables
Create the following variables: <<http://samle.dk/STTBDP/Assignment1_1.png>>

5 years ago

Solved


Remove the first, third and fifth rows of a matrix
Given a matrix x with at least five rows, return a matrix y that includes all rows of x except for th 1st, the 3rd and 5th. E...

5 years ago

Solved


Rotate a Matrix
Input a Matrix x, Output y is the matrix rotating x 90 degrees clockwise

5 years ago

Solved


Sum of Two Numbers
Given two integer numbers x and y, calculate their sum and put it in z. Examples: Inputs x = 2, y = 4 Output z is 6 ...

5 years ago

Solved


We love vectorized solutions. Problem 1 : remove the row average.
Given a 2-d matrix, remove the row average from each row. Your solution MUST be vectorized. The solution will be tested for ac...

5 years ago

Solved


Who knows the last digit of pi?
There is only one man who knows the last digit of pi, who is that man? Give the name of that man, who, by popular believe, can ...

5 years ago

Solved


only input
Return the output without writing any code into the function.

5 years ago

Solved


Area of a triangle
A triangle is given with base *'b'* ,vertical hight *'h'* . then find it's area.

5 years ago

Load more