Beantwortet
Hey can someone have a look at this for me?
Hi, summary is a predefined Matlab function which works on tables. This causes problems. Choose another name for your function....

mehr als 7 Jahre vor | 1

| akzeptiert

Beantwortet
help me to find max :((
Hi, two steps. Symbolic finding the derivatives and then calculate numeric over the functions you got. syms x y; f(x) = (2.*...

mehr als 7 Jahre vor | 0

| akzeptiert

Beantwortet
how to create this matrix?
Hi, do you want a square matrix? Is the calculation correct without any brackets? My calculation follows the way you wrote the ...

mehr als 7 Jahre vor | 0

Beantwortet
Creating a matrix one row at a time
See this example: y = [1 2 3]; A=zeros(3) for k = 1:3 y = k.*y; A(k,:)=y end Best regards Stephan

mehr als 7 Jahre vor | 0

| akzeptiert

Beantwortet
how can i get the maximum value in the signal in simulink ?
Hi, link your signal to a minMaxResetTable: See also this example in the documentation. Best regards Stephan

mehr als 7 Jahre vor | 0

| akzeptiert

Beantwortet
How do I change the number of variables in a custom equation in the curve fitting tool?
Hi, if you work with only x and y just leave z out. Best regards Stephan

mehr als 7 Jahre vor | 0

| akzeptiert

Beantwortet
Import .csv file using simulink, reading the entry and storing in variable and update the variable with new entry every 0.1s
Hi, you could use the from file block in Simulink. The attached .mat-file contains your data converted to a timeseries object, ...

mehr als 7 Jahre vor | 0

Beantwortet
How to solve Vertcat error to PID graph?
Hi, try: kd=input('enter the value of kd'); kp=input('enter the value of kp'); ki=input('enter the value of ki'); T1=tf([25...

mehr als 7 Jahre vor | 0

Beantwortet
Extracting specific numerical data from array
t = A(A>=24*60 & A<25*60);

mehr als 7 Jahre vor | 0

| akzeptiert

Beantwortet
I need to solve for beta please help me
Hi, use: syms b eqn1 = b*exp((b)^2)*erf(b)==(1000*(383.15-373.15))/(1000*(3.14)^(1/2)); res = vpasolve(eqn1,b) Maybe '3.14'...

mehr als 7 Jahre vor | 0

| akzeptiert

Beantwortet
Is there anyone to help me for Lagrange multipliers method?
Hi, your result is correct. Here is an alternative solution using lagrange multiplier: syms l b h lambda A = l * b + 2 * b * ...

mehr als 7 Jahre vor | 10

| akzeptiert

Beantwortet
Solving an optimization problem with several functions
Hi, one way to solve this is fsolve: format long x0 = [1 1 1 1 1]; options = optimoptions('fsolve', 'Algorithm', 'Levenberg-...

mehr als 7 Jahre vor | 0

| akzeptiert

Beantwortet
How to transform a 2x5184 data set
Hi, here is a small example - change k to 72 to adapt for your case: k = 3; % in your case 72 A = [2 28.2; 2 28.2; 2 28.2; 2....

mehr als 7 Jahre vor | 0

Beantwortet
A wire of 3 m length is to be used to make a circile and a square. How should the wire be distributed between two shapes in order to minimize the sum of the enclosed areas?
Hi, your code returns the correct result. Here is another way to write the same in symbolic form: syms l1 l2 % declare symboli...

mehr als 7 Jahre vor | 2

| akzeptiert

Beantwortet
How to normalize data ?
x = rand(1,25); x = (x-mean(x))/std(x)

mehr als 7 Jahre vor | 1

| akzeptiert

Beantwortet
1-hour to 6-hour aggregation?
Hi, retime should do the job - see the example: a = hours(1:6) + datetime('00:00','format','HH:mm'); b = [1 2 3 4 5 6]; c = ...

mehr als 7 Jahre vor | 0

Beantwortet
Is there an Optimization Tool that returns a function?
Hi, yes, there is functionalDerivative which is useful in this case. See the examples in the documentation. There is a tutorial...

mehr als 7 Jahre vor | 0

| akzeptiert

Beantwortet
Warning: Escaped character '\U' is not valid.
Hi, for backslash use double backslash - that solves the problem, for example: use 'C:\\user' instead of 'C:\user' Do this ...

mehr als 7 Jahre vor | 5

| akzeptiert

Beantwortet
How can get the value for each time step for a variable inside of a function?
Hi, you try this code (all in one file as nested function). The values you want to have in every iteration are now added to the...

mehr als 7 Jahre vor | 0

| akzeptiert

Beantwortet
how to convert 5.5 hour to 05:30:00 HH:MM:SS format?
a = hours(5.5); b = datetime('00:00:00','Format','HH:mm:ss'); result = a+b result = datetime 05:30:00

mehr als 7 Jahre vor | 1

Beantwortet
Matlab jokes or puns
A physicist, a matlab programmer and a firefighter are invited to a social science experiment. Everyone spends a week in a compl...

mehr als 7 Jahre vor | 0

Beantwortet
How to solve iteratively equation
Hi, there is an analytic solution: syms p0 p beta eqn1 = p0 == sqrt(1+64*beta); eqn2 = p == p0+8*(1/p0-1); eqn2 = subs(eqn2...

mehr als 7 Jahre vor | 1

Beantwortet
Having a system of three state I put the odes in a function and the script to solve the given function but now it is executing continuously, so tell me how to stop it?
Hi, try: calculate_system function calculate_system A=[0 1 0;0 0 1;-1 -2 -3]; B=[0 0;0 1;1 0]; C1=[0 1]'; C2=[1 0 ;0 1]; ...

mehr als 7 Jahre vor | 1

Beantwortet
How to select random numbers from array for creating new matrix?
Hi, try: b1=[-3,-1,1,3,5]; A = b1(randi(numel(b1),3,4)) possible result: A = 1 -1 -3 3 -3 5 -...

mehr als 7 Jahre vor | 2

| akzeptiert

Beantwortet
I have a matrix 'm' of oder 4 by6by960. I want to extract 1st and 3rd dimensions, i.e 4by960. how to do this?
Hi, all the non-zero elements are in column 1 - not in column 6: m=rand(4,960); m = [m; zeros(20,960)]; m=permute(reshape(m,...

mehr als 7 Jahre vor | 0

| akzeptiert

Beantwortet
how to read images in MATLAB when images are saved in one folder in the form of image(1),image(2)........image(2000).
Hi, you can use numberedFileNameArray from FEX. Here is an example how to use it: names = numberedFileNameArray(1,5,'C:\user\p...

mehr als 7 Jahre vor | 0

Gesendet


numberedFileNameArray
Creates a string array of file names automatically numbered as specified in input

mehr als 7 Jahre vor | 1 Download |

0.0 / 5

Beantwortet
I need to type a very long equation. How can I do a line break ?
Hi, use for example: f = @(x,y) 2*x^2 + 4*y^3 +... 4*y - 6*x^3 + 3*x^0.5... - 2*x*y + 11*y^(-0.5) + 6 Answer: f = f...

mehr als 7 Jahre vor | 1

Beantwortet
converting gray to RGB
Hi, consider this information regarding the algorithm that rgb2gray uses: "...rgb2gray converts RGB values to grayscale values...

mehr als 7 Jahre vor | 0

Beantwortet
Calculating time component on a function
Hi, have a look to this accepted answer to solve your problem - the question is very similar to yours. Best regards Stephan...

mehr als 7 Jahre vor | 1

| akzeptiert

Mehr laden