Tag Info

3

To create convex function we can use InterpolatingPolynomial as follows mypts = {{0, 0, 2}, {0, 1, 1}, {0, 2, 2}, {1, 0, 1}, {1, 1, 0}, {1, 2, 1}, {2, 0, 2}, {2, 1, 1}, {2, 2, 2}}; g = Interpolation[mypts, InterpolationOrder -> 2]; {zc = Table[g[x, y], {x, 0, 2, .4}, {y, 0, 2, .4}], xc = Table[x, {x, 0, 2, .4}], yc = Table[y, {y, 0, 2, .4}]}; ...

2

Clear["Global`*"] j = {{0, 0.205004}, {0.1, 0.259237}, {0.2, 1.059125}, {0.3, 0.832184}, {0.4, 0.587992}, {0.5, 0.565537}, {0.6, 0.527323}}; f = Interpolation[j, InterpolationOrder -> 3, Method -> "Spline"]; The function range is {fmin, fmax} = (#[{f[x], 0 <= x <= 0.6}, x] & /@ {MinValue, MaxValue}) (* {-0....

1

Look at your function: Plot[f[x], {x, 0, 0.52}] As you can see, for some y values there are several x values. This makes the inverse function multivalued. And MMA seems to take randomly one of several values as you can see: Plot[InverseFunction[f][x], {x, 0, 1}] Therefore, using InverseFunction is not a good idea. Instead try e.g. FindInstance with ...

1

First,with only 3 points you can only use "InterpolationOrder->1". Toward this aim I create new "intensity" data and function "f" like (note the point at the north pole is double, what will not harm): dat = Flatten[Table[{{th, ph}, th ph}, {th, 0, Pi/2}, {ph, 0, Pi/2}], 1]; f = Interpolation[dat, InterpolationOrder -> 1]...

Only top voted, non community-wiki answers of a minimum length are eligible