last day (15 days later) » 

11:45 PM
0
Q: How to optimize for following cost function?

Saksham JainFor given values of constants $\forall i $ $a_i, b_i, c$ such that $a_i, b_i, c_i \in R^+$ and $0 < a_i < 1$, find all variables $n_i$ such that $$n_i \in Z^+$$ and $$c \ge \sum_{i}{\frac{b_i}{n_i} * \lceil{a_i * n_i}\rceil}$$ while minimizing the cost function $$\sum_i{n_i}$$ What I have found...

 
This doesn't make any sense, so far as I can see. If $n_ia_i \in \mathbf Z^+,$ then so is $kn_ia_i $ for every $k\in \mathbf Z^+,$ so how can you say this "solution" minimizes the sum of the $n_i?$ Also, what if $a_i$ is irrational?
 
As I mentioned in the post, "so one solution for the given problem is always easy to find." BUT "this solution doesn't necessarily optimize the cost function". Also, I will edit the question to mention that all a, b, c are rationals.
 
Sorry, I missed that line.
Now I understand what you are saying. There is no solution unless $c\ge \sum{b_ia_i},$ and in that case, we can take $n_i$ to be the smallest positive integer such that $a_ic_i\in \mathbb Z^+,$ but that's not necessarily the optimum. Is this correct?
 
Yes, exactly. (One small correction in your comment $a_i * n_i \in Z^+$ instead of $a_i * c_i \in Z^+$) Btw, thanks for your comments!
 
Is all we know about $c$ that it is rational? BTW, you haven't edited the question to show the conditions on $a_i,b_i,c.$ This seems really hard. I don't have a clue. (Of course, I'm often clueless, so that doesn't mean much.)
 
11:45 PM
$a_i, b_i, c$ are all given i.e. they all are constants. Also, given is that $0 < a_i < 1$. Apart from that, all we know pretty much is that they all are positive rational numbers. This equation arises when I am trying to solve a problem at work. I don't have much more information about these constants that what is given. Do you have any particular information that you would like about these constants?
 
Are you there?
 
Yes I am here
I have placed the conditions in the body
 
I guess my last comment didn't get posted. I had assumed the problem was a textbook exercise, so I assumed there would be a neat solution. I thought that perhaps $c$ was an integer.
 
Would it help if c is an integer. Do you have a solution in case it is an integer. Because that too will work if you have a solution assuming c is intefer
 
I don't have a solution if $c$ is an integer. I just thought that might make it easier. Let's say we start by making $n_i$ the smallest positive integer such that $n_ia_i$ is integral. Is it clear that there are no better solution that use a bigger $n_i$ for some $i$? Not to me.
 
11:51 PM
Let me give yo an example. Give me 5 mins.
 
Oops. I didn't realize we can't use MathJax here.
 
Suppose c=2, a_1 = 3/7 a_2 = 2/8 b_1 = 3 b_2 = 1. Then I am the optimal solution is n_1 = 2, n_2 = 2. Whereas by taking n_i as the smallest positive integer such that $n_ia_i$ is integral we will have n_1 = 7 and n_2 = 4, which though works but is not optimal.
Sorry for the weird values of a_i. But this is real life example I have encountered.
 

  last day (15 days later) »