For questions regarding the underlying implementation of built-in functions.

learn more… | top users | synonyms

9
votes
1answer
269 views

What are the hidden specifications for FindRoot

The Help page of FindRoot says: "by default, FindRoot uses Newton's method (Newton-Raphson) to solve a nonlinear system" (or a nonlinear equation I suppose)...
12
votes
1answer
715 views

What type of solver does Mathematica use in LinearSolve

I have a question regarding linear equation solvers. For a specific 9-diagonal matrix, every method I tried in C++ (Gaus, GCC, BICGTAB) didn't work (even though they worked for other matrices). But in ...
6
votes
2answers
142 views

Algorithm in RandomChoice[{w1,w2,…}->{e1,e2,…},n]?

I wonder if someone happens to know the actual algorithm implemented in the particular overload of RandomChoice that handles explicitly presented discrete ...
9
votes
1answer
137 views

Why does $Failed have attribute HoldAll?

Why does $Failed have attribute HoldAll? Are there typical situations where $Failed is ...
21
votes
1answer
756 views

How to determine BLAS/LAPACK implementation used internally for numerical matrix operations?

Is there a command which reveals which implementation of BLAS and LAPACK are used in Mathematica's matrix operations such as Eigensystem? I asked a related question ...
10
votes
1answer
335 views

How does LocationTest choose its “AutomaticTest”?

Is there a way of determining how LocationTest chooses its "AutomaticTest"? Sometimes it's clear from the ...
3
votes
1answer
812 views

Specific Mathematica algorithms, for example LU Decomposition

Where I can find detailed information on algorithms used by Mathematica, especially for numerical methods. The Manual doesn't seem to iclude specifics in most cases. For example I get a different LU ...
1
vote
0answers
38 views

Internals of Prime function [duplicate]

Does anyone knows how exactly Prime works ? For example how Prime[1000000000] is calculated ? The only information I found was ...
2
votes
0answers
103 views

What are the limits of the Prime-functions? [duplicate]

Will Prime and PrimePi test up to 3 * 10^12? Where can I find the limits for these funtions? ...
13
votes
1answer
411 views

What is the default ColorFunction for Image3D?

What is the default ColorFunction for Image3D? I find it a bit confusing that the most intense colour is not shown where the ...
16
votes
1answer
2k views

What are the algorithm details of FindRoot?

The Help page of FindRoot says: "by default, FindRoot uses Newton's method (Newton-Raphson) to solve a nonlinear system". But I ...
10
votes
1answer
1k 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: ...
1
vote
1answer
700 views

FindMinimum [] methods [closed]

Which algorithm is used when we do not use the option Method of FindMinimum[] function. FindMinimum[f,{x,x0}]
4
votes
1answer
2k views

How does Mathematica estimate error on fit parameters?

When performing a fit using NonlinearModelFit (or any of Mathematica fitting functions, but I am particularly interested in nonlinear models), Mathematica makes a ...
3
votes
2answers
393 views

How does Accumulate work?

Accumulate can be used to compute the partial sums of a list. The partial sums can also be computed using a For loop but this ...
4
votes
0answers
89 views

JewishNewYear date limitation

The documentation for the function "JewishNewYear" in the "calendar" package declares that the year argument must be between 1900 and 2100. No explanation is given for this limitation. The function ...
7
votes
0answers
173 views

Finding hidden treasure (aka finding undocumented functions) [duplicate]

I was searching for a way to determine if a point is within a polygon and stumbled upon rm -rf's answer. (actually, I really wanted to find a point within a ...
21
votes
2answers
949 views

Blend code for built-in ColorData schemes

Hi I want to get a blend similar to "SunsetColors". To make those slight modifications, I would like to know the precise blend of that color scheme. My try: <...
20
votes
1answer
502 views

Underlying Algorithms for List Manipulation Functions

Does anyone know, or know of a link for the underlying algorithms used for list manipulation functions? Specifically: Union with and without the ...
14
votes
1answer
442 views

What is the real default CellEvaluationFunction?

The default CellEvaluationFunction is Identity but one can quickly see that this is handled specially as an equivalent function, ...
1
vote
0answers
2k views

How to Output Chi-Squared Statistics when using NonLinearModelFit

I am using NonLinearModelFit for some curve fitting and I was wondering if NLM is able to output chi-squared/leastsquared statistics from the best-fit parameters and confidence intervals. From my ...
24
votes
1answer
514 views

Why does list assignment with a packed array result in unpacked values?

Bug introduced in 5.2 or earlier and fixed in 10.1.0 This is another question on the design choices in Mathematica. I understand that without direct reply from the developers it may not be ...
2
votes
1answer
504 views

Problem with Covariance Matrix Output in NonlinearModelFit

I am running NonlinearModelFit based off of some simulated data and trying to fit to a function with more than one parameter. Eventually, I would like to fit to 5 ...
44
votes
1answer
1k views

What's inside InterpolatingFunction[{{1., 4.}}, <>]?

I'm curious what's inside the InterpolationFunction object? For example: ...
1
vote
2answers
813 views

How does ListPlot3D interpolate data?

