Page **1** of **1**

### Scaling factor in two matrix

Posted: **2016-06-24T21:47:53-07:00**

by **life24**

Hello,

I reading an article and i can't understand well about scaling factor.

Could you give me definition and example about scaling factor?

How can embed one matrix to other matrix with scaling factor?

Thanks

### Re: Scaling factor in two matrix

Posted: **2016-06-24T22:18:28-07:00**

by **fmw42**

It might help if you give a reference to that article.

Guess at this point is the the diagonal elements of the D matrix used for the watermarking are scaled (magnified) to enhance the separability of low diagaonal values where the image is flat colored.

### Re: Scaling factor in two matrix

Posted: **2016-06-24T23:22:49-07:00**

by **life24**

Sure,

Reference article is here and we can read it free.

http://www.sciencedirect.com/science/ar ... 0915001945

### Re: Scaling factor in two matrix

Posted: **2016-06-27T05:39:04-07:00**

by **life24**

Emailed to the owner article and answered me, now could you give me more explain about it?

*Embedding a matrix into another one can do as matrix addition. Scaling factor is used for obtaining the invisibleness of the watermark. Pls find the below.*

Watermarked= A + (s*B).

Here A &B are matrices of cover and watermark. s is the scaling factor. U may vary this according to invisibleness that ur need.

### Re: Scaling factor in two matrix

Posted: **2016-06-27T06:21:34-07:00**

by **snibgo**

An image is an array of pixels. It is also a number of arrays of values, where each array represents one channel.

Image arrays can be added together. We can multiply one array by a *scalar* factor (that is, a single value, like 0.05) before adding it to another.

In IM, "-compose Mathematics" is useful for this.

### Re: Scaling factor in two matrix

Posted: **2016-06-27T06:24:15-07:00**

by **life24**

We have the below formula

Watermarked= A + (s*B).

If A and B between 0 and 255, for example we have:

S = 0.5 , A = 250 and B = 245

Watermarked = 250 + (0.5*245) = 372.5 !!!

But each pixel is 8-bit and should be between 0 <= intensity <= 255 .

### Re: Scaling factor in two matrix

Posted: **2016-06-27T06:33:37-07:00**

by **snibgo**

Well, not exactly. A and B are arrays. So each value in array B is multiplied by s, then added to the corresponding value in B.

Yes, the simple formulae can give overflow (aka clipping). So the array values can be reduced first, or the result is reduced after the calculation, or a different formula used:

out = A*(1-s) + B*s

This is a blending function.

### Re: Scaling factor in two matrix

Posted: **2016-06-27T06:41:24-07:00**

by **life24**

Thank you for your reply,

The below formula is your formula? or it's from other papers?

out = A*(1-s) + B*s

We have out intensity and watermark is fine.

Now with Scale(for example : 0.5 ) and out ,how we can extract A and B ?

### Re: Scaling factor in two matrix

Posted: **2016-06-27T06:47:36-07:00**

by **snibgo**

It's a standard blending function. If you know three of the four variables (out, A, B, s) you can easily calculate the fourth, for example:

A = (out - B*s) / (1-s)

### Re: Scaling factor in two matrix

Posted: **2016-06-27T06:55:51-07:00**

by **life24**

snibgo wrote:It's a standard blending function. If you know three of the four variables (out, A, B, s) you can easily calculate the fourth, for example:

A = (out - B*s) / (1-s)

Thank you for your reply,

yes, but when watermark image in the cover image(A and B) , we lost A and B in watermark image.

We just s and out . we don't have A or B.

We don't have B to calculate A. or A to calculate B.We just s and out

### Re: Scaling factor in two matrix

Posted: **2016-06-27T07:30:00-07:00**

by **snibgo**

The paper is vague on that. It also says it is "embedded on the singular values of cover image", but there are only 2*min(W+H) non-zero values in the "singular values" matrix. So I don't know how that works.