Re: ZTransform for a non-causal unstable signal. How to make Mathematica gives correct result?
- To: mathgroup at smc.vnet.net
- Subject: [mg108236] Re: ZTransform for a non-causal unstable signal. How to make Mathematica gives correct result?
- From: "Nasser M. Abbasi" <nma at 12000.org>
- Date: Thu, 11 Mar 2010 06:37:12 -0500 (EST)
- References: <hn7f5s$2u4$1@smc.vnet.net> <4B97560C.7040902@metrohm.com> <014b01cac084$e1fa1700$2c8cfea9@computerh20djr> <4B989125.50607@metrohm.com>
- Reply-to: "Nasser M. Abbasi" <nma at 12000.org>
----- Original Message -----
From: "dh" <dh at metrohm.com>
> Hi Nasser,
> the result from Mathematica is:
> -(2/(-2 + z))
> The inverse z transform of this:
> -2^n UnitStep[-1 + n]
> now you can write this as:
> - (1/2)^(-n) UnitStep[n-1]
> what is consistent with where we started.
>
Hello Daniel;
Well, yes, ofcourse. But the point is what you started with an expression
which is _not_ the Z transform result I should get from my original
expression, which is
-(1/2)^n)*UnitStep[-n - 1];
> However, if we back transform your "hand" result, we get:
> (-(1/2))^n Binomial[-1, n]
> what does not look like your initial expression.
> Daniel
>
My hand calculations shows that the Z transform of -(1/2)^n)*UnitStep[-n -
1] is 1/(1- 0.5 z^-1), with ROC of |z|<1/2, this is correct. (unless you
show me where I made an error).
So, The inverse Z transform of 1/(1- 0.5 z^-1) has to come back as what I
started with. BUT one must use the ROC |z|<1/2.
A ztransform is not unique without giving the ROC. i.e. 2 same Ztransform,
but with different ROC, can give back different sequences. Becuase for
example, and right sided sequence can give the same Z transform as a left
sided sequence (one will stable and the other not). So when doing inverese Z
transform, how does it know which one to return back if it did not know the
ROC?
So, Mathematica result you showed above, saying the InverseZ of my sequence
is (-(1/2))^n Binomial[-1, n] must be for ROC |z|>1/2 (i.e. causal and
stable) and not |z|<1/2, which is not what I had.
I do not know how to tell InvserZtransform that the ROC is |z|<1/2, I tried
this:
InverseZTransform[1/(1-0.5 z^-1),z,n,Assumptions->Abs[z]<1/2]
but result did not change to what I expected.
--Nasser
>
> On 10.03.2010 20:07, Nasser M. Abbasi wrote:
>>>> On 10.03.2010 07:45, Nasser M. Abbasi wrote:
>>>>
>>>> I am trying to find the Z transform using Mathematica for the signal
>>>>
>>>> (-(1/2)^n)*UnitStep[-n - 1];
>>>>
>>
>>
>>> Hi Nasser,
>>> Mathematica calculates the unilateral Z transfrom. This is clearly zero in
>>> your case. But in your case you may get the bilateral by setting n ->
>>> -n in f:
>>>
>>> f = (-(1/2)^(-n))*UnitStep[n - 1];
>>> ZTransform[f, n, z]
>>>
>>> Daniel
>>>
>>
>>
>> I had a second look at the above solution, but the result obtained still
>> does not match my hand calculation actually, Here is the output from the
>> above code:
>>
>> -(2/(-2 + z))
>>
>> Which can be rewritten as
>>
>> 1
>> -------------
>> 1- 1/2 z
>>
>> In addition, when using GenerateConditions -> True option, I get that
>> |z|>2
>>
>> *But* the result I should get is
>>
>> 1
>> -------------
>> 1- 1/2 z^-1
>>
>> With |z|<1/2. Notice the z^-1 vs z in the denominator.
>>
>> so, more tweaking is needed I think. getting close, but Just changing
>> the "n" from +n to "-n" did not seem to do the trick?
>>
>> I need to look more into this. But at least now I know what the correct
>> definition of Ztransform used by Mathematica is. All of this could have
>> been avoided if the Ztransform was defined to be 2-sided. Now each time
>> I have a left sided signal, I have to play tricks to feed it to the
>> Ztransform. Also, If I have 2 sided signal, I have to break it up and
>> play more tricks, which can lead to errors.
>>
>> --Nasser
>>
>>
>>
>>
>
>
> --
> Daniel Huber
> Metrohm AG
> International Headquarters
> Oberdorfstr. 68, CH-9101 Herisau / Switzerland
> Phone +41 71 353 8606, Fax +41 71 353 89 01
> Mail <mailto:dh at metrohm.com>
> Web <http://www.metrohm.com
>
>