Réponse apportée
With ischar usage - I get two different answers
"Why is that?" Because a character array (char) and a string array (string) are different. They are both different data types f...

plus de 2 ans il y a | 2

Réponse apportée
while iam trying to execute my code iam getting error
Numeric arrays in MATLAB are homogenous. When you initialize h(1) as a double array, then any elements to be added to it are e...

plus de 2 ans il y a | 0

Réponse apportée
How to write an exponent in an axis label when the matlab syntax doesn't work?
Try this - t = -5:.01:5; x = exp(t/10); figure(1) scatter(x,t,24,'filled') xlabel('t') ylabel('e^{(t/10)}')

plus de 2 ans il y a | 1

Réponse apportée
how to change zero in series number
Assuming the last element is not zero - in = [0 2 3 5 1 6 0 0 3 4 7 2 0 6 2].'; idx = in==0; while any(idx) in(idx) =...

plus de 2 ans il y a | 1

Réponse apportée
reverse operation to 'strsplit'
Use strjoin

plus de 2 ans il y a | 0

| A accepté

Réponse apportée
Create Subparts in one problem on MATLAB grader
Yes, in addition to tests provided by the MATLAB Grader, you can include your custom assessments. See the documentation for > F...

plus de 2 ans il y a | 0

Réponse apportée
calculate the perimeter of a polygon arranged in space
I am not sure what the idea behind that method is, but it does not give the correct result - load plane_new figure x = plane...

plus de 2 ans il y a | 0

| A accepté

Réponse apportée
Code for Delay differential analytical Solution. Its showing error. Please correct it. Kindly do the Needful.
There is missing operator between k and the left parenthesis as shown below - Fix it and the code will work. t=linspace(0,120...

plus de 2 ans il y a | 0

Réponse apportée
Setting a textbox returning error 'Unable to resolve the name'
The function does not know what "S" is. You need to pass it as an input. And the font name 'Comic Sans MS' does not have ellips...

plus de 2 ans il y a | 0

Réponse apportée
Using "if" and "disp" in a comparison of two numbers
You need to use the elseif condition. Refer to the documentation for more info - if, elseif, else a=5;%input("Give a value f...

plus de 2 ans il y a | 0

| A accepté

Réponse apportée
Grab 20 lines and make a graph
"Can anyone tell me?" I assume you wanted to ask why that happens. You have provided a matrix as the single input to plot. ...

plus de 2 ans il y a | 0

Réponse apportée
Relative pose in 2D: problem 1
Given that the frame of reference is a cartesian co-ordinate system, the angle is supposed/expected to be calculated w.r.t x-axi...

plus de 2 ans il y a | 0

| A accepté

Réponse apportée
Where is the month, day and year string stored in a plot with a datetime axis which shows hours and minutes in the xticklabel string?
The data is stored as the x-tick values. They can be edited, but not all properties can be changed. One option to specify form...

plus de 2 ans il y a | 0

Réponse apportée
Error using fopen for obj file
You should try these functions instead of fopen - https://in.mathworks.com/matlabcentral/fileexchange/27982-wavefront-obj-tool...

plus de 2 ans il y a | 1

Réponse apportée
How to plot these figures into a graph with tons of data
Assuming that you want to plot using the values in the 1st column as x-values - Firstly, you would need to convert the 1st colu...

plus de 2 ans il y a | 0

Réponse apportée
Obtaining max value from cyclic data
For each cycle, finding the maximum of the temperatures corresponding to the step == 3; %Read the data T = readtable('Referenc...

plus de 2 ans il y a | 0

| A accepté

Réponse apportée
Create a loop with doubling the previous number minus 1
Use a while loop and perform the operation in each iteration - %Starting value x = 2; %Run the loop till the value of x is...

plus de 2 ans il y a | 1

Réponse apportée
How to create a long matrix rapidly
ones does exist, but using eye would be easier and faster here - n = 10; x = 1 - eye(n)

plus de 2 ans il y a | 1

Réponse apportée
Square wave with randomly varying frequency
The increment in time vector too small to clearly resolve the output wave-form. You can either zoom into parts of wave form to ...

plus de 2 ans il y a | 0

Réponse apportée
Meshgrid on inhomogeneous surface plot
To modify the lines on the surface, you will have to modify the underlying data. You might not be able to get the exact shape, ...

plus de 2 ans il y a | 0

Réponse apportée
the size of picture show three data?
It does not result in 3 images. That is a single image only, which is stored as a 3D array. That is a RGB image, also referred...

plus de 2 ans il y a | 0

Réponse apportée
Determining area considering nodes arranged in space in an almost circular shape
Directly use polyarea - load('plane_new.mat') x = plane_new(:,1); y = plane_new(:,2); plot(x,y,'.-r') A = polyarea(x...

plus de 2 ans il y a | 1

| A accepté

Réponse apportée
I need to keep only specific columns from the .csv table
%Read the data tb = readtable('satellites-16-Jan-2024.csv', VariableNamingRule="preserve") %Compare the values from 2nd column...

plus de 2 ans il y a | 0

| A accepté

Réponse apportée
Revert y-axis order in BarPlot
There are multiple ways to do that. One simple way is reverse the Y-axis direction (assuming the data is originally sorted des...

plus de 2 ans il y a | 0

| A accepté

Réponse apportée
Adding and dividing elements in a 3D array
A = rand(15,5,120); B = (A(1:end-1,:,:) + A(2:end,:,:))/2 size(B)

plus de 2 ans il y a | 1

| A accepté

Réponse apportée
How could I fix the parsing error on line 8
The most notable issue I can see is the un-supported character in the 8th line before the fix() call, which appears as a box. R...

plus de 2 ans il y a | 1

Réponse apportée
How change only second number in a=ones(1,10)?
Simply use indexing to change the element - a = ones(1,10); a(2) = 2

plus de 2 ans il y a | 0

| A accepté

Réponse apportée
一つの3次元座標軸内に複数の球面をプロットしたい
They are plotted in 3D, you just need to change the line of sight. Check view for more information. D = [4.8115220,1.5733090,1...

plus de 2 ans il y a | 0

| A accepté

Réponse apportée
What hardware Matlab Online uses?
As MATLAB Online runs on a Linux OS, run this command and see the output - system('lscpu')

plus de 2 ans il y a | 2

| A accepté

Réponse apportée
changing expression to function
You will have to define x and y as symbolic variables first - %Random values for example a = rand(1,10); b = rand(1,10); ...

plus de 2 ans il y a | 0

Charger plus