Questions tagged [numerical]

This tag is for questions concerning problems using numbers which either cannot be exactly solved, or where the exact solution may be much more difficult to acquire than by using numerical methods.

This tag is for questions concerning problems using numbers which either cannot be exactly solved, or where the exact solution may be much more difficult to acquire than by using numerical methods.

It includes questions about algorithms, precision and accuracy of underlying numbers, advantages and disadvantages of several methods, error propagation, problems with the underlying numbers and data structures.

508 questions
0
votes
1 answer

Using Python Interactive as a Programming Calculator

I have used AnalogX PCalc for years as my go to calculator for back of the envelope interactive calculations where integer math is important and flexible base input and output is important. For example, when working with fixed point numbers, often…
David Perek
  • 141
  • 3
0
votes
1 answer

Find the quadratic AND the cubic polynomial interpolating this data set?

I can't make heads or tails of how to do this question; I thought there was only one interpolating polynomial for a set of data points. Here is the data set: Data Set [0,0], [10,102.6903], [20,105.4529], [30,81.21744], [40,55.6016], [50,35.6859] We…
0
votes
4 answers

Is the "e" character used to denote an invalid number in graphics data?

I've got a graphical program that's exporting a data file with numbers such as: -1.33227e-015 and -4.02456e-016. I've long been perplexed by the "e-" notation. Is it used to denote an invalid number? What sort of valid value can I extract from the…
Robin Rodricks
  • 110,798
  • 141
  • 398
  • 607
0
votes
1 answer

Matlab - polyval data differentiation

I am working on some problems with curve fitting ect, and need to find the derivative of a cubic fit of 50 points. The questions asks to find the growth rate of bacteria given data. My current code is time = [1,2,4,5,7,9]; bacteria =…
Vladamir
  • 247
  • 1
  • 3
  • 11
0
votes
0 answers

Numerical derivative of function wrt natural log of variable

The function that I am trying to evaluate is d y / d ln(x) where d is the derivative. However I have a set of data points for x and y with uncertainties. Now I think that this derivative can be evaluated by finding the slope of the data in log…
0
votes
1 answer

Minus from slider value in AfterEffects

I'm making a timer. When the minutes value reaches 60, it has to decrease by 60 and increment the hour. It's tracking a time lapse; the minutes is currently the time of the computation divided by 6 : each frame is 10 seconds in real life. This is…
user1715010
0
votes
1 answer

runga kutta integration with sensor data

Had a question regarding numerical integration with Runga Kutta (RK2). Suppose I have sensor data that provide me with x,y position and velocities. Based on the current vehicle state I need to find out where the vehicle will be at a certain time.…
jti107
  • 149
  • 2
  • 13
0
votes
1 answer

Matlab- 1D Numerical integration with function stored in multiple variables

as you can see in the last few lines below, I'm trying to store my function on multiple variables because it gets rather ugly. However, doing this yields the error shown below. A fix for this would be to manually substitute k and kp, but this is…
RRR
  • 69
  • 6
0
votes
1 answer

in tcl, how to convert a list arg into a numerical value

My code looks like this: proc decimalToBin { decNum numBits } { set one "1" set zero "0" set rd "" for { set jj 0 } { $jj < $numBits } { incr jj } { if { [expr {$decNum % 2}] > 0 } { set rd "$one$rd" }…
0
votes
1 answer

Changes needed to make this code book tickets in numerical order rather than random?

**I would like the code to print out in numerical order rather than a random integer as it does at present due to the fact that I now want to fill up the bookings from 1 to the upper range of 32. Any help on this would be really appreciated, thanks…
JamesAH
  • 3
  • 2
0
votes
2 answers

Sorting Alphabetically and Numerically

f = open(document) #this will open the selected class data swag = [f.readline(),f.readline(),f.readline(),f.readline(),f.readline(),f.readline()] #need to make go on for amount of line viewfile = input("Do you wish to view the results?")#This will…
0
votes
1 answer

Best Way to Add 3 Numbers (or 4, or N) in Java - Kahan Sums?

I found a completely different answer to this question, the whole original question makes no sense anymore. However, the answer way be useful, so I modify it a bit... I want to sum up three double numbers, say a, b, and c, in the most numerically…
0
votes
1 answer

Machine epsilon multiplication

I am trying to get a better understand of floating point arithmetic. I know machine epsilon (e) is define as the difference between 1 and the next largest number (i.e. the next largest number after 1 that can be accurately represented in floating…
bnorm
  • 399
  • 2
  • 16
0
votes
0 answers

Matlab: diff(interp1(...'pchip')) produces strange results?

I have the following arbitrary data: t=[0 1 2 3 4 5 6 7 8 9 10 12 14]; C=[0 1 5 8 10 8 6 4 3.0 2.2 1.5 0.6 0]; area=trapz(t,C); E=C./area; F=cumtrapz(t,E); When plotted, it looks as follows: Now, I want to smoothen the…
Mierzen
  • 566
  • 1
  • 5
  • 25
0
votes
1 answer

The distinct approximatons in the weighted average for my rk4 implementation are all the same

Okay so I'm trying to write an implementation of the 4th order runge kutta method for the numerical approximation of a differential equation just as part of my maths course but also to learn some programming but the problem is that it uses these…