Beantwortet
Slope of a curve
Slope is the change in the y value divided by the change in the x value. When dealing with numerical calculations, there are a ...

mehr als 8 Jahre vor | 3

| akzeptiert

Frage


Why use an "if" statement to encapsulate a block of code?
I notice that many users encapsulate their code inside an if statement such as if true ... (code) ... end What...

mehr als 8 Jahre vor | 1 Antwort | 1

1

Antwort

Beantwortet
Euler's Method for stiff ODE
Torsten is right. There is no way you will get a solution with a large step size (h=5). I checked out your code and it works ...

mehr als 8 Jahre vor | 0

| akzeptiert

Beantwortet
How to create a counter variable in a loop
What you are describing sounds like a histogram. You can use the function "histcounts" to count the number of times a number ap...

mehr als 8 Jahre vor | 1

Beantwortet
Hi, I am new to MATLAB. I am not getting the plot .
Inside the abs function you are dividing two vectors. This is where the error is.

mehr als 8 Jahre vor | 0

Beantwortet
help please why ??
the statement sum(A(1)) is summing only the first element in A, which is 1. If you want to sum the first row, it shoul...

mehr als 8 Jahre vor | 2

| akzeptiert

Beantwortet
"Model based development and testing using PLC coder"
Model Based: Any endeavor that is "Model Based" places an emphasis on the use of simulation models. "Model Based Developm...

mehr als 8 Jahre vor | 0

Beantwortet
Divide vector of coordinates into even intervals.
Based on your description of the problem, this is what I would do: Given a vector of lat/lon positions which represents one r...

mehr als 8 Jahre vor | 0

| akzeptiert

Beantwortet
Newbie question - Error in line 2
Your equation set looks like it produces a direction cosine matrix for a planar rotation about the Z axis. If this is the case,...

mehr als 8 Jahre vor | 0

Beantwortet
How would I improve my euler code?
For trapezoidal integration, you use the average of two consecutive evaluations. This could be done by simply adding one line of...

mehr als 8 Jahre vor | 0

| akzeptiert

Beantwortet
convert wind direction in true North to Math convention
Working with wind direction vectors can be confusing, because there are two different conventions which are both widely used. ...

mehr als 8 Jahre vor | 1

| akzeptiert

Beantwortet
MATLAB -- how to create a parabolic arc?
This is a simple polynomial curve fit problem. If you have the curve fitting toolbox, the problem is solved by: x = [0 5 10...

mehr als 8 Jahre vor | 0

Beantwortet
Centering Multiple circular images
Here is a thought. The images appear to have some significant circular waves emanating from the (presumed) center. I would u...

mehr als 8 Jahre vor | 0

| akzeptiert

Beantwortet
Measure depth tread of the tire?
I can't imagine how you will get tread depth from this photo. Wouldn't you rather have a photo of the profile, similar to the a...

mehr als 8 Jahre vor | 0

| akzeptiert

Beantwortet
Merge block connection issue
Look at help for the merge block. Merge is intended for use with conditionally executed blocks where only one of the blocks i...

mehr als 8 Jahre vor | 0

Beantwortet
How do I create a for loop to separate each oscillation on a plot to take the average of each section.
Here is a suggestion for an algorithm: Your data looks like it settles down very well in between events, so I would use a sli...

mehr als 8 Jahre vor | 0

Beantwortet
How to find the nth derivative of square root of a polynomial using forward or backward differences. f(x)=sqrt(a0+a1 x + a2 x^2+a3 x^3+...an x^n)
See the attachment for numerical derivative formulas from my collection.

mehr als 8 Jahre vor | 0

Beantwortet
what do the variable P,I and D mean in PID(z) in simulink?
See the link to help in Guillaume's comment: Proportional Integral Differential

mehr als 8 Jahre vor | 0

Beantwortet
Generate a 4-Hz, 1000-point sine wave with a sample interval of T=0.002, and use quantiziation to digitize it using a 4-,8-,12-, and 16-bit ADC...
The first thing I notice is that signal_in is computed from signal_in = sin(2*pi*frequency*t) but variable "frequency" ...

mehr als 8 Jahre vor | 0

Beantwortet
Simulink: Buffer with constant input due to delay of input
The default sample time for a constant block is "inf". Based on the error message, the first thing I would check is the sample ...

mehr als 8 Jahre vor | 0

Beantwortet
How can i make my MATLAB code to run faster or robust while having many function calls and for loop up to thousands?
There is one blanket method which will speed up any Matlab code - use the Matlab compiler to generate an executable (.exe) file....

mehr als 8 Jahre vor | 1

Beantwortet
Why is an empty string not empty? isempty('') returns true, but isempty("") returns false
As near as I can tell, Matlab does not use the double quote character, so isempty("") is not a valid statement.

fast 9 Jahre vor | 0

Beantwortet
Please , how can I find the center and the radius of the inscribed circle of a set of points
I have worked this problem in the past, and the only solution I could find was a numerical searching method. There are a number...

fast 9 Jahre vor | 1

Beantwortet
How can I create semicircle signal in Simulink?
I would use the MATLAB Function block with the code in the PDF file attachment. (Found a typo in the first attachment. Pleas...

fast 9 Jahre vor | 0

Beantwortet
discrete simulink model problem
Although I am unable to open and view your model, a very common problem when converting from continuous to discrete is that the ...

fast 9 Jahre vor | 1

| akzeptiert

Beantwortet
Matlab function in Simulink - calling variable from workspace
Try declaring the variables to be persistent at the top of the function, i.e. persistent prev_angle prev_counter

fast 9 Jahre vor | 2

| akzeptiert

Beantwortet
How to get a sin function in simulink
I'm a little confused by the problem statement. Inside the sine function you have x/2000 * t. I'm not sure which represents th...

fast 9 Jahre vor | 0

Beantwortet
Find coordinates point M
See attachment. The symbolic solution will be very messy and require quite a lot of algebra. If you have the symbolic math t...

fast 9 Jahre vor | 0

| akzeptiert

Beantwortet
[EMERGENCY NEED CRITICAL HELP] Numerically determine the Voltage
You are given an equation for i(t). All you need to do is integrate it directly, but your instructions are to perform the integ...

fast 9 Jahre vor | 1

Beantwortet
[PLEASE HELP] Derive the time and distance values...
After looking at your table, it is clear that you are given a time history of velocity and acceleration samples and you wish to ...

fast 9 Jahre vor | 0