Mathematica: NIntegrate data points

Click For Summary
SUMMARY

The discussion centers on normalizing a set of data points represented as (time, voltage) in Mathematica. The user seeks to find a factor C to multiply the voltage data so that the area under the curve equals 1. Niles suggests that instead of integrating, the user can simply sum the data points using the Apply[Plus, data] or Plus@@data functions. For those who still wish to integrate, constructing an interpolating function or fitting the data to a Gaussian is recommended.

PREREQUISITES
  • Familiarity with Mathematica syntax and functions
  • Understanding of Gaussian distributions and their properties
  • Knowledge of numerical integration techniques
  • Ability to construct and manipulate interpolating functions
NEXT STEPS
  • Explore the use of Apply and Plus functions in Mathematica for data manipulation
  • Learn how to create interpolating functions in Mathematica
  • Study Gaussian fitting techniques and their applications in data normalization
  • Investigate numerical integration methods available in Mathematica
USEFUL FOR

Data scientists, researchers, and engineers working with numerical data analysis in Mathematica, particularly those interested in data normalization and integration techniques.

Niles
Messages
1,834
Reaction score
0
Hi

I have a set of data points in units of (time, voltage), and they have the form of a Gaussian when I plot it. I would like to normalize my data set, i.e. find a factor C that I multiply on to the voltage-data such that the area is 1.

However, is there a way to numerically integrate data points in Mathematica?


Niles.
 
Physics news on Phys.org
Integration is probably overkill. I would just use:

Apply[Plus,data]

or equivalently:

Plus@@data

If you really want to integrate it then you need to construct an interpolating function object, specify the order of the interpolation and then integrate that. Alternatively, you could fit the data to a Gaussian and then use the integral of the fitted Gaussian.
 
Last edited:
Thanks. Yeah, I think integrating it is overkill. Your first suggestion works!Niles.
 

Similar threads

  • · Replies 4 ·
Replies
4
Views
2K
  • · Replies 5 ·
Replies
5
Views
4K
  • · Replies 13 ·
Replies
13
Views
3K
  • · Replies 18 ·
Replies
18
Views
5K
  • · Replies 11 ·
Replies
11
Views
3K
  • · Replies 58 ·
2
Replies
58
Views
7K
  • · Replies 3 ·
Replies
3
Views
2K
  • · Replies 1 ·
Replies
1
Views
2K
  • · Replies 2 ·
Replies
2
Views
5K
  • · Replies 6 ·
Replies
6
Views
1K