This is a general question about modeling the seasons using sine and cosine functions; I am trying to use sine and cosine to model cyclic behavior in sales due to the seasons (spring, summer, fall and winter);

Eliza Gregory

Eliza Gregory

Answered question

2022-10-25

Sine and Cosine Models
This is a general question about modeling the seasons using sine and cosine functions; I am trying to use sine and cosine to model cyclic behavior in sales due to the seasons (spring, summer, fall and winter); I have the following seasonal factors so to speak:-
t = 0 Start of year
t = 3 Spring - sin ( π t ) 12
t = 6 Summer - sin ( π t ) 12
t = 9 Fall - sin ( π t ) 18
t = 12 Winter - cos ( π t ) 6
I want to get sales to be max in each period for a given product. For example I want sales for sandals to max in the spring and sales for cardigans to max in the fall.
I Would appreciate advice and guidance as am not sure if these are correct. But looking at the graphs, they seem reasonable.

Answer & Explanation

zupa1z

zupa1z

Beginner2022-10-26Added 20 answers

Step 1
Consider an arbitrary sinusoid:
A cos ( 2 π T t + ϕ )
Where A is the amplitude (the peak price), T is the period (the amount of time it takes for the function to repeat itself), and ϕ is the phase shift (the "starting point" of the cycle). You want your period to be 12 months, so the function will be
A cos ( π 6 t + ϕ )
Keep in mind though that this function will drop below zero (and I'm sure you don't want to pay your customers to take the merchandise off your hands on off seasons!), so in order for it to vary from A to 0 instead, cut the amplitude in half and add half the amplitude to the function:
A 2 cos ( π 6 t + ϕ ) + A 2
Step 2
The phase shift ϕ can be calculated by multiplying the time where the peak should occur by the angular frequency (the coefficient of t). So for example, if you wanted the price to peak every spring, ϕ = 3 ( π 6 ) = π 2 .
Tara Mayer

Tara Mayer

Beginner2022-10-27Added 4 answers

Step 1
Let's measure time t in days, t = 1 corresponding to 12 a.m. January 1 s t , and each month has 30 days. So the relevant period is T = 360, corresponding to 360 in angular measure. The "simplest" periodic function of period T having its peak at t = t 0 is given by
(1) f ( t ) = m + a cos 2 π ( t t 0 ) 360   .
This "Ansatz" is so simple that f will automatically have its minimum at t 0 + 180, which is maybe not what you want. Putting this point aside we now have to adjust the parameters m and a appearing in (1) to actual sales data.
Step 2
We want f(t) to represent the expected sales on day t. Since the mean value of cos over a full period is 0 it follows that
(2) m = Y 360   ,
where Y denotes the total sales over a year. Denote by f max and f min the maximal and minimal observed daily sales. Then our "Ansatz" enforces
m = f max + f min 2   ,
which will most probably not be fulfilled in practice, and secondly one has
(3) a = f max f min 2   .
Plugging (2) and (3) into (1) we obtain
f ( t ) = Y 360 + f max f min 2 cos 2 π ( t t 0 ) 360   .
In this way we shall order the right number of shoes, but whether we shall properly accommodate the sales peaks and lows is not so sure.

Do you have a similar question?

Recalculate according to your conditions!

Ask your question.
Get an expert answer.

Let our experts help you. Answer in as fast as 15 minutes.

Didn't find what you were looking for?