X****r 发帖数: 3557 | 1 I don't know the GAMS at all, but the easy way to model this
kind of problem is using an assigment matrix x_{ij},
with x_{ij} = 1 if the ball i is in bag j, 0 otherwise.
so we have constraints:
x_{ij} >= 0
x_{ij} <= 1
\sum_j x{ij} = 1
Denote the weight for ball i is w_i.
For all j, we want w_i be the same for all i that x_{ij}=1,
i.e. w_i*x_{ij} and x_{ij} linearly dependent. if we define
o_j = (\sum_i (w_i^2*x_{ij}^2))(\sum_i x_{ij}^2) - (\sum_i (w_i*x_{ij}^2))^2
then using Cauchy-Schwarz inequ |
|
J*****n 发帖数: 48 | 2 I need to let function A be an argument for function B,
but function A has two forms (override), how can I
include the two types as a general form of A in argument of B?
for example
float A(int);
float A(int, double);
I want
float B((*A)(?),other arguments)
how do I substitute content denoted by "?" |
|
p***o 发帖数: 1252 | 3
有点。
没看明白,你说啥?是不是这个:
14.1.2
There is no semantic difference between class and typename in
a template parameter. typename followed by an unqualified-id
names a template type parameter. typename followed by a
qualified name denotes the type in a non-type parameter
declaration. A storage class shall not be specified in a
template parameter declaration. |
|
n*******r 发帖数: 444 | 4 来自主题: Programming版 - 算法求教 给定一个array A, size(A) = n, n is an even number.
Denote Sum(A) = A[0]+A[1]+...+A[n-1]
Split A into A1, A2, size(A1) = size(A2) = n/2,
the goal is to minimize Sum(A1)-Sum(A2).
Is there any efficient algorithms for this problem? |
|
i******r 发帖数: 323 | 5 来自主题: Programming版 - 问个算法题 动态规划
假设N > 0
double max, curr=-1;
int maxI = -1, maxJ; //use maxI == -1 to denote that max = -infinity
int currI;
for (int i = 0; i < N; ++i) {
if (curr < 0) {
curr = 0;
currI = i;
}
curr = curr + a[i];
if (maxI < 0 || curr > max) {
maxI = currI;
maxJ = i;
max = curr;
}
}
//now maxI and maxJ is what you want
//complexity O(N) |
|
b***e 发帖数: 1419 | 6 来自主题: Programming版 - 算法问题。 We define a follower relation between each 2 line segments:
l1 follows l2 iff l1.start == l2.end. We use l2 < l1 to denote l1
follows l2.
Let start = [A, A], and end = [B, B], and consider set of line
segments extened with start and end.
The follower relation naturally leads to a partial order on the all
the line segments, which is, in fact, a direct acyclic graph. Now the
only thing you need to do is to find a shortest path from start to
end, which can be done using standard bfs graph travers |
|
X****r 发帖数: 3557 | 7 Okay, insomnia bothers me, so I might as well look into this problem.
Say there is n buttons, their states being b_i, where 1 < i < n.
Now define the state of the buttons s = [b_1, ..., b_n]. However,
existence of rotation (or any other kind of operation) divides the
state set S into equivalence classes. Denote the set of these
equivalence classes S'. Similarly, define an action a = [f_1, ...,
f_n], where f_i, 1 < i < n, is whether the button is pushed or not;
and rotation divides the action set |
|
b***e 发帖数: 1419 | 8 Somewhat I expected a good one from you. And here we go.
This looks very promising, but man, you are going with a real operational
approach while I am looking for some sort of denotational explanation.
Nonetheless, here's the question (where I believe you have a typo):
by
if len(s_i) <= j, use a[len(s_i)-j] as s_i[j] // negative index?
do you really mean:
if len(s_i) <= j, use s[j-len(s_i)] as s_i[j]
There are further questions, but let's figure out the most essential one
first. |
|
X****r 发帖数: 3557 | 9 Hmm interesting, I had thought of this but just didn't think it
would be a total order. But upon a closer look it is quite obvious:
assume the size of character set is n, then all strings can be mapped
to numbers in base n. Denote x(s) as the number for string s, and l(s)
as its length, ab <= ba then is as same as
x(a)*n^(l(b)) + x(b) <= x(b)*n^(l(a)) + x(a)
which is equivalent to
x(a)/(n^(l(a))-1) <= x(b)/(n^(l(b))-1)
so obviously it is transitive. The above means that you may as well
repeat th |
|
X****r 发帖数: 3557 | 10 Neither 10 or 20 appears in the vptr at all. The value to
pass to the function is determined at the compile time according
to the static type of the object, not the dynamic type.
8.3.6 Default arguments
10 A virtual function call uses the default arguments in the
declaration of the virtual function determined by the static
type of the pointer or reference denoting the object. An
overriding function in a derived class does not acquire default
arguments from the function it overrides... 阅读全帖 |
|
E******T 发帖数: 59 | 11 Here is part of MPI code, a is a matrix with column NCA, offset is the start
point of row number of matrix a. The confusing part is ((double (*)[NCA])a)
, does it denote NCA number of pointer in matrix a?
any comments? Thanks
MPI_Send(&((double (*)[NCA])a)[offset][0], rows*NCA, MPI_DOUBLE, dest
, mtype,
MPI_COMM_WORLD); |
|
E******T 发帖数: 59 | 12 float **x;
x = (float **)malloc(k*sizeof(float *)); /* Make space for the data */
in this example, sizeof(float *) and sizeof(float) has any difference? the
denotation * means a pointer?
Thanks |
|
k****e 发帖数: 126 | 13 C99里面对function call是这样规定的,6.5.2.2 Function calls:
If the expression that denotes the called function has a type that does
include a prototype, the arguments are implicitly converted, as if by
assignment, to the types of the corresponding parameters, taking the type of
each parameter to be the unqualified version of its declared type.
对于assignment是这样规定的,6.5.16.1 Simple assignment:
one operand is a pointer to an object or incomplete type and the other is a
pointer to a qualified or unqualified ver... 阅读全帖 |
|
b***e 发帖数: 1419 | 14 Seems it's just a queue construct starting from the super set of roots. For
your example, start with:
{{}|{a,b}, {a}|{b}, {b}|{a}, {a,b}|{}}
Note we use S1|S2 to denote a state where the nodes in S1 must appear and
nodes in S2 must not appear in any future extension.
Pop {}|{a,b}. You can not reach more with empty starting set, so this is it.
Pop {a}|{b}, which means a is in and b is out. This state only reaches {a,c
}|{b}, so we push that in.
Pop {b}|{a}. This state doesn't reach anywhere, ... 阅读全帖 |
|
g*********e 发帖数: 14401 | 15 来自主题: Programming版 - 出道面试题 dp
Use Boolean matrix dp(x, s) to denote if frog can reach rock x at step s.
O(n*s*s) |
|
d******c 发帖数: 2407 | 16 第二个运行结果不对把
is.na(x)[2] <- T 是什么乱七八糟的?这跟x根本没关系,根本没改变x好吧,我运行
结果x也没有变。
而且用T当TRUE是非常坏的用法。
TRUE and FALSE are reserved words denoting logical constants in the R
language, whereas T and F are global variables whose initial values set to
these.
> (x <- factor(c(1, 2, NA) , exclude = NULL))
[1] 1 2
Levels: 1 2
> x
[1] 1 2
Levels: 1 2
> is.na(x)[2]
[1] FALSE
> is.na(x)
[1] FALSE FALSE FALSE
> is.na(x)[2] <- T
> x
[1] 1
Levels: 1 2 |
|
w******e 发帖数: 12 | 17 比如
\vspace{0.1in}
The actual effect of first attack is ...,
which can be denoted as V\rightarrow I.
the second kind of...
\rightarrow 后面的文字就都变成斜体字,并且没有字间空格。我是在window下编辑te
x文件,然后在linux下编译。
后来我用了$, i.e. $V \rightarrow I$ 虽然控制住了范围,但是变成斜体字了:( |
|
T*******n 发帖数: 493 | 18 \rightarrow is a math mode command, so you can only use it in
an equation, e.g., surrounded by $...$ or \begin{equation}...\end{equation}.
Here you want to say
which can be denoted as $V\rightarrow I$.
Because the $...$ were missing, LaTeX added a $ in front of \rightarrow.
If you ran LaTeX on the command line in Linux or Windows, LaTeX should
have stopped to tell you that it had to add the $; it might not stop if you
ran LaTeX from some kind of integrated editor that throws away LaTeX's
wa |
|
s*****g 发帖数: 5159 | 19 If you can save your xls as a csv, write a shell script and make that happen.
Someone write a csv2tabular with reasonable parameter set, I personally
denote 500 MITBB$ for you. |
|
s*****g 发帖数: 5159 | 20 If you can save your xls as a csv, write a shell script and make that happen.
Someone write a csv2tabular with reasonable parameter set, I personally
denote 500 MITBB$ for you. |
|
q*****g 发帖数: 1568 | 21 虽然经历了那么多的进化过程,人类作为一个物种的种间距离却是惊人的小。而且
目前人类正处在一个种间距离继续缩小而不是扩大的过程当中。
然而我们这个物种却最热衷于划分种间的不同集团,比如说种族,阶级等等。
简单点说,我们现在说的种族几乎不可能成为一个科学的概念。标准的race的定义
是这样的:a race denotes a large, geographically isolated population
within a species that has had little or no gene flow with other
populations for a long time.
目前的黄种人,白种人黑种人等跨种族的杂交是一点问题都没有的,所以其实从学
术的角度讲干脆不用race这个词完全没有问题。事实上很多现代人类学家就大力提
倡把这个词从人类学教课书里整个去掉,而以population来指代特定的人群。这个
population的定义比race简单的多,它只是:any group of people whose
members interbreed and who exhib |
|
f********n 发帖数: 6465 | 22 这个排名分先后吗?
Schools that consistently rank in the top 14
The "Top Fourteen" schools according to US News and World Report Rankings
are (in alphabetical order, ignoring terms denoting the type of school, such
as "University"):[19]
University of California, Berkeley School of Law, University of California,
Berkeley, in Berkeley, CA.
University of Chicago Law School, University of Chicago, in Chicago, IL.
Columbia Law School, Columbia University, in New York, NY.
Cornell Law School, Cornell Universit |
|
O******e 发帖数: 4845 | 23 Try to use "Tg" to denote transgenes. |
|
x********u 发帖数: 430 | 24 I have constructed several gene circuits and got some unpredictable data (
Please open the link for the attached figure)
P: inducible promoter
P': constitutive promoter
X1 and X2: protein binding site (which will affect the expression level of
eGFP when the regulator protein binds them)
R1 and R2: putative regulator protein for sequence X1 and X2, respectively
eGFP: enhanced green fluorescence protein/reporter gene
A broad range of inducer concentration which known to bind effector R1 and
abolis... 阅读全帖 |
|
m******5 发帖数: 1383 | 25 oh, that sucks, did you try to purchase the same antibody from other
companies? I was under the impression that the paper I attached actually
gave very specific result at the end denoting that the element they
identified can actually function in a developmental regulated manner.
also I strongly suggest you to change the title of your post to a more
specific one
ChiP- |
|
x******0 发帖数: 1490 | 26 【 以下文字转载自 Statistics 讨论区 】
发信人: xzxz0000 (凶涨凶涨), 信区: Statistics
标 题: R 编程面试题,被弄残废了,在这里求解,钱不多,但会鼎力散财,
发信站: BBS 未名空间站 (Sat Apr 14 20:21:09 2012, 美东)
面试了一个software职位,本以为很有戏,但考我的题基本上全是job description上
没有的R 编程,希望这里的大侠帮助解惑答疑,在下感恩不尽。
1)
An analytical technique used in a molecular biology lab involves dispensing
solutions of DNA in very
low concentration into 384-well plates. Consider the perfectly random
distribution of N=30 molecules
onto this device
a) What is the probability that two molecules fall... 阅读全帖 |
|
l**********1 发帖数: 5204 | 27 Mark!
Good said.
plus
整个领域正在期待类似热力学定律的新理论诞生
1967 that theory Dissipative structures in chemical systems
already published.
>The deterministic chaos is a complex order typical of dissipative systems (Prigogine, 1967)
which is denoted by several qualitative characteristics such as non-linearity, sensitive
dependence on initial conditions, unpredictability and uncertainty.
from
Prigogine I. (1967) Dissipative structures in chemical systems. In: Fast reactions and primary processes in
chemical kinet... 阅读全帖 |
|
l**********1 发帖数: 5204 | 28 Bingo
suppl:
Boehm AM et al. (2007)
Precise protein quantification based on peptide quantification using
iTRAQ^@TM
BMC Bioinformatics. 8:214.
its Fig. 2
The normal-probability-plot shows that a lognormal distribution
fits the peptide ratio data. The transformed experimental
data is plotted and lies on a line, so the data is nearly
normally distributed. The x-axis denotes the inverse function
of the normality and the y-axis represents the sorted logtransformed
values.
//www.ncbi.nlm.nih.gov/pub... 阅读全帖 |
|
m******5 发帖数: 1383 | 29 Did anyone here used plasmid or cDNA clones from OriGene?
is their product reliable?
Moreover, in many of their plasmid they denote the plasmid are not
replicable by regular DNA purification method, is this possible? Looks to me
they are just trying to get customers to buy the plasmid from them instead
of purifying the plasmid indefinitely in their own bench
I attached their 'explanation below'
;Due to the inherent nature of this plasmid, standard methods to replicate
additional amounts of DNA ... 阅读全帖 |
|
l**d 发帖数: 472 | 30 There have been and there will be a lot of "first time" for you.
As you said, this is the first time you "heard." There are a lot of things
you have not "heard." People may just not talk about it.
Also, I don't think the word "inorganic food" is correct. "Inorganic" means
"not consisting of or deriving from living matter" or "of, relating to, or
denoting compounds that are not organic (broadly, compounds not containing
carbon)." Most foods, if not all, are not inorganic. |
|
c*******e 发帖数: 150 | 31 do these denote Journal of Financial and Quantitative Analysis, and Journal
of Business?
Thanks for the information, Diadora~~
top |
|
y*****a 发帖数: 580 | 32 2. Z=(6+4i)*(2+3i)/13 |z| = |(6+4i)*(2+3i)|/13=|26i|/13=2
3. may have bug for the color, i.e., 3 white and 1 black. If this is the case, then P=3/C42=3/6=50%.
4. No fig.
22. Let us denote A as Tier 1 for Item Jia and B for Tier2 for Item Jia, C
as Tier1 for Item Yi and D as Tier2 for Item Yi.
(1) Results can have AC, AD, BC, BD four cases.
AC has possibility of .8*.9 = 0.72 with profit of 10 w yuan.
BC has possibility of .2*.9=0.18 with profit of 5w yuan
AD has possibility of .8*.1=0.08 with |
|
h*********y 发帖数: 1 | 33 My solution:
let h1 = a ^ (L1/x1), h2 = a ^ (L2/x2), then according to (3) and (4),
h1 = -v1 / [v2*p1*log(a)], (7)
h2 = -v1 / [v2*p2*log(a)], (8)
and
h1/h2 = p2/p1.
We denote h1 and h2 as formulas (7) and (8), then we get
L1/x1 = log(h1) / log(a), (9)
L2/x2 = log(h2) / log(a) (10)
and through (5) we get
L1 + L2 = L, (11)
and through (6) we get
p1*h1 * x1 + p2*h2 * x2 = E (12)
Now we change the form of the 4 formulas:
L |
|
m******d 发帖数: 3 | 34 Let the point be (x, y).
Line up the vertices(DingDian) as (x1, y1), (x2, y2), ..., (xn, yn).
Calculate
ci=det(matrix
x y 1
xi yi 1
x(i1) y(i+1) 1
)
for i=0, 1, ..., n-1. Of course, denote (x0, y0) = (xn, yn).
If all the ci's are positive, or all are negative, the point is
in the polygon. Otherwise, i.e., some positive and some negative,
the point is not in the polygon.
坐标, |
|
j*******r 发帖数: 1 | 35 Hi,
Does anyone have any idea to prove the following inequality :
Assuming a, b, c and q are real numbers satisfying :
1) a>=1, b>=1 , c>=1 , q>=1
2) abs(a-b)
where abs() denotes absolute values.
3) q>=2
Prove:
abs(a^q-b^q)
where ^ stands for power and q is the exponent.
Any suggestions and comments are very welcome.
Thanks.
Min |
|
g*****a 发帖数: 340 | 36 if that is a figure, open it, there is a tool in the toolbar which you can
use to denote the value on the spot where you click
or
if it's a image, jpeg, bmp, such kind, use ruler.... |
|
c*******h 发帖数: 1096 | 37 what is the fourier transform (and inverse transform) of 1/|x|^a,
where x is a d-dimensional vector, |x| denotes the euclidean norm,
and a is any real number?
any references would be appreciated |
|
q********y 发帖数: 20 | 38 One dimension damped wave equation on the rod with length L
u_tt = c^2 u_xx - a u_t + g (u(x,t) denote the displacement)
the boundary condition is
u(x,t)=S(t) | x=0
u_t(x,t) = F(t) | x=0
I want calculate the other end u(L,t) and u_t(L,t)
How can I solve the boundary value problem |
|
J**Y 发帖数: 34 | 39 We can have more compact way to think about this. Suppose f(X) is an
unbiased estimator of odds ratio, where X=(x1,....,xn). Then
E[f(X)]=Sum_k[f(k)*C_nk*p^k*(1-p)^n-k], where C_nk is the combination
symbol. Because f(k)*C_nk is constant, let a_k denote it. Then
E[f(X)]=Sum_k[a_k*p^k*(1-p)^n-k]=p/1-p =>
Sum_k[a_k*p^k*(1-p)^n-k+1]=p, you then can show the equation
doesn't exist. |
|
G****n 发帖数: 145 | 40 100+ for Cai Hongbin
State corroding federalismkuleuven.ac.be 中的 [PDF]
Carnegie Mellon FulltextH Cai… - Journal of Public Economics, 2004 -
Elsevier
... a Department of Economics, University of California, Los Angeles, CA,
USA. ... a L b , where A>0,
a>0, b>0, 1−a−b>0. There is a fixed amount of capital in the
economy, denoted by ... Specifically,
if the official tax rate is t, an enterprise pays an effective tax rate of (
1−h)t, where h is the ...
被引用次数:145 - 相关文章 - 所有 18 个版本
... 阅读全帖 |
|
w****r 发帖数: 748 | 41 Simply, Y=C+I+NX, where Y is output (GDP), C denotes consumption, I is
investment, and NX is net export. In China, investment accounts for more
than 50% of GDP, which is unsustainable. |
|
a*****g 发帖数: 19398 | 42 The 21st century learning skills are often called the 4 C's: critical
thinking, creative thinking, communicating, and collaborating. These skills
help students learn, and so they are vital to success in school and beyond.
See videos of each main area below at the website - https://k12.
thoughtfullearning.com/FAQ/what-are-learning-skills
Critical Thinking
Critical thinking is focused, careful analysis of something to better
understand it. When people speak of "left brain" activity, they are usual... 阅读全帖 |
|