How to work with expanded functions?

In summary, when working with functions which are expanded up to some order, it is important to remember to only expand to terms that are independent of the ##\mathcal{O}## variable. Doing so will make the problem easier to solve.
  • #1
Vrbic
407
18
TL;DR Summary
How to grab a bit complex problem, which is limited upto some order in some variable, i.e., initial function are expanded upto this order?
I solve problem where I use functions which are expanded upto some order. I multiply them, make square root and make derivatives or solve differential equations. What is the right way to deal with such problem?
Shall I expand all functions after every step or work with unexpanded functions and do it at the end? How manage a numerical solution of differential equations? Is there any recipe?

Thank you for all comments and responses.
 
Physics news on Phys.org
  • #2
Vrbic said:
Summary:: How to grab a bit complex problem, which is limited upto some order in some variable, i.e., initial function are expanded upto this order?

I solve problem where I use functions which are expanded upto some order. I multiply them, make square root and make derivatives or solve differential equations. What is the right way to deal with such problem?
Shall I expand all functions after every step or work with unexpanded functions and do it at the end? How manage a numerical solution of differential equations? Is there any recipe?
Your question is unclear. Are you asking about replacing functions by, say, a polynomial? For example, replacing ##\sin(x)## by a polynomial of degree 3, as in ##\sin(x) \approx x - \frac{x^3}{3!}##?
 
  • #3
Mark44 said:
Your question is unclear. Are you asking about replacing functions by, say, a polynomial? For example, replacing ##\sin(x)## by a polynomial of degree 3, as in ##\sin(x) \approx x - \frac{x^3}{3!}##?
I solve a problem from physics. The problem is more complex and therefore the description of the problem is only an approximation to the given order. Thus, functions describing the initial state are, say, in the form ## f (x) \approx x - \frac{x ^ 3}{3!} ##. I continue to work with those functions. I am looking for equations of motion etc. and I multiply them, differentiate them, etc. In these operations, higher order terms begin to appear. My question is how to work with these higher order terms during the calculation? Finally, I integrate numerically equations of motion.
 
  • #4
Vrbic said:
I solve problem where I use functions which are expanded upto some order
So they look like e.g.
$$f(x) = ax^4+bx^3+cx^2+d+{\mathcal O}(x^5) \ \ ?$$ Are you aware what this means, formally ?
 
  • #5
The problem is not to expand at the end of after every step, if you do it right you will get the same answer, the problem is to know to what order you should expand because maybe you start with a function ##f(x)## that is exact to second order, but your final answer is exact only to first order.

My advice is to write your approximate function as ##f(x)+\mathcal{O}##, and do all the manipulations taking into account the ##\mathcal{O}##, you can expand whenever you want to simplify your life. But anytime you expand, you need to expand only to those terms that are independent on ##\mathcal{O}##.
 
  • #6
Gaussian97 said:
The problem is not to expand at the end of after every step, if you do it right you will get the same answer, the problem is to know to what order you should expand because maybe you start with a function ##f(x)## that is exact to second order, but your final answer is exact only to first order.

My advice is to write your approximate function as ##f(x)+\mathcal{O}##, and do all the manipulations taking into account the ##\mathcal{O}##, you can expand whenever you want to simplify your life. But anytime you expand, you need to expand only to those terms that are independent on ##\mathcal{O}##.
I uderstand, but let's say, I have a matrix of functions upto second order:

##f_{ab}=f0_{ab}+f1_{ab}+f2_{ab},##
where ##a,b## is postition in matrix and number ##0,1,2## describes order. And I need inverse matrix and to work with it. Matrix is not diagonal, i.e., inversion is not trivial 1/... . In inversion matrix is something like that

##f_{11}=f0_{11}*f0_{44}+...+f1_{11}*f2_{44}+f2_{11}*f2_{44}+...##. Last two terms are higher order then the problem.
And I have to work with this further and finally numerically integrate. Expansion after every step gives different result than I let it be till last step and than expand.
 
  • #7
BvU said:
So they look like e.g.
$$f(x) = ax^4+bx^3+cx^2+d+{\mathcal O}(x^5) \ \ ?$$ Are you aware what this means, formally ?
Yes, I do. I wrote more to the problem below.
 
  • #8
Let's put an example on a 2x2 matrix
$$\begin{pmatrix}
f_{11}(x) & f_{12}(x) \\
f_{21}(x) & f_{22}(x) \\
\end{pmatrix}$$
Then, if you want the function ##(f^{-1})_{11}## you need to compute
$$(f^{-1})_{11} = \frac{f_{22}(x)}{f_{11}(x)f_{22}(x)-f_{12}(x)f_{21}(x)}$$
If all the functions ##f_{ij}(x)## are exact to order ##x^2## then ##f^{-1}_{ij}## will be exact to, at least, order ##x^2##

For example, in a 3x3 matrix, you would be
$$(f^{-1})_{11} = \frac{f_{22}f_{33}-f_{23}f_{32}}{f_{11}f_{22}f_{33}-f_{11}f_{23}f_{32}-f_{12}f_{21}f_{33}+f_{12}f_{23}f_{31}+f_{13}f_{21}f_{32}-f_{13}f_{22}f_{31}}$$

In general, you can always work the inverse in your matrix using multiplication, division and sum.

This, of course, becomes more painful when you work with higher matrices, and maybe there's some better way to do it, I'm not a mathematician and I don't usually work with this kind of problems.

For the numerical integration, I don't know, but naively, if you are integrating a second-order approximation in an interval ##[a,b]##, the error may be of the order of ##(b-a)^3##.
 

Related to How to work with expanded functions?

1. What are expanded functions in science?

Expanded functions in science refer to the use of advanced techniques, tools, and methods to conduct experiments, analyze data, and draw conclusions. These functions often require specialized training and equipment, and are used to push the boundaries of scientific research.

2. How can I learn to work with expanded functions?

To learn how to work with expanded functions, it is important to have a strong foundation in basic scientific principles and techniques. You can also attend workshops, seminars, or training programs specifically designed to teach expanded functions. Additionally, working with experienced scientists and practicing on your own can also help you develop the necessary skills.

3. What are some examples of expanded functions in science?

Some examples of expanded functions in science include advanced imaging techniques such as electron microscopy, genetic engineering, and computational modeling. Other examples include advanced statistical analysis, use of specialized equipment like mass spectrometry, and conducting experiments in extreme conditions such as zero gravity or high pressure.

4. What are the benefits of using expanded functions in science?

The use of expanded functions in science allows for more precise and accurate data collection, analysis, and interpretation. It also allows for the study of complex phenomena that cannot be observed or manipulated using traditional methods. Additionally, expanded functions can lead to new discoveries and advancements in various fields of science.

5. Are there any risks associated with working with expanded functions?

Yes, there can be risks associated with working with expanded functions in science. These can include exposure to hazardous materials, potential equipment malfunctions, and ethical considerations when conducting experiments on living organisms. It is important to follow safety protocols and guidelines, and to always consider the potential risks before using expanded functions in research.

Similar threads

Replies
3
Views
2K
  • Calculus
Replies
11
Views
2K
  • Calculus
Replies
2
Views
1K
Replies
5
Views
1K
  • Calculus
Replies
2
Views
2K
  • Special and General Relativity
Replies
2
Views
949
Replies
14
Views
2K
Replies
5
Views
2K
Replies
1
Views
2K
Replies
12
Views
2K
Back
Top