Questions about the use of built-in Mathematica functions, including pure functions.

learn more… | top users | synonyms

0
votes
0answers
22 views

Improving RationalInterpolation Result

The following code produces a {4,4} rational interpolation approximation accurate to 10^-6 or better over the range ...
1
vote
1answer
35 views

Composition of Multivariable function

I am trying to compose functions of xleft, maybe like xleft[xleft[f]] or even higher order. And here is my function: ...
0
votes
1answer
67 views

Diffentiating a function f with respect to x [duplicate]

I have a tabe y={10,20,30,40...} and x={62,63,64,65...} y is a function f and this function needs to be interpolated. How do I defferentiate the function f with respect to x?
2
votes
1answer
228 views

How to make a function from body with variable number of arguments?

Suppose I have an UNKNOWN function, which generates formulas with given number of x[i]. ...
0
votes
1answer
38 views

Taking function output as shown, and processing it regardless of its history

I am making some symbolical calculations for my quantum chemistry class. I am supposed to build a wave function composed of multiple other functions, each of which is also composite of some lower ...
0
votes
1answer
48 views

Converting list into Double quote list [on hold]

I am trying to import a spreadsheet of stocks. I have tried to flatten it and a few other functions but noting seems to work. Can someone help me get the double quotes surrounding each stock like in ...
0
votes
0answers
46 views

How to take a coordinates of mouse position? [on hold]

There is MousePosition function, which gives a coordinates of mouse right now.But I need coordinates of a line, that been made by user in the picture. I was thinking about writing function, that gives ...
0
votes
1answer
49 views

What is the simplest way to obtain function obect of a given function?

Suppose I have a function p of some arguments: p[x_,y_]:= (* something *) Now I with to pass this function as an object to ...
1
vote
2answers
113 views

How to tell Mathematica that certain variables are real/imaginary, integer-valued, etc

I'm trying to expedite some quantum mechanical calculations by running them through Mathematica. Expectation values and stuff like that. When I say, for example, ...
0
votes
0answers
61 views

How to differentiate a function? [closed]

I have two tables ax={6371.1,6371.59,6372.06...} ay={0,10.9975,21.9958...} with: data=Transpose@{x,y} ListPlot[data] which result in the following graphic: How can I differentiate the ...
1
vote
1answer
102 views

Why does LyapunovSolve solve non-standard form?

LyapunovSolve[A,Q] solves the equation $A P + P A^T = Q$ for $P$ whereas the standard form (wikipedia,lecture notes, p.25, linear control systems) of the Lyapunov ...
6
votes
2answers
133 views

How to define a nested function like this?

For example, I want to calculate the limit of $\frac{1}{1+\frac{2}{1+\frac{3}{1+\ldots}}}$. So I want to define: $f(1)=1$ $f(2)=\frac{1}{1+2}$ $f(3)=\frac{1}{1+\frac{2}{1+3}}$ Then I calculate ...
0
votes
1answer
41 views

Mathematica Lattice Reduce Command

I'm going through a very old copy of "Mathematica: A System for Doing Mathematics by Computer" for self practice. I'm on chapter 3, and ran into the LatticeReduce ...
2
votes
2answers
105 views

cycloid parametric [closed]

How do I enter 3 parametric equations for cycloids corresponding to circles with radii 1, 2, and 4. I have tried ...
0
votes
0answers
48 views

Plotting A Function Using A Given Number Of Points [closed]

i'm new to mathematica and am trying to figure out how I can plot something and specify the number of points on the plot. I want to plot the real root of an equation from a=0..1 using 500 points of ...
-2
votes
0answers
25 views

How to define a function with more than one equation in? [closed]

How do I define the first function where there are more than one equations in it with each with an inequality? And for the second question how do I graph the periodic extension, what is it?
1
vote
0answers
53 views

Crosscorrelation for nonperiodic signals

