How to represent a series of numbers into characters

1 次查看(过去 30 天)
I have a sine wave which is wavelet thresholded (say soft thresholding). How to program so that the signal is transformed using a discrete wavelet transform and then display the coefficients of the signal in this new basis using alphabetical characters rather than using numbers. Then,to find the histogram such that I get to know the frequency of occurrence of each character.
For instance: $a=(\text{coeff}_1,\text{coeff}_2,...,\text{coeff}_9)$, $b=(\text{coeff}_{10},...,\text{coeff}_{19})$, and so on. Now, the depending on how many numbers are to be represented by a single character, a rule can be formed such that say if the number of alphabets are 8 and the length of the signal is 1000 then how to specify a sliding window for the assignment of characters?It is possible that there can be more than one instance of $a$ coefficients; they are not unique numbers. This is similar to a compression technique. The characters of alphabets can be assigned by Markov Method or any arbitrary user defined rule.
  2 个评论
Walter Roberson
Walter Roberson 2012-1-18
Cross-reference: http://www.mathworks.com/matlabcentral/answers/25961-how-to-represent-numbers-as-characters-in-an-image
chitra
chitra 2012-1-19
That question was not answered since it lacked clarity and example in the question. Hope this one is clear enough to invite answers!It would be more helpful if a solution is posted instead of tracking. Hope,this time the question is clear.Thank you for any help.

请先登录,再进行评论。

回答(1 个)

Walter Roberson
Walter Roberson 2012-1-19
Unfortunately the answer I had composed for you was eaten by the system maintenance starting. Ah well.
I would say that your requirements are not simply "similar to" a compression technique, but rather that they are a compression technique. I recommend you look at it that way, and read compression theory rather than trying to invent your own schemes at this time.
I used to hang out on comp.compression and saw a lot of techniques proposed that would not actually work; it could sometimes be quite difficult to convince the proposers that the flaw was there.
A book I recommend highly is Text Compression by Bell, Cleary, Witten. I find that I have used the material from that book over and over again in a wide variety of circumstances.
I would say offhand that the comparison of the LZ77 and LZ78 algorithms would be useful for clarifying your thoughts about what you are doing and why.
  2 个评论
chitra
chitra 2012-1-22
Thank you for the response. It would highly ease out the first step if you could illustrate with a code of simply assigning characters to the coefficients so that I get some idea before getting drowned in the books u referred.
Walter Roberson
Walter Roberson 2012-1-22
I do not think it would ease anything if I were to do that. Your thinking about what you are doing appears to be sufficiently unclear that if I were to show one method without presenting the background materials, then you would get stuck in that method.
You could research LZ77 and LZ78 specifically, but it would be better to have a fair bit of background reading in order to understand what they are doing and why.

请先登录,再进行评论。

标签

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by