OFFSET
1,1
COMMENTS
The sequence A215142 is included in this sequence.
LINKS
Robert Israel, Table of n, a(n) for n = 1..10000
EXAMPLE
105 is in the sequence because 105 = 3*5*7 and 7 - (3 + 5) = 7 - 8 = -1;
231 is in the sequence because 231 = 3 * 7 * 11 and 11 - (3 + 7) = 11 - 10 = 1.
MAPLE
filter:= proc(n) local P, pmax;
P:= numtheory[factorset](n);
abs(convert(P, `+`)-2*max(P))=1
end proc;
select(filter, [$1..10000]); # Robert Israel, Jun 23 2014
MATHEMATICA
fpdQ[n_]:=Module[{f=Transpose[FactorInteger[n]][[1]]}, Max[f]-Total[Most[f]]==1]; gpdQ[n_]:=Module[{g=Transpose[FactorInteger[n]][[1]]}, Max[g]-Total[Most[g]]==-1]; Union[Select[Range[2, 3000], fpdQ ], Select[Range[2, 3000], gpdQ ]]
dbgQ[n_]:=Module[{fi=FactorInteger[n][[All, 1]]}, Abs[fi[[-1]]-Total[ Most[ fi]]]==1]; Select[Range[2, 1500], dbgQ] (* Harvey P. Dale, Jan 01 2020 *)
CROSSREFS
KEYWORD
nonn
AUTHOR
Michel Lagneau, Jun 22 2014
STATUS
approved