Skip to main content

Questions tagged [operators]

Questions about using or composing operators--functional mappings from one state or vector space to another.

Filter by
Sorted by
Tagged with
0 votes
1 answer
68 views

How to define a composition of operators?

If I define P[x]=D[#,x]& (derivative operator) How can I define another operator $Q$ such that $Q(f(x))=Pf(x)+a$ (for example)? Thanks.
eraldcoil's user avatar
  • 203
0 votes
1 answer
44 views

Symbolic calculations with operator ordering

Given the following set of equations: ...
Jee's user avatar
  • 386
0 votes
0 answers
34 views

Taking sums of differential operators

If I define a differential operator: T[i_] := D[#, x[i]] & I am able to apply it multiple times to a function without any issues: ...
Antoine Vauterin's user avatar
3 votes
3 answers
204 views

Finite Differences:

I am having difficulty implementing finite differences in the correct columns of my code. ...
Rubens Vilhena Fonseca's user avatar
2 votes
1 answer
84 views

Defining custom operators for indexed objects [closed]

I have some symbolic indexed objects $A_i$, $B_{ij}$, $C_{ijk}$, $D_{ijkl}$, etc. I want to define a symbolic differential operator $\partial_{xy}$ that acts on these indexed objects in the following ...
Franz5217's user avatar
7 votes
6 answers
465 views

Applying several functions to the same argument

Is there a more concise way of achieving the following result (possibly without d |->)? ...
azerbajdzan's user avatar
  • 18.9k
2 votes
0 answers
78 views

How to define the square root of an operator [duplicate]

How can I define the operator $\sqrt{m^2-\frac{\partial^2}{\partial x^2}}$, such that it acts on the function $\psi(x)$ as follows: \begin{eqnarray*} \sqrt{m^2-\frac{\partial^2}{\partial x^2}}\...
Yu-Sen Zhou's user avatar
3 votes
3 answers
269 views

Apply central difference formula to a variable twice

I am working with finite difference methods analytically and I would like to be able to perform operations on subscripted variables. I would like to generate the following expression by applying a ...
Hefaestion's user avatar
4 votes
3 answers
270 views

How can I construct a determinant-type differential operator?

How can I construct a determinant-type differential operator, where the multiplication of elements in the determinant represents the composition of multiple differential operators? \begin{align*} \...
D.Matthew's user avatar
  • 217
0 votes
1 answer
54 views

Nested RowBox in MakeExpression reports error when I define my own curl operator, but the single RowBox in MakeExpression works well

I want to define my own vector notation so that the input \[Del] \[Cross] a outputs curl[a] while the ...
ymma's user avatar
  • 1
1 vote
1 answer
156 views

Doing algebra with differential operators

I'm doing some work on stochastic processes, where I use random functions which are defined by their properties over averages, i.e $$\langle f(t) \rangle =0 \\ \langle f(t) f(t')\rangle = \alpha(x,y) ...
J Pin's user avatar
  • 11
0 votes
1 answer
87 views

Could Mathematica analytically work with operators (such as $\nabla$) and vectors?

I have the following expression: $$(\nabla+\vec{P})^2$$ where $P=(r\cos\theta sin\phi,r^4\sin\theta,r\cos^3\phi)$ I would like to open the brackets and simplify the expression. Are there in ...
Mam Mam's user avatar
  • 1,863
1 vote
3 answers
122 views

Is it possible to prevent two functions from commuting?

I have an expression of the following type: x f[a] g[b] where x is a number but f[a] and <...
Pxx's user avatar
  • 711
8 votes
7 answers
2k views

Can I use == to compare two list element wise?

I have the following lists Y and EY with actual and estimated outcomes. ...
M.E.'s user avatar
  • 333
2 votes
1 answer
108 views

How to define an operator like ⊕?

For example, I define the circle plus as a_\[CirclePlus]b_ := a + b^2; a__\[CirclePlus]b_ := (a[[1 ;;-2]]\[CirclePlus]a[[-1]])\[CirclePlus]b; But when I try ...
Curious Cat's user avatar
1 vote
1 answer
51 views

How can I define an operator and plot its iterates?

I am trying to define a function (an operator) that "integrates then translates" a function. More specifically, for an input f[x], I want to integrate it as \int_0^x f[t] dt, then translate ...
user122916's user avatar
1 vote
0 answers
241 views

How to define momentum operator for use with creation and annihilation operators in quantum mechanics

I am having trouble writing the momentum operator in the differential form to complete a piece of code shown here so that I can show a commutator [P,Q] = I . Here is what I have done so far, and I ...
cows's user avatar
  • 165
1 vote
2 answers
155 views

Replace with non-commutative product

I'm trying to evaluate some scattering amplitudes terms in Mathematica using the spinor helicity formalism. For that, I need to turn products like $\epsilon_i\cdot k_j$ into spinor product which can ...
Marcosko's user avatar
  • 259
11 votes
2 answers
210 views

How to make a function with two patterns listable?

Suppose that I have a function that has two patterns: disksConstantRadius[radius_][points_] := Disk[#, radius] & /@ points (noting that this would be better---...
Craig Carter's user avatar
  • 4,510
1 vote
0 answers
110 views

How to define a vector operator?

I know how to define a single-variable differential operator like Clear[Op] Op[x_] := a D[#, {x, 1}] & and I can do operations like ...
z.v.'s user avatar
  • 189
7 votes
1 answer
285 views

What does the operation Map[({...}=#;{...})&, ] do?

With reference to the answer by @Bill to the question posted here, I am trying to understand the following three lines ...
seeker's user avatar
  • 539
2 votes
1 answer
295 views

What's wrong with or? [closed]

Consider Clear[x]; x = 2; x < 2.9 || x > 3.1 This yields True So, everything is o. k. (interesting) But when you replace ...
user7427029's user avatar
1 vote
1 answer
113 views

How do I make an operator that acts on a function with the function's argument explicitly given?

I am trying to make a finite difference operator such that it would behave similar to the partial derivative $\partial_{x}f[x]$. $\delta_n[f[n],m] := \frac{f[n+m]-f[n]}{m}\ .$ I couldn't find a way to ...
Questioneer's user avatar
1 vote
1 answer
60 views

Using Through function with vectors

I have the vectors defined as follows: v1={x1,y1,z1}; v2={x2,y2,z2}; v12=v2-v1; v21=v1-v2; I am passing an integer function for iteration purpose as follows: ...
Aschoolar's user avatar
  • 883
2 votes
1 answer
126 views

How to give a property to a list of functions?

For example, I have defined a bunch of binary functions Sum1, Sum2, Prod1, ...
Yifeng Huang's user avatar
2 votes
1 answer
86 views

Visualizing order of operations

TreeForm[HoldForm[ (9-2^2+10 8)/9]] produces this: Is there a way to use Divide instead of ...
Geremia's user avatar
  • 478
2 votes
2 answers
112 views

Product of different differential operators

I need to define a multivariable differential equation of the type $$ \mathcal{D}=\Theta_1^2-z_1(-\Theta_1+\Theta_2+\Theta_3+\Theta_4)(1+\Theta_1+\Theta_2+\Theta_3+\Theta_4)\\ \;\;\;\;\;\;\;\;\;\;\;\;\...
Forum's user avatar
  • 21
0 votes
1 answer
31 views

Confusing abnormalities observed when counting a specific operator in an expression [duplicate]

Recently I have met with some confusing abnormalities when trying to determine if there is a specific operator (usually Plus[] ) in an expression by programming. ...
AlbertLew's user avatar
  • 483
2 votes
1 answer
85 views

How to convert an expression of several variables into an operator

Given the expression How can I define the following operator like g[u_, v_] := eq1 The correct definition is
Jose Nuñez's user avatar
3 votes
2 answers
163 views

How to subtract a list from certain sublists of a list? [closed]

I have a problem in doing an operation on this vector {{2,3},{3,4},{5,6}}-{1,1} I want to minus this to get the result ...
Ahmed's user avatar
  • 369
0 votes
1 answer
138 views

Second order differential operator in Mathematica

I am trying to write the code for the following expression in Mathematica: $$\partial_{x} e^{-g x}=-g e^{-g x}+e^{-g x} \partial_{x}\,.$$ I was able to do so with the help of the following links with ...
Sam's user avatar
  • 3
0 votes
0 answers
57 views

How to write the expression for first order differential operator in Mathematica?

How to write the expression for first order differential operator in Mathematica? What I mean to say that I want to evaluate $$\frac{\partial}{\partial x}f(x)=f'(x)+f(x)\frac{\partial}{\partial x}.$$ ...
Sam's user avatar
  • 3
3 votes
1 answer
98 views

Define an operator for long equations

I'm trying to workout a long expression with derivations, the thing is I can't seem to transfer this problem to code. What I need is a operator $D = l^\mu \frac{\partial}{\partial x^\mu} $ where $l^\...
Nitaa a's user avatar
  • 770
7 votes
1 answer
464 views

What operator is this?

I was looking at some sample code in a YouTube video and saw an "operator" (not sure this is the right term) consisting of a horizontal bar with circles on the ends. I searched through the ...
Robert McCormick's user avatar
0 votes
2 answers
70 views

How to define specify parameter functions of a Sturm-Liouville operator & plot its effect on specific functions?

I have a Sturm-Liouville operator: $$\mathcal{Ly(x)}=-\frac{\mathrm{d}}{\mathrm{d}x}\left(p(x)\frac{\mathrm{d}}{\mathrm{d}x}y(x)\right)-q(x)y(x)$$ but I do not yet know the parameter functions $p(x)$ ...
zabop's user avatar
  • 137
0 votes
0 answers
61 views

Is there a concise way to generate a continuous less-than relationship?

Actually, I have a ton of variables, Let me simplify it to 4 in this post. vars = {a, b, c, d}; 0 < Less @@ vars < 10 0 < (a < b < c < d) < ...
yode's user avatar
  • 26.8k
0 votes
2 answers
131 views

How can I remove the attributes "Orderless" from function Times stably and reliably?

Recently I have been doing some algebra of partitioned matrices, where product like below is common: where $A_{11}, A_{12}, X, Y$ are all partitioned matrix blocks thus all are matrices in essence. ...
AlbertLew's user avatar
  • 483
3 votes
1 answer
91 views

A possible issue in combination of the Infix operator ~ with Sequence [closed]

There are other similar questions on this site about using the Infix operator for more than two arguments, which I have read. But there is one thing that I wasn't able to understand and couldn't ...
polfosol's user avatar
  • 952
1 vote
0 answers
116 views

Use self-defined operator symbol simplify formula

Mathematica is very useful and powerful in symbol compute, but some output isn’t concise if we didn’t simplify. Can i predefined some operator? eg. Lie bracket. Here is a minimum example. Suppose ...
lumw's user avatar
  • 593
0 votes
1 answer
65 views

Defining Numerical Integral Functional [closed]

In some sense the question is a combination of defining an operator and defining numerical integration with parameters. For example, I want to define $I[f] = \int_0^1 f(x)dx$. and tried ...
Fan Zheng's user avatar
  • 101
1 vote
2 answers
81 views

System of rules transformingn a multivariate polynomial onto corresponding partial derivative operator

I take a complex multivariate polynomial, and I want to transform it into the corresponding differential operator. I.e., I am looking for the set of rules transforming variables to derivation, ...
Slepecky Mamut's user avatar
1 vote
1 answer
671 views

Simplifying quantum operators (ladder operators with multiple modes)

Similar to this question, I am interested in working with an implementation of quantum ladder operators. I've been trying to use this "Quantum Mathematica Package" to solve some lengthy ...
Steven Sagona's user avatar
3 votes
0 answers
203 views

Commutator of QFT Operators $[\hat{a}_p, \hat{a}^\dagger_k]$ and 4-Momentum Integrals

I just recently started looking into CAS (i.e. i have very little experience in Mathematica), specifically for doing basic calculations in Quantum Field Theory. For that i would like to define $\hat{a}...
fN ktn's user avatar
  • 131
0 votes
2 answers
215 views

How to create an operator which is a composition of a sequence of operators?

Suppose I have a sequence of operators $\partial_x$, $\partial_x^2$,..., $\partial_x^n$. I want to define an operator which is a composition of these $D_x^{(n)}=\partial_x\circ\partial_x^2\circ\cdot\...
vichitravir's user avatar
7 votes
1 answer
196 views

Applying Operators inside complex expressions to argument with Through

I am developing some functions to help me work with Quantum Mechanics Momentum Operators. Here, for simplicity, I represent them with these simple functions because the actions of the operators ...
Jorge's user avatar
  • 83
1 vote
2 answers
165 views

How to make a change of variable $y=x^2$ in the differential operator $\frac{d^2}{d y^2}$?

I have this differential operator $$\frac{d^2}{d y^2}\qquad (1)$$ I want to make a change of variable $y=x^2$ in $(1)$ so that I get this differential operator $$ \frac{1}{4 x^2} \frac{d^2 }{d x^...
Phys96's user avatar
  • 361
0 votes
1 answer
65 views

Evaluating a scalar product of a vector and a differential operator vector

I created a scalar product of a vector $\in \mathbb{R}^2$ and of a vector consisting of a differential operators ...
Uwe.Schneider's user avatar
3 votes
4 answers
394 views

Coordinate transformation can this be done with AffineTransform?

Looking for alternatives or improvements for accomplishing the following: Given the position of points A, B, and C in both the x-y and u-v planes, determine transformation functions to map values ...
user6546's user avatar
  • 1,069
1 vote
0 answers
50 views

Performing operator expression on a function

What I want. I write an operator expression, and Mathematica performs it on a function. Examples: E^(b D): f[x] -> f[x+b] ...
Anixx's user avatar
  • 3,585
5 votes
2 answers
434 views

Dealing with infinite matrices in Mathematica?

Is there a mechanism of dealing with infinite matrices in Mathematica, and in particular, with linear operators, corresponding to those matrices? For instance, automatic simplification of operator ...
Anixx's user avatar
  • 3,585

1
2 3 4 5 6