I have data of the form {{x1, y1, f(x1, y1}, {x2, y2, f(x2, y2)}, ...}. I need to interpolate the data to get an interpolated ...
3
votes
1answer
334 views

Daubechies scaling function

In Mathematica in wavelet package with the following codes Phi[x_, j_, k_] := 2^(j/2) WaveletPhi[DaubechiesWavelet[3], 2^(j) x - k] Mathematica computes ...
8
votes
1answer
740 views

How does Mathematica's LowpassFilter work?

I don't really understand the documentation for the LowpassFilter[] function in Mathematica. In the course I have about signal processing, low-pass filters come in ...
4
votes
1answer
531 views

How does Mathematica calculate the nth prime?

When I enter Prime[2000000000000], the two-trillionth prime, Mathematica gives 61427839512211 for the answer after several ...
9
votes
3answers
726 views

The default bandwidth of the SmoothKernelDistribution function

I am researching the Silverman rule of thumb for bandwidth selection. Below is a sample of my code, from which it seems that BW=63 is close to the default parameter given by Mathematica (2 images are ...
7
votes
2answers
301 views

What is the underlying algorithm for GroupElementToWord?

What algorithm is Mathematica 9 using for GroupElementToWord[group, g]?
1
vote
0answers
90 views

What algorithm is Mathematica using for FirstPassageTimeDistribution[]?

What algorithm is Mathematica 9 using for FirstPassageTimeDistribution[]? Is it attempting to use PseudoInverse[] on the ...
2
votes
1answer
490 views

How does FindShortestTour work?

How are FindShortestTour and the algorithms therewithin implemented internally? Also: Can I access some form of incremental, in-progress result during evaluation? (...
9
votes
1answer
155 views

Apart may use Padé method: what's that?

How does Apart work? The page tutorial/SomeNotesOnInternalImplementation#7441 says, "Apart ...
2
votes
1answer
660 views

Method used by FindFit

Using FindFit, Mathematica selects an optimal algorithm when Automatic is selected. I'd like to know the name of the method ...
6
votes
0answers
114 views

Design considerations behind `O` (a.k.a. BigOh, a.k.a. Landau Order)

This works without any warnings: O[Log[x]]. This raises a warning: O[x^2]. I have a few questions around this: Why is it a ...
7
votes
1answer
3k views

Methods for NonlinearModelFit

I am using NonlinearModelFit for a thesis project. I get quite different results if I change the Method to LevenbergMarquardt or QuasiNewton or ConjugateGradient ...
22
votes
3answers
417 views

Efficiently appending points to a NearestFunction

I have a program which works with a list of points (in 3D, but it could be in 1D as well, it won't make a difference). Within a loop, it keeps adding new points to the list. To calculate the ...
7
votes
1answer
356 views

What algorithm is Mathematica 9 using for “SpectralEmbedding” of graphs?

When I specify that a graph should be realized using the "SpectralEmbedding" procedure, what paper / algorithm for spectral embedding is this based on? I was unable to find any documentation for this....
2
votes
1answer
161 views

Implementation of Decompose

I'm curious as to how Decompose works so I decided to use Trace with the option ...
9
votes
1answer
310 views

What algorithm does Plot use to determine abscissas?

(I'm hoping this question is not hopelessly naive...) My understanding is that Plot's strategy is to generate a list of abscissas, evaluate the argument expression ...
10
votes
2answers
499 views

How to interpret the FullForm of a SparseArray?

SparseArrays are atomic objects, but they do have a FullForm which reveals information about them. What is the meaning of the ...
5
votes
3answers
298 views

How could I implement the equivalent of NextPrime

I would like to know what an implementation of the function NextPrime would look like if it were implemented in Mathematica's core language.
22
votes
2answers
520 views

How to implement FittedModel like objects

In the course of making some RLink wrappers I want to have some richer containers like Mathematica does with its FittedModel ...
15
votes
2answers
496 views

Why does iterating Prime in reverse order require much more time?

Say I would like to display the $10$ greatest primes that are less than $10^5$. I could do the following: ...
6
votes
2answers
566 views

Any ideas on how GeneralMiniMaxApproximation is implemented?

GeneralMiniMaxApproximation is used to construct minimax approximations of parametrically defined functions. I am curious about how ...
30
votes
1answer
794 views

What calendar is Mathematica using for dates in the distant past?

It appears that Mathematica treats all dates as proleptic Gregorian dates by default, a hypothesis that can be easily tested by using AbsoluteTime to compute the ...
22
votes
2answers
984 views

How to retrieve the parameters calculated and used by ImageAdjust?

When ImageAdjust is called with an image, i.e. with one parameter, it returns an automatically adjusted Image. I would like to ...
11
votes
1answer
200 views

Algorithm used by IsomorphicGraphQ

I'd like to know which algorithm is used to test if two graphs are isomorphic?
2
votes
0answers
172 views

PowersRepresentations Algorithm

I'm trying to understand the mathematics behind counting the number of representations of a positive integer by $n$ distinct $k$th powers, i.e. I would really like to know how to do the Mathematica ...
9
votes
0answers
704 views

Does Mathematica use the Elliptic Curve Method (ECM) in FactorInteger[]?

I'm not a mathematician, and I'm not even going to pretend that I understand anything of the ECM. But I know it can be a fast method for factorization. I benchmarked the factorization of $$...