Linked Questions

39
votes
6answers
5k views

How to splice together several instances of InterpolatingFunction?

I have a set of InterpolatingFunction returned by NDSolve which are valid over different (but overall continuous) domains. How ...
36
votes
4answers
2k views

How to implement the sample-point process like the built-ins of Mathematica?

Consider this: pts = {{0, 0}, {1, 1}, {2, -1}, {3, 0}, {4, -2}, {5, 1}}; f = BSplineFunction[pts] I can use ParametricPlot to ...
32
votes
2answers
2k views

How does Plot work?

I considered the following function: sin[x_] := Module[{}, Print["x=", x]; Sin[x] ] in Mathematica. Next, I tried to plot it using: ...
50
votes
1answer
3k views

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

I'm curious what's inside the InterpolationFunction object? For example: ...
27
votes
3answers
867 views

How can I make Plot show the plot while it's computing it?

Normally, Plot acts like a black box and only gives you the requested plot once it has finished computing it. However it can be useful, other than interesting, to ...
8
votes
4answers
1k views

Transform an InterpolatingFunction

I'd like to transform an InterpolatingFunction from NDSolve but can't figure out how. Here's an example. The equation I want to solve is ...
10
votes
2answers
840 views

Interpolating an Antiderivative

I'd like to be able to make InterpolatingFunctions for antiderivatives of functions that can't be integrated symbolically. However, the following code returns ...
5
votes
1answer
668 views

How to sample a function as Plot* functions do?

Suppose we have a hard to calculate function f. We plot it like e.g. ...
3
votes
0answers
1k views

Why is my Plot3D not smooth? [closed]

Unless I'm missing something very obvious, why does this code: Plot3D[r^(-2) + 1000*r^2 + 10*Cos[x],{r,0.01,0.5},{x,0,20*Pi},PlotRange->{0,200}] generate this ...
1
vote
1answer
405 views

Interpolating a function of many variables

I am trying to interpolate a function of $5$ variables $$f[m,M,k,v,w]$$ by creating a 5D table of $n$ values in each dimension. ...
2
votes
1answer
218 views

Interpolating functions and Look-up tables

This is just a general question about how InterpolatingFunctions work: If I have a complicated function that I don't want to have to evaluate many times over, does turning it into an ...
2
votes
1answer
129 views

2D plot using output from the other function

I would like to get 2D plot using output from the other function. FindInstance[0.5*x^2 + Cos[y + P] == 1, {x, y}, Reals] By changing values of P manually it gives ...
1
vote
2answers
50 views

Evaluate function at “good” points used by Plot in numerical problems

Plot function with option Mesh->All shows how mathematica evaluates function to make it most optimal for plotting. I'd like to evaluate some physical function in ...
0
votes
3answers
62 views

AbsoluteOptions not working with PlotPoints?

AbsoluteOptions does not work well with PlotPoints, for example: ...