Re: Easiest Mathematica algorhitm needed

• To: mathgroup at smc.vnet.net
• Subject: [mg92830] Re: [mg92793] Easiest Mathematica algorhitm needed
• From: Bob Hanlon <hanlonr at cox.net>
• Date: Tue, 14 Oct 2008 04:59:03 -0400 (EDT)

```data = Table[Sqrt[n!], {n, 1, 10}];

sp = data /. Sqrt[_] -> 1

{1,1,1,2,2,12,12,24,72,720}

sfp = data/sp /. Sqrt[x_] -> x

{1,2,6,6,30,5,35,70,70,7}

Bob Hanlon

---- Artur <grafix at csl.pl> wrote:

=============
Dear Mathematica Gurus,
Who know which Matrhematica function uses to separate square free part
of number.
e.g.
In[1]: Table[Sqrt[n!], {n, 1, 10}]
Out[1]: {1, Sqrt[2], Sqrt[6], 2 Sqrt[6], 2 Sqrt[30], 12 Sqrt[5], 12
Sqrt[35],
24 Sqrt[70], 72 Sqrt[70], 720 Sqrt[7]}
What to do to take squre-free parts:
{1, 2, 6, 6, 30, 5, 35, 70, 70, 7}
or square parts
{1, 1, 1, 2, 2, 12, 12, 24, 72, 720}
Best wishes
Artur

--

Bob Hanlon

```

• Prev by Date: Re: Conditional SetDelayed with Replacement
• Next by Date: Re: Docked header cell in slide show
• Previous by thread: Re: Reading numerical data from a file which also contains a text
• Next by thread: Re: Easiest Mathematica algorhitm needed