I want to detect patterns (of an absorption spectrum which is nonperiodic) with Mathematica automaticly. I have found CorrelationFuncion but as far as I understand, ...
5
votes
3answers
125 views

Missing control for depth of Inner

Working on a mechanics problem, I stumbled on something peculiar: Since Inner is a generalisation of Dot, it changes its ...
1
vote
2answers
45 views

How to add a part of a list to a function?

I want to be able to add a specific portion of a list to a part of a function but this fucntion intakes 6 variables where as the list is of example: ...
1
vote
0answers
30 views

Why the same function defined by Set and SetDelayed look different? [duplicate]

I am novice to Mathematica and maybe my question looks kind of silly, but nevertheless here is it. I input two functions: ...
2
votes
1answer
108 views

Show how Eliminate arrives at reduction

Does anyone know how to get Mathematica to show how it arrives at the following result? ...
1
vote
1answer
67 views

Help creating a simple function

Can someone help me to create a function. The truth I'm new in Mathematica and I don't understand well the way functions work in I. I need a function that animate some rectangles according to a curve ...
3
votes
1answer
70 views

Integrate[] does not work when the function has an antiderivative function

This function (1 + (1 + 1/(2*Sqrt[x]))/(2*Sqrt[Sqrt[x] + x]))/(2*Sqrt[x + Sqrt[Sqrt[x] + x]]) has the antiderivative function, since ...
-1
votes
1answer
73 views

Putting two functions in one manipulate plot

I have a problem that is somewhat related to this http://stackoverflow.com/questions/7727668/putting-two-plots-in-a-manipulate-whilst-keeping-the-plots-visible but I would like to plot two functions ...
8
votes
1answer
114 views

How do I override options with my own defaults?

I'm calling a function f from within a function g and would like to pass any valid options for ...
1
vote
1answer
71 views

using Module in NDSolve

I am trying to solve a set of two wave equations where solution of first equation defines initial conditions for the second one. And I would like to use Module to define those equations as a function ...
1
vote
1answer
74 views

Apply functions to functions yields slow execution speed

I'm trying to write a function that parametrizes a curve c(t) by its arc length. Technicly I'm finished but if I plot the result for an example curve like ...
8
votes
1answer
116 views
+100

Enumerating tuples from a larger space such that all pairs of values are present at least once

I am trying to write a function that will accept a list of N lists and returns a list of N-tuples that represent all pairs of values from the original N lists at least once. To illustrate with an ...
1
vote
1answer
54 views

Manipulate - Evaluating Value of Function

I would like to visualize the properties of a threshold, which is a value of a function. Unfortunately, the value is expressed as scientific value (an approximation with 3-5 decimals would be fine) ...
1
vote
0answers
27 views

Apparent issue with derivative of FractionalPart

This issue came to my attention from Math.SE: http://math.stackexchange.com/questions/1015325/is-the-derivative-of-x-on-0-1-always-equal-to-1/1015342#1015342 To summarize, it appears that ...
0
votes
0answers
10 views

Formula to divide (group) numbers into N proportionally groups [migrated]

Lets take ideal theoretical case as example: we have 20 numbers: 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20 we should split these numbers into 5 groups: lowest, low, ...
1
vote
1answer
98 views

In there a way to derive the inverse value of CDF format MultinormalDistribution?

Is there a way to produce the inverse value of multinormal distribution function in CDF format with 0.05 significance level? I found the function called ...
0
votes
0answers
57 views

simulate a 32-bit signed integer overflow in a recurrence function

Considering the following recurring equation: which is this factorial function: I want to find the value of x where f(x) = 0. Actually, the solution is impossible with Mathematica, and it's ...
0
votes
0answers
32 views

Zero of a function [migrated]

let $$F(x)=-c x^{n+p} -b x^n + (a-c)x^p -b$$ where $c>0, \, \, a-c >0, \, \, 0<p<1, \, \, b>0 , n=2,3, \cdots$ Under what conditions this equation has zero solution, one solution, ...
0
votes
1answer
33 views

