MathGroup Archive 2010

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: Rule

  • To: mathgroup at smc.vnet.net
  • Subject: [mg108473] Re: Rule
  • From: dh <dh at metrohm.com>
  • Date: Fri, 19 Mar 2010 02:48:17 -0500 (EST)
  • References: <hnss20$5q5$1@smc.vnet.net>

Hi Rui,
I think it is simplier to transfrom the expression before stuffing it 
into "FourierTransfrom".
Here is a rule that transforms an expression according to your needs :

rule = expr0_ /; (pos = Position[expr0, (k_ /; FreeQ[k = k, t]) t];
      Equal @@ Extract[expr0, pos]) :> (1/Abs[k] expr0 /. k t -> t);

here is an example:
Sin[k t] + (Cos[k t + 2])^2 /(1 + k t)  /. rule

If you want to include "FourierTransfrom" into the process it gets more 
complicated, because we must take care that the transfrom is not done 
too early:

rule = HoldPattern[
     FourierTransform[expr1_, t,
       f] /; (pos = Position[expr1, (k_ /; FreeQ[k = k, t]) t];
       Equal @@ Extract[expr1, pos])] :>
    1/Abs[k] FourierTransform[expr1 /. k t -> t, t, f/k];

here is an example:

expr = Sin[k t] + (Cos[k t + 2])^2 /(1 + k t);
Hold[FourierTransform[expr0, t, f]] /. expr0 -> expr /.
   rule  // ReleaseHold
Daniel

On 18.03.2010 10:33, Rui wrote:
> I got surprised when I saw that my Mathematica 7 computed
> FourierTransform[DiracComb[t], t, f] without trouble but couldn't deal
> with
> FourierTransform[DiracComb[2 t], t, f]
>
> So I thought about writing a rule that uses the property that the
> F{x[k t]}[f] = 1/|k| F{x[t]}[f/k] (I think :P)
>
> In Mathematica's words:
> FourierTransform[ expr_ , t_, f_]   should be transformed, only if in
> "expr" you can find aall "t"s multiplied by the same thing (let's call
> it "k"), and that thing doesn't have "t"s inside, into
> 1/Abs[k] FourierTrnasform[expr_ (* having replaced the k t  by t *),
> t, f/k]
>
> I'm a little lost. Even if I could find a way to do it, I wanna know
> how you would do it, because I'm already thinking about complicated
> stuff and it doesn't seem neither a too complex or too unusual
> problem.
>
> Thanks ;)
>


-- 

Daniel Huber
Metrohm Ltd.
Oberdorfstr. 68
CH-9100 Herisau
Tel. +41 71 353 8585, Fax +41 71 353 8907
E-Mail:<mailto:dh at metrohm.com>
Internet:<http://www.metrohm.com>



  • Prev by Date: Re: Rule
  • Next by Date: Re: Possible bug: Integrate[(u - t)*BesselY[0, 2*t], {t,
  • Previous by thread: Re: Rule
  • Next by thread: Re: Rule