Questions on the use of Mathematica to construct models for approximating empirical data.

learn more… | top users | synonyms (1)

4
votes
1answer
455 views

NonlinearModelFit does not find a good fit

I am trying to fit my data to the following function, $$\frac{a b t \left(\log \left(\frac{-a d t+a t-1}{a d t}\right)-2\right)}{4 (a t-1)}-c$$ ...
1
vote
2answers
83 views

Minimizing the maximal residual in mathematica

With this: d1 = 10; d2 = 4; mat = RandomReal[{-1, 1}, {d1, d2}]; vec = RandomReal[{-1, 1}, d1]; LeastSquares[mat, vec] ...
0
votes
0answers
256 views

histogram fit for probability density

I am trying to fit the (probability density) histogram of some data with the exponential function, but I am having difficulties. My raw data are in file called ...
1
vote
2answers
164 views

FindFit giving weird values on a logistic equation

I was trying to fit a set of data onto a logistic equation, however it ended up telling me that the initial value when $t=0$ is greater than the maximum limit, thus I am led to believe that it isn't ...
0
votes
1answer
212 views

Exporting tables of interpolating functions

A few weeks ago I asked a question about manipulating parameters in NDSolve (Looping with NDSolve?) , and received some very helpful advice about the manipulate environment; now I want to take the ...
2
votes
2answers
531 views

Line of best fit on LogLog plot

I have a LogLog plot, and i'm unsure about how to fit a line to it. The data represents a calibration curve. ...
0
votes
1answer
95 views

Replicating Excel output using Mathematica

I have 2 columns of data in Excel. One is inputs the other is outputs. I ask Excel to make a graph of that data and to fit the data to a power trendline. Excel does this and it's fine as far as it ...
16
votes
5answers
1k views

Finding the intersection of a curve with an interpolation function

There are no issues trying to find the intersection points of two defined curves. ...
1
vote
2answers
213 views

Can't find a fit for Erf

I have the following numbers ...
1
vote
2answers
87 views

How can I get a fully functional FittedModel when fitting data to a pointwise function?

When I am fitting data with a pointwise function using NonlinearModelFit, the produced FittedModel fails to calculate variances ...
0
votes
0answers
43 views

Supply parameter values in NormFunction of FindFit

As I understand the input to the NormFunction is a list of residuals. Is there a way to get parameter values into the NormFunction as well? I ran into a problem where the norm depends on the values of ...
0
votes
1answer
94 views

Constraining some rows from LeastSquares to lines

For two matrices, A and B, with dimensions {n,p} and ...
0
votes
0answers
79 views

Find Numerical Derivatives (With Errors) given some data

I have a question. Suposse I have some data with their respective errors: ...
7
votes
1answer
174 views

Least Square Data Fit /Design Matrix

I am trying to learn how to use the DesignMatrix function in Mathematica and how to perform a LeastSquares fit. I am at end of ...
3
votes
2answers
169 views

Multi-Fitting with Nonlinear model

