Beantwortet
Ergebnis enthält "oder"
syms y(x) f = y(x)^2 * (diff(y(x), x))^2; eqn = functionalDerivative(f,y) == 0; %Get the equation mentioned in the question...

mehr als 2 Jahre vor | 1

Beantwortet
Table row retrieval with dependent on column values
Rec_id =[1; 1; 2; 2; 2; 3; 3; 4; 4]; % for clarification: the values here go up to 80 in the original table Rec_type= {'A';'B';...

mehr als 2 Jahre vor | 1

| akzeptiert

Beantwortet
dendrogram関数の配色を任意のものにする
dendrogram is basically a group of lines. Thus, you will have to change the color of each lines accordingly - load fisheriris ...

mehr als 2 Jahre vor | 0

| akzeptiert

Beantwortet
how to remove all the value zero in column 2?
%Example A = num2cell([0;rand(10,1);0;0;rand(5,1);0;0;0;1]); B = num2cell(char(randi([30 50], numel(A), 1))); C = [B A] %Fin...

mehr als 2 Jahre vor | 0

Beantwortet
solve by the matrix method
Use mldivide, \

mehr als 2 Jahre vor | 0

Beantwortet
Side by side subplots with one split into 3
Use tiledlayout - tiledlayout(3, 2) %Span a tile across 3 rows and 1 column nexttile([3 1]) fplot(@sin) nexttile scat...

mehr als 2 Jahre vor | 1

Beantwortet
How to run 3 script in sequence?
First of all, Never use built-in functions as variable or scripts names. You should modify the names of the scripts; for e.g. ...

mehr als 2 Jahre vor | 1

| akzeptiert

Beantwortet
How to define function include others functions in matlab
X = @(u) 1-u; Y = @(v) 1-v; R = @(u,v) sqrt(X(u).^2+Y(v).^2); %Integrate R w.r.t u from 0 to 1 %and w.r.t v from 1 to 2 ...

mehr als 2 Jahre vor | 1

| akzeptiert

Beantwortet
グラフのy軸の目盛りラベルにて、整数部の表示桁数を指定する方法について
The ticklabels are stored as the mantissa and the exponent is stored as the property of the corresponding axis (see below). So,...

mehr als 2 Jahre vor | 1

| akzeptiert

Beantwortet
error in using eig built-in function
The symbolic function eig does not support the syntax that you are trying to use. The numeric function eig does. So, you can...

mehr als 2 Jahre vor | 0

Beantwortet
cell array for loop assignment
An approach without loops - A = {rand(10,2),rand(10,2),rand(10,2),rand(10,2)} B = horzcat(A{:}) C = mat2cell(B, [5 5], [2 2 ...

mehr als 2 Jahre vor | 1

Beantwortet
How to combind a 1d Matrix with a 3d Matrix to form a 4d Matrix?
A = rand(10000,28,28); B = rand(10000,1); A = permute(A, [2 3 4 1]); B = permute(B, [4 3 2 1]); size(A) size(B) C = A.*B...

mehr als 2 Jahre vor | 0

| akzeptiert

Beantwortet
how to use makeUniqueStrings
Utilize the functionality of strings - vec1 = 1:10; vec2 = 4:10; [vec1 "A"+vec2]

mehr als 2 Jahre vor | 0

| akzeptiert

Beantwortet
fill the entry of a vector with a given distance
M = 10; A = [1;zeros(M-1,1)]; d = 3; A(d+1:d+1:end-(d+1))=1

mehr als 2 Jahre vor | 1

Beantwortet
How to save .mat files on the disk after each iteration?
The values will be over-written in each iteration, so you don't need to clear them. for k = 1:number_of_iterations %get im...

mehr als 2 Jahre vor | 0

| akzeptiert

Beantwortet
sym에서 double로 변환할 수 없다는 오류가 뜨는데 어떻게 해결해야 할까요?
You need to pass the function to be analysed as a function handle - % vvvvv golden(@trig,1,3,10^-8,10^-8) function g...

mehr als 2 Jahre vor | 0

| akzeptiert

Beantwortet
Merge tables based on a string key
Use innerjoin

mehr als 2 Jahre vor | 0

| akzeptiert

Beantwortet
How to find same values in an array and their index
arr = load('array.mat') mat = arr.yintercept val = 1e-6; %As you are dealing with floating point numbers, use tolerance to ...

mehr als 2 Jahre vor | 0

Beantwortet
How to convert 4D double matrix into 2D arrays
Use squeeze - in = rand(1,1,101,14); size(in) out = squeeze(in); size(out)

mehr als 2 Jahre vor | 1

| akzeptiert

Beantwortet
Loop inside a loop isn't working
There are 2001 elements in x, not 2000. (Imo) It's better to use numel() to get the number of elements, rather than manually usi...

mehr als 2 Jahre vor | 0

| akzeptiert

Beantwortet
how create cell 1:10 vertical
c = (1:10).'; c = num2cell(c)

mehr als 2 Jahre vor | 1

| akzeptiert

Beantwortet
Help with Pre-allocating function values
Dynamically growing arrays is detrimental to the performance of the code. You should Preallocate arrays according to the final o...

mehr als 2 Jahre vor | 1

Beantwortet
come posso eliminare le colonne di una matrice?
From what I understand - %Random data as input %Here columns 6, 7 and 8 are same as columns 2, 3, and 5 respectively in = [1...

mehr als 2 Jahre vor | 0

| akzeptiert

Beantwortet
Set aspect ratio of stacked plot
You can change the (inner) position of the stacked plot - https://in.mathworks.com/help/matlab/ref/matlab.graphics.chart.stacked...

mehr als 2 Jahre vor | 0

| akzeptiert

Beantwortet
Trying to get a equation in terms of symbolic values but cant
As you are adding Symbolic variables, pre-allocate P as a symbolic array - % vvv P = sym([0; 0; 0;]) syms V3 theta2 theta3...

mehr als 2 Jahre vor | 0

Beantwortet
Create function that varies between 1 and zero if input is 1 or 2
The output variable should be the same - y1 = delt(1) y2 = delt(2) y3 = delt(-69) function y = delt(x) if x == 2 ...

mehr als 2 Jahre vor | 0

| akzeptiert

Beantwortet
plotting same values as individual points on x-axis
x=[1,2,3,4,5,1,2,3,4,5,1,2,3,4,5]; y=[1,1,1,1,1,1,1,1,1,1,1,1,1,1,1]; vec = 1:numel(y); scatter(vec,y) xticks(vec) xtickl...

mehr als 2 Jahre vor | 0

| akzeptiert

Beantwortet
How to add Mean and Median to a boxplot?
sample=readmatrix('Data.csv'); x=sample(1:end,1); xString=string(x); dataSample=sample(:,2:end); %Calculate mean m = mean...

mehr als 2 Jahre vor | 2

| akzeptiert

Beantwortet
Need to delete the previous points in a plot while plotting continously
Change colors and other properties as you like/prefer. x = [1,2,3,4,5]; y = [3,4,5,6,7]; plot(x, y, 'r') hold on h = anim...

mehr als 2 Jahre vor | 0

| akzeptiert

Beantwortet
MATLABで得られたデータをExcelの各シートに名前を付けて保存したい!
x_data = [1, 2, 3, 4, 5]; y_data = [6, 7, 8, 9, 10]; z_data = [11, 12, 13, 14, 15]; str = ["x" "y" "z"] + "data"; arr = ta...

mehr als 2 Jahre vor | 0

| akzeptiert

Mehr laden