## 5 Reputation

11 years, 211 days

## I'm thinking:   criterion:=proc(t...

I'm thinking:

criterion:=proc(t)

local L;

L:=limit(t/r,r=infinity);

coulditbe(abs(L)<>0)

end proc

## So after a little more investigation the...

So after a little more investigation the proc:

criterion:=proc(t)

local L;

L:=limit(t/r,r=infinity);

is(abs(L)<>0)

end proc

almost works. The only point where it fails it for the finite terms i..e something that started as ( r^9*a)/((b+r^4)^2) so has a limit of r. and comes out as : 'a'. Then is(abs(a) <>0) is still unsure.

## I have one more small issue here. I have...

I have one more small issue here. I have quite a lot of constants, and it would be very time consuming for me to have to write assume(a>0), assume(b>0) etc, in maple...

The problem is that when I run the is(limit(t/r^2, r=infinity) <> 0) on a term that looks like say [a/sqrt(1+b)]*r^3, giving [signum(a)/(sqrt(signum(b+1))]x infinity,  then it can't tell if it's non zero or not,Maple returns is(signum(a)/sqrt(signum(b+1))*infinity <>0) as false, and is(signum(a)/sqrt(signum(b+1))*infinity =0).

my solution was just to use the select(has, [signum(a) x infinity/(sqrt(signum(b+1))], r) method which returns 1.

but this select(has,expr, r) behaves strangely, e.g. select(has,b, r) seems to return nothing, but select(has,b+1,r) returns zero, as does select(has, c*b+1,r), but then select(has,c*(b+1),r) returns 1?? Also my select(has, a/sqrt(b+1), r) returns 1. Why is it behaving like this? it seems to be doing what I want just because all my coeffs are of this fractional form, so when I get non zero one I do the select(has,expr, r) method on it, which converts it to 1<>=0,  and when I get a zero limit, select(has..) obviously leaves it as 0, and everything proceeds as your above post. But I can't explain it's behaviour. Is there a simpler way?

The other thing I've tried is using type(signum(a)*infinity, SymbolicInfinity) which returns true, so this seems to allow me to tell if I have a term with a postive power of r limit. Regardless of the coeff values being unspecified. So then I can also tell if I have a negative power of r limit, by looking if it's zero. But now I still can't tell if I have a finite limit like just sig(a)/sqrt((sig(b+1)) because this does not return true for non zero.

I thought then just using is(abs(L) <>0) might be the way forward, it seems to give varying results however...

## That's great, exactly what I'm looking f...

That's great, exactly what I'm looking for I think thanks.

what was the 'range' part for in your earlier code?

`not type(L,{infinity,range})`

I understood why you don't want type infinity, but range?

## Yeah, I know that you could catch r^d or...

Yeah, I know that you could catch r^d or greater just by changing the r^2 in your code appropriately, what I meant was I need to simulataneously catch everything with d greater than say 2....so I would need some kind of loop discarding everything below this, keeping only the ones above d

## This actually works a treat, I think I u...

This actually works a treat, I think I understand that line now. It's disregarding things of type infinity or zero (I didn't realise <> was not eq).

My one remaining issue is that I don't just need to find things of order 'r', say, I need to find things of order r or greater, i..e. r,r^2, r^3........and I would like to disregard things below this.

This is not always r,r^2,r^3...... it could be 1/r^2,1/r, finite, r,r^2...... etc.....basically it will vary depending on which block of terms I'm analyzing, but it seems your code could be adapted to handle this, although I'm not sure exactly how

## Thanks for the reply. Could you possibly...

Thanks for the reply. Could you possibly break down what is going on here for me?

you define a function called criterion that takes a variable t? then inside this function you define local variable L. You then assign to this variable the result of taking the large r limit of t*r^2.

type(L,{infinity,range}) and is (L<>0), I am lost at this point......

then it appears from google, that when you write select(criterion,L), now criterion is the 'boolean valued procedure' and the L here is no longer the local L, but the global L, i.e. my sum of terms? select then takes my sum of terms and displays the ones that fulfil the proc?

 Page 1 of 1
﻿