Services & Resources / Wolfram Forums
-----
 /
MathGroup Archive
2005
*January
*February
*March
*April
*May
*June
*July
*August
*September
*October
*November
*December
*Archive Index
*Ask about this page
*Print this page
*Give us feedback
*Sign up for the Wolfram Insider

MathGroup Archive 2005

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

Search the Archive

Re: spiral cipher

  • To: mathgroup at smc.vnet.net
  • Subject: [mg55850] Re: spiral cipher
  • From: zak <chocolatez at gmail.com>
  • Date: Fri, 8 Apr 2005 01:36:22 -0400 (EDT)
  • Reply-to: zak <chocolatez at gmail.com>
  • Sender: owner-wri-mathgroup at wolfram.com

Thanks dh at metrohm.ch for your letter
i mean the following
moves={0, 5, 2, 7, 4, 6}
so the movement of the point will trace across the following points:
dat = {{0, 0}, {5, 0}, {5, 2}, {5 - 7, 2}, {5 - 7, 2 - 4}, {5 - 7 + 6, 2 - 4}}

Show[Graphics[Line[dat]]];

will draw the spiral.

the problem how to construct (dat List) from (moves List)

regards


======================================

From: dh <dh at metrohm.ch>
To: mathgroup at smc.vnet.net
Subject: [mg55850] Re: spiral cipher

Hi zak,
here a short solution:
get some data:
dat = ToCharacterCode["i love apples and cats"];
calculate the spiral
res = {};
Fold[(AppendTo[res, {#1 + {#2[[1]], 0}, #1 + {0, #2[[2]]}, #1 +
   {-#2[[3]], 0}, #1 + {0, -#2[[1]]} } ]; {0, -#2[[1]]} ) & , {0, 0} ,
Partition[dat, 4] ];
and draw it:
Show[Graphics[Line[Flatten[res, 1]]]];

=================================
suppose i have the string "i love apples and cats"
the sentence composed from 18 letters. we will neglect space letter.
if we give to every letter a value which depend on the english alphabet such as:
a=1; b=2 ; c=3; d=4;...; i=9;...; l=12 ...
now i pick the letters one by one:
I=9  plot 9 units to the right
L=12  plot 12 units to the north
O=15  plot 15 units to the left
V=22  plot 22 units to the south
E=5  plot 5 units to the right
and so on...

this will create a messy spiral but it will represent our string.
we may dream to see some patterns in poets or similar texts.
i hope someone may have an idea about how to draw this messy spiral
cipher using mathematica
we will see if the letters of some texts will crawl to some
directions, or it will clutter arround the center point
and if someone could construct a text wich when spiralling it will
crawl to the north as an example. or may plot a bird figure.
regards
zak


  • Prev by Date: Re: Numerical accuracy of Hypergeometric2F1
  • Next by Date: Re: Re: spiral cipher
  • Previous by thread: Re: spiral cipher
  • Next by thread: Re: Re: spiral cipher