I want to fit experimental data by the H-N model. Here is the H-N model: $$\text{EHN}(T)\text{=}\text{E$\infty $}+\frac{\text{E0}-\text{E$\infty $}}{\left(1+\left(i \omega\tau(T_g)10^{-\frac{\text{C1} ...
0
votes
0answers
189 views

Non linear model fit mathematica

I want to fit experimental data (temp,alpha) to the following equation for calculating k and Ea -Log[alpha]^n = function(k,Ea,temp) However i do not know ...
-1
votes
2answers
207 views

Fitting a beta distribution to a probability density curve

If I have a spectral data set showing measured energy on the y-axis and frequency on the x-axis, how would I go about fitting this to a beta distribution? For example, lets say I had the data for the ...
-1
votes
1answer
927 views

How do I calculate RSquared in Mathematica 9? [closed]

I imported data from an Excel package and used LinearModelFit to return a FittedModel: FittedModel[6.90762 - 0.999573 x] How ...
1
vote
1answer
258 views

Fitting data using a differential equation

I have data generated from two functions given below. How can I go about finding a fit of the form: y'[x] == -(a + b/(c + d y[x] + e F[x] )) where a,b,c,d,e are ...
5
votes
3answers
263 views

Determing two Nonlinear model fits with 95% confidence bands from one data set

I have the following data which is postulated to have contributions from two different sources .....as can be seen from the confidence band, many points are out of the band. Question: How can I ...
0
votes
2answers
148 views

Any other way to get a better FindFit for my data besides good initial parameters?

I fit some data with FindFit and NonlinearModelFit with some constraints and I am not getting a good fit with my data. I read ...
1
vote
1answer
259 views

Curve fitting data to model

Example Assumptions: ...
2
votes
3answers
315 views

Estimating a distribution using binned data

I have data from which information has been irretrievably lost through binning and I am trying to find a plausible distribution from which it derives. There is an academic paper suggesting that the ...
4
votes
1answer
224 views

Fitting triangular function with HeavisideTheta

I have a problem fitting a triangular function (like potential vs. time in cyclic voltammetry) with a HeavisideTheta function. I just want to get used to ...
1
vote
1answer
168 views

How do I construct a non-linear model from experimental data?

I want to find a function $w=f(x,y,z)$ that fits experimentally determined values of w. For example, assume ...
1
vote
1answer
220 views

dynamically set fit parameters and models with FindFit

I want to fit a gaussian profile by setting some values dynamically, but FindFit returns an error and i can't see the problem. with a given gaussian: ...
0
votes
0answers
133 views

NonlinearModelFit with multiple parameters

I am now trying a slightly more complicated model which actually consists of finding the parameters of 2 particles in an Image (I attached an Plot of an image). Although I put very good initial values ...
2
votes
1answer
73 views

is there an option for FitResiduals in FindFit?

I know this option exists in NonlinearModelFit and probably in other fit models as well but for some reason the best result i get is with FindFit. Regards Doron
4
votes
1answer
211 views

FindFit not giving a good fit despite good initial parameters

I'm having a problem with FindFit not giving a good fit to my data, even though the initial parameters I give look really good when plotted. The fitting function is ...
0
votes
0answers
68 views

Fitting data set with series expansion

I have a function given in a form of a list: ScalarField={{$\epsilon$,$y_1$},..{1,$y_{3000}$}} It is defined in the range $(\epsilon,1)$ (spacing between grid points is homogeneous), where ...
0
votes
0answers
118 views

Using FindFit for step functions

Having used FindFit like so: ...
6
votes
2answers
184 views

how recover lost data of coordinates from contourplot of mention data?

I have made Contour Plot for a lot of data, like this ...
3
votes
0answers
297 views

What exactly is “ParameterErrors” of NonlinearModelFit?

I am trying to get what I call a "$\chi^2$ fit". This means taking a function $f(x,p)$ of the variable $x$ with a parameter $p$ and finding the value of $p$ that minimizes the "distance" from a data ...
0
votes
2answers
166 views

How to solve this FindFit::nrlnum:

the following code show error message FindFit::nrlnum: "The function value {6.71759 -9.36268*10^-8\ I,6.51797 -8.42641*10^-8\ I,6.31789 -7.49014*10^-8\ I,6.1179 -6.55387*10^-8\ I,5.91794 ...
3
votes
1answer
180 views

Fitting one function to another

I'd like to see how close I can fit an exponential function to a cosine function in the domain of $\;-\frac{\pi}{2}$ to $\frac{\pi}{2}$ in the least squares sense. ...
0
votes
1answer
227 views

Fitting a Function With a Numerical Integral [duplicate]

I am having trouble using FindFit with the following function. ...
6
votes
1answer
335 views

Having trouble fitting data using NonlinearModelFit

I'm trying to fit data = {{2002, 45000}, {2004, 90000}, {2005, 120000}, {2013, 211000}}; to an exponential function ...
0
votes
0answers
104 views

Smoothing a function

NDsolve gives me a solution to a certain NL PDE. I want to evaluate the rate of exponential decay of the maxima of the solutions in time. So, I plot ...
0
votes
1answer
128 views

Fitting a function

I defined and evaluated a function Max2[t_?NumericQ] := Log[Abs[-1 + First[Maximize[sol1[[2]][x, t], 0 <= x <= L, x]]]]; Now, I expect this to be close to ...
1
vote
3answers
199 views

Getting an equation of particular curve

How can I get an equation of the similar shaped curve? I've tried to get it like y = a + c x^2 + d x^3: ...
2
votes
1answer
192 views

FindMaximum of loglikelihood in Gaussian Process

I am trying to implement a Gaussian Process and have problems to maximize the loglikelihood because the function consists of a determinant of a matrix that is dependent of 2 variables and the product ...
7
votes
1answer
386 views

How does Mma compute Confidence Intervals?

I am trying to understand how Mma computes the Confidence Intervals after a NonlinearModelFit. Consider the following example: ...
6
votes
2answers
182 views

Implement planar correction for skewed 3D profilometric data

I have some data that represents small-scale surface topography. The data is planar but not flat because it's impractical to level this microscope to a tolerance of microns. It looks like this: I'd ...
4
votes
0answers
201 views

Using FindFit to fit nonlinear ODE parameters, subject to a constraint (an inverse problem) [duplicate]

Similar to this post I am finding that constraints tend to make FindFit poor at finding a good fit. However, unlike the previous post, the constraints are required ...
5
votes
2answers
420 views

Find parameters of ODEs to fit solution data

Problem How to find the initial conditions x[0],y[0] and the optimal value of parameters ...
0
votes
0answers
137 views

How could I code the following nonlinear regression? [closed]

I am an extremely limited user of Mathematica. Could someone tell me how to set the following nonlinear regression problem : Y = Sum[a[i] F[i,X] , i = 1,4] ...
3
votes
2answers
261 views

fit a curve in a three dimensional space

I have a list of points of a curve in a three dimensional space, like ...
0
votes
0answers
41 views

How to fit ODE's coefficient, just like using NMinimize [duplicate]

I want to fit ODE's coefficients to a model. I tried using NMinimize, but it seems it does symbolic instead of numerical calculations. ...
2
votes
0answers
137 views

NonlinearModelFit is not giving the fit with minimum chi^2

First of all, a bit of background, I am using Mathematica to fit angular distributions of gamma rays, so I apologize for some of the serious messiness in the formulas. The data is simple I have three ...
2
votes
1answer
165 views

Judging the quality of fitting an EventData object to a distribution using LogRankTest

I have $389$ data points defined in an EventData object and want to judge the quality of fit of this data to a fitted $3$-parameter Weibull distribution. This ...