Error: in the part assignment is not a symbol [duplicate]

I am trying to set part of a Doubly-indexed list aInitialPopulation to cNumHeg. Specifically I am trying to set the 3rd part of the list aInitialPopulatiom[[cNodeNumber]] to cNumHeg. My (attempted) ...
6
votes
5answers
160 views

What is the shortest way to switch between heads of nested functions

consider this example: f[g[x]] what is the shortest way to switch between heads of nested functions to produce. g[f[x]]
2
votes
1answer
62 views

Using Integrate to define a function

I'd like to define a function by way of the output of a definite integral with symbolic bounds. For instance, F[m_,k_] := Integrate[x,{x,m,k}] would define ...
1
vote
0answers
40 views

RowReduce doesn't work for this matrix?

I have this matrix A={{0,1,1,w},{1,0,1,x},{-1,0,1,y},{0,1,1,z}} where w, x, y, z are arbitrary constants. This matrix should be row reduced to the form ...
12
votes
2answers
2k views

Which Mathematica function has the longest name (by character length?)

I came across DamerauLevenshteinDistance[u,v] in the documentation center so that got me thinking: Which documented Mathematica function has the longest name? ...
0
votes
0answers
38 views

Should this be equal to Gamma function or not?

I define the following function: Nat2[s_] := InverseFourierTransform[FourierTransform[1/t, t, w] (-I w)^(s - 1), w, x]/Cos[Pi (s - 1)] /. x -> 1 I expected ...
10
votes
1answer
226 views

Why does the documentation call functions “pure”?

Clearly, functions in mathematica are not pure functions according to the definition on Wikipedia (no side effects - basically implementabe with table lookups): ...
1
vote
1answer
171 views

How can I call the R-programming packages in my Mathematica?

I am trying to call the R-programming package called highfrequency in my Mathematica so that I can use its function rCov. I ...
1
vote
1answer
85 views

handling division by zeros and line equations

today I was writing a code which takes some line equation and a circle equation,finds intersection points that are on $II$ and $III$ quadrants,draw a tangent line to circle from that point and then ...
0
votes
0answers
56 views

Empty Graph for Absolute Function

I wanted to plot the following equation: Plot[((x/7)^2 Sqrt[(Abs[Abs[x] - 3]/(Abs[x] - 3))] + (y/ 3)^2 Sqrt[(Abs[y + 3 Sqrt[33]/7])/(y + 3 Sqrt[33]/7)] - 1) (Abs[x/2] - ((3 ...
1
vote
1answer
41 views

Multiway Systems Rules List Management

I'm working with a multiway system and I have a number of different mutation rule lists. I need an efficient way of managing which rule lists I apply. Here is the basic multiway system code that I'm ...
1
vote
1answer
67 views

Plotting a function in {X(Y),Y} space

The code below generates some data and defines a function f[x,cb]:=NMaximize[expr,x] that upon being evaluated returns: {function value at max $x$,the function maximizing $x$}. ...
7
votes
2answers
179 views

How to redefine the type of multiplication in Det

I would like to redefine the type of multiplication that is used in Det (calculates the determinant). Instead of the standard multiplication I would like to use a custom function Fun[a,b] (which takes ...
14
votes
1answer
237 views

Why do big-O terms disappear in definite integrals since Mathematica 9?

In Mathematica 8, when I computed the following input: Integrate[Series[Cos[x], {x, 0, 2}], {x, 0, a}] Mathematica returned an expression that had a O[a^4] in ...
2
votes
0answers
47 views

FinancialDerivative function call without parameter fails in Mathematica 10

When I type FinancialDerivative[] in Mathematica 10. There is error listed as follows. Anybody know how to solve it? Thanks.
1
vote
1answer
60 views

User defined functions and decimal places displayed

I have a couple of complicated user-defined functions, one which calls the other, and I wish to control the number of decimal places displayed when I call the "mother" function. I have tried the ...