13 QStringList& a_models,
14 QList< double >& a_udpars )
20 setAttribute ( Qt::WA_DeleteOnClose );
21 setWindowTitle( tr(
"Model Selection - UltraScan Analysis" ) );
23 setMinimumSize( 400, 300 );
26 QVBoxLayout*
main =
new QVBoxLayout(
this );
27 main->setContentsMargins( 2, 2, 2, 2 );
28 main->setSpacing ( 2 );
32 models <<
"1-Component, Ideal"
33 <<
"2-Component, Ideal, Noninteracting"
34 <<
"3-Component, Ideal, Noninteracting"
35 <<
"Fixed Molecular Weight Distribution"
36 <<
"Monomer-Dimer Equilibrium"
37 <<
"Monomer-Trimer Equilibrium"
38 <<
"Monomer-Tetramer Equilibrium"
39 <<
"Monomer-Pentamer Equilibrium"
40 <<
"Monomer-Hexamer Equilibrium"
41 <<
"Monomer-Heptamer Equilibrium"
42 <<
"User-Defined Monomer-Nmer Equilibrium"
43 <<
"Monomer-Dimer-Trimer Equilibrium"
44 <<
"Monomer-Dimer-Tetramer Equilibrium"
45 <<
"User-Defined Monomer - N-mer - M-mer Equilibrium"
46 <<
"2-Component Hetero-Association: A + B <=> AB"
47 <<
"User-Defined self/Hetero-Association: A + B <=> AB, nA <=> An"
48 <<
"User-Defined Monomer-Nmer, some monomer is incompetent"
49 <<
"User-Defined Monomer-Nmer, some Nmer is incompetent"
50 <<
"User-Defined irreversible Monomer-Nmer"
51 <<
"User-Defined Monomer-Nmer plus contaminant";
54 QLabel* lb_mbanner =
us_banner( tr(
"Please Select a Model:" ) );
55 main->addWidget( lb_mbanner );
60 for (
int ii = 0; ii <
models.size(); ii++ )
67 QHBoxLayout* buttons =
new QHBoxLayout;
70 connect( pb_help, SIGNAL( clicked() ), SLOT(
help() ) );
71 buttons->addWidget( pb_help );
74 connect( pb_cancel, SIGNAL( clicked() ), SLOT(
cancelled() ) );
75 buttons->addWidget( pb_cancel );
77 QPushButton* pb_select =
us_pushbutton( tr(
"Select Model" ) );
78 connect( pb_select, SIGNAL( clicked() ), SLOT(
selected() ) );
79 buttons->addWidget( pb_select );
81 main->addLayout( buttons );
105 QMessageBox::information(
this,
106 tr(
"No Data Selected" ),
107 tr(
"You have not selected any data.\nSelect Model or Cancel" ) );
196 QString msg = tr(
"Fitting to Function:\n\n" ) + fequ + fcmp;
199 msg = msg + tr(
"\n* indicates that this parameter can be floated.\n" );
204 tr(
"\n** Equilibrium Constants are calculated in log of"
205 " molar units;\n conversion to concentration is performed in"
206 " the Model Control Windows.\n" );
210 tr(
"\n*** vbar_AB = ( vbar_A * M_A + vbar_B * M_B )"
211 " / ( M_A + M_B )\n" );
224 QString msg = QString(
"C(X) = " );
230 msg = msg +
"exp[ (ln(A) + M * omega^2 * (1 - vbar * D)"
231 +
" * (X^2 - Xr^2)) / (2 * R * T) ] + B";
232 comps <<
"X" <<
"Xr" <<
"Aa" <<
"M" <<
"E" <<
"D" <<
"R" <<
"T"
236 msg = msg +
"exp[ ln(A[1]) + M[1] * omega^2 * (1 - vbar[1] * D)"
237 +
" * (X^2 - Xr^2) / (2 * R * T) ]\n"
238 +
" + exp[ (ln(A[2]) + M[2] * omega^2 * (1 - vbar[2] * D) * "
239 +
"(X^2 - Xr ^2) / (2 * R * T) ] + B";
240 comps <<
"X" <<
"Xr" <<
"Aa" <<
"M" <<
"D" <<
"R" <<
"T" <<
"B";
243 msg = msg +
"exp[ ln(A[1]) + M[1] * omega^2 * (1 - vbar[1] * D)"
244 +
" * (X^2 - Xr^2) / (2 * R * T) ]\n"
245 +
" + exp[ (ln(A[2]) + M[2] * omega^2 * (1 - vbar[2] * D) * "
246 +
"(X^2 - Xr^2) / (2 * R * T) ]\n"
247 +
" + exp[ (ln(A[3]) + M[3] * omega^2 * (1 - vbar[3] * D) * "
248 +
"(X^2 - Xr^2) / (2 * R * T) ] + B";
249 comps <<
"X" <<
"Xr" <<
"Aa" <<
"M" <<
"D" <<
"R" <<
"T" <<
"B";
252 msg = msg +
"A[i] * SUM[ exp[ M[i] * omega^2 * (1 - vbar[i] * D)"
253 +
" * (X^2 - Xr^2) / (2 * R * T) ] ] + B\n";
254 comps <<
"X" <<
"Xr" <<
"Ai" <<
"Mi" <<
"D" <<
"R" <<
"T" <<
"B";
257 msg = msg +
"exp[ (ln(A) + M * omega^2 * (1 - vbar * D)"
258 +
" * (X^2 - Xr^2)) / (2 * R * T) ]\n"
259 +
" + exp[ (2 * (ln(A) + ln(2/(E*L)) + ln(K1,2) + 2 * M * omega^2"
260 +
" * (1 - vbar * D) * (X^2 - Xr^2)) / (2 * R * T) ] + B";
261 comps <<
"X" <<
"Xr" <<
"Aa" <<
"E" <<
"L" <<
"K1" <<
"M" <<
"D"
262 <<
"R" <<
"T" <<
"B";
265 msg = msg +
"exp[ (ln(A) + M * omega^2 * (1 - vbar * D)"
266 +
" * (X^2 - Xr^2)) / (2 * R * T) ]\n"
267 +
" + exp[ (3 * (ln(A) + ln(3/(E*L)^2) + ln(K1,3) + 3 * M *"
268 +
" omega^2 * (1 - vbar * D) * (X^2 - Xr^2)) / (2 * R * T) ] + B";
269 comps <<
"X" <<
"Xr" <<
"Aa" <<
"E" <<
"L" <<
"K1" <<
"M" <<
"D"
270 <<
"R" <<
"T" <<
"B";
273 msg = msg +
"exp[ (ln(A) + M * omega^2 * (1 - vbar * D)"
274 +
" * (X^2 - Xr^2)) / (2 * R * T) ]\n"
275 +
" + exp[ (4 * (ln(A) + ln(4/(E*L)^3) + ln(K1,4) + 4 * M *"
276 +
" omega^2 * (1 - vbar * D) * (X^2 - Xr^2)) / (2 * R * T) ] + B";
277 comps <<
"X" <<
"Xr" <<
"Aa" <<
"E" <<
"L" <<
"K1" <<
"M" <<
"D"
278 <<
"R" <<
"T" <<
"B";
281 msg = msg +
"exp[ (ln(A) + M * omega^2 * (1 - vbar * D)"
282 +
" * (X^2 - Xr^2)) / (2 * R * T) ]\n"
283 +
" + exp[ (5 * (ln(A) + ln(5/(E*L)^4) + ln(K1,5) + 5 * M *"
284 +
" omega^2 * (1 - vbar * D) * (X^2 - Xr^2)) / (2 * R * T) ] + B";
285 comps <<
"X" <<
"Xr" <<
"Aa" <<
"E" <<
"L" <<
"K1" <<
"M" <<
"D"
286 <<
"R" <<
"T" <<
"B";
289 msg = msg +
"exp[ (ln(A) + M * omega^2 * (1 - vbar * D)"
290 +
" * (X^2 - Xr^2)) / (2 * R * T) ]\n"
291 +
" + exp[ (6 * (ln(A) + ln(6/(E*L)^5) + ln(K1,6) + 6 * M *"
292 +
" omega^2 * (1 - vbar * D) * (X^2 - Xr^2)) / (2 * R * T) ] + B";
293 comps <<
"X" <<
"Xr" <<
"Aa" <<
"E" <<
"L" <<
"K1" <<
"M" <<
"D"
294 <<
"R" <<
"T" <<
"B";
297 msg = msg +
"exp[ (ln(A) + M * omega^2 * (1 - vbar * D)"
298 +
" * (X^2 - Xr^2)) / (2 * R * T) ]\n"
299 +
" + exp[ (7 * (ln(A) + ln(7/(E*L)^6) + ln(K1,7) + 7 * M *"
300 +
" omega^2 * (1 - vbar * D) * (X^2 - Xr^2)) / (2 * R * T) ] + B";
301 comps <<
"X" <<
"Xr" <<
"Aa" <<
"E" <<
"L" <<
"K1" <<
"M" <<
"D"
302 <<
"R" <<
"T" <<
"B";
305 msg = msg +
"exp[ (ln(A) + M * omega^2 * (1 - vbar * D)"
306 +
" * (X^2 - Xr^2)) / (2 * R * T) ]\n"
307 +
" + exp[ (N * ln(A) + ln(N/(E*L)^(N-1)) + ln(K1,N) + N * M *"
308 +
" omega^2 * (1 - vbar * D) * (X^2 - Xr^2)) / (2 * R * T) ] + B";
309 comps <<
"X" <<
"Xr" <<
"Aa" <<
"E" <<
"L" <<
"K1" <<
"N" <<
"M"
310 <<
"D" <<
"R" <<
"T" <<
"B";
313 msg = msg +
"exp[ (ln(A) + M * omega^2 * (1 - vbar * D)"
314 +
" * (X^2 - Xr^2)) / (2 * R * T) ]\n"
315 +
" + exp[ (2 * (ln(A) + ln(2/(E*L)) + ln(K1,2) + 2 * M * omega^2"
316 +
" * (1 - vbar * D) * (X^2 - Xr^2)) / (2 * R * T) ]\n"
317 +
" + exp[ (3 * (ln(A) + ln(3/(E*L)^2) + ln(K1,3) + 3 * M *"
318 +
" omega^2 * (1 - vbar * D) * (X^2 - Xr^2)) / (2 * R * T) ] + B";
319 comps <<
"X" <<
"Xr" <<
"Aa" <<
"E" <<
"L" <<
"K1" <<
"M" <<
"D"
320 <<
"R" <<
"T" <<
"B";
323 msg = msg +
"exp[ (ln(A) + M * omega^2 * (1 - vbar * D)"
324 +
" * (X^2 - Xr^2)) / (2 * R * T) ]\n"
325 +
" + exp[ (2 * (ln(A) + ln(2/(E*L)) + ln(K1,2) + 2 * M * omega^2"
326 +
" * (1 - vbar * D) * (X^2 - Xr^2)) / (2 * R * T) ]\n"
327 +
" + exp[ (4 * (ln(A) + ln(4/(E*L)^3) + ln(K1,4) + 4 * M *"
328 +
" omega^2 * (1 - vbar * D) * (X^2 - Xr^2)) / (2 * R * T) ] + B";
329 comps <<
"X" <<
"Xr" <<
"Aa" <<
"E" <<
"L" <<
"K1" <<
"M" <<
"D"
330 <<
"R" <<
"T" <<
"B";
333 msg = msg +
"exp[ (ln(A) + M * omega^2 * (1 - vbar * D)"
334 +
" * (X^2 - Xr^2)) / (2 * R * T) ]\n"
335 +
" + exp[ (N1 * (ln(A) + ln(N1/(E*L)^(N1 - 1)) + ln(K1,N1) + N1 *"
336 +
" M * omega^2 * (1 - vbar * D) * (X^2 - Xr^2)) / (2 * R * T) ]\n"
337 +
" + exp[ (N2 * (ln(A) + ln(N2/(E*L)^(N2 - 1)) + ln(K1,N2) + N2 *"
338 +
" M * omega^2 * (1 - vbar * D) * (X^2 - Xr^2)) / (2 * R * T) ] + B";
339 comps <<
"X" <<
"Xr" <<
"Aa" <<
"E" <<
"L" <<
"N1" <<
"N2" <<
"K1"
340 <<
"M" <<
"D" <<
"R" <<
"T" <<
"B";
343 msg = msg +
"exp[ (ln(A) + M_A * omega^2 * (1 - vbar_A * D)"
344 +
" * (X^2 - Xr^2)) / (2 * R * T) ]\n"
345 +
" + exp[ (ln(B) + M_B * omega^2 * (1 - vbar_B * D) *"
346 +
" (X^2 - Xr^2)) / (2 * R * T) ]\n"
347 +
" + exp[ (ln(A) + ln(B) + ln(K_AB) + ln(E_AB/(E_A * E_B * L))"
348 +
" + (M_A + M_B) * omega^2 * (1 - vbar_AB * D) * (X^2 - Xr^2)) /"
349 +
" (2 * R * T) ] + B";
350 comps <<
"X" <<
"Xr" <<
"Aa" <<
"Ab" <<
"E" <<
"L" <<
"KC" <<
"MA"
351 <<
"MB" <<
"MC" <<
"D" <<
"R" <<
"T" <<
"B";
354 msg = msg +
"exp[ (ln(A) + M_A * omega^2 * (1 - vbar_A * D)"
355 +
" * (X^2 - Xr^2)) / (2 * R * T) ]\n"
356 +
" + exp[ (ln(B) + M_B * omega^2 * (1 - vbar_B * D) *"
357 +
" (X^2 - Xr^2)) / (2 * R * T) ]\n"
358 +
" + exp[ (ln(A) + ln(B) + ln(K_AB) + ln(E_AB/(E_A * E_B * L))"
359 +
" + (M_A + M_B) * omega^2 * (1 - vbar_AB * D) * (X^2 - Xr^2)) /"
361 +
" + exp[ (N *ln(A) + ln(N/(E*L)^(N-1)) + ln(K1,N) + N * M_A"
362 +
" * omega^2 * (1 - vbar_A * D) * (X^2 - Xr^2)) /"
363 +
" (2 * R * T) ] + B";
364 comps <<
"X" <<
"Xr" <<
"Aa" <<
"Ab" <<
"E" <<
"L" <<
"KC" <<
"KN"
365 <<
"MA" <<
"MB" <<
"MC" <<
"VA" <<
"VB" <<
"VC"
366 <<
"D" <<
"R" <<
"T" <<
"B";
369 msg = msg +
"exp[ (ln(A1) + M * omega^2 * (1 - vbar * D)"
370 +
" * (X^2 - Xr^2)) / (2 * R * T) ]\n"
371 +
" + exp[ (N * ln(A1) + ln(N/(E * L)^(N - 1) + ln(K1,N) +"
372 +
" N * M * omega^2 * (1 - vbar * D) * (X^2 - Xr^2)) /"
374 +
" + exp[ (ln(A2) + M * omega^2 * (1 - vbar * D) *"
375 +
" (X^2 - Xr^2)) / (2 * R * T) ] + B";
376 comps <<
"N" <<
"X" <<
"Xr" <<
"Aa" <<
"E" <<
"L" <<
"K1"
377 <<
"M" <<
"A1" <<
"A2" <<
"D" <<
"R" <<
"T" <<
"B";
380 msg = msg +
"exp[ (ln(A1) + M * omega^2 * (1 - vbar * D)"
381 +
" * (X^2 - Xr^2)) / (2 * R * T) ]\n"
382 +
" + exp[ (N * ln(A1) + ln(N/(E * L)^(N - 1) + ln(K1,N) +"
383 +
" N * M * omega^2 * (1 - vbar * D) * (X^2 - Xr^2)) /"
385 +
" + exp[ (ln(A2) + N * M * omega^2 * (1 - vbar * D) *"
386 +
" (X^2 - Xr^2)) / (2 * R * T) ] + B";
387 comps <<
"N" <<
"X" <<
"Xr" <<
"Aa" <<
"E" <<
"L" <<
"K1"
388 <<
"M" <<
"A1" <<
"A2" <<
"D" <<
"R" <<
"T" <<
"B";
391 msg = msg +
"exp[ (ln(A1) + M * omega^2 * (1 - vbar * D)"
392 +
" * (X^2 - Xr^2)) / (2 * R * T) ]\n"
393 +
" + exp[ (N * ln(A1) + ln(N/(E * L)^(N - 1) + ln(K1,N) +"
394 +
" N * M * omega^2 * (1 - vbar * D) * (X^2 - Xr^2)) /"
396 +
" + exp[ (ln(A2) + M * omega^2 * (1 - vbar * D) *"
397 +
" (X^2 - Xr^2)) / (2 * R * T) ]\n"
398 +
" + exp[ (ln(A3) + N * M * omega^2 * (1 - vbar * D) *"
399 +
" (X^2 - Xr^2)) / (2 * R * T) ] + B";
400 comps <<
"N" <<
"X" <<
"Xr" <<
"Aa" <<
"E" <<
"L" <<
"K1"
401 <<
"M" <<
"A1" <<
"A2" <<
"A3" <<
"D" <<
"R" <<
"T" <<
"B";
404 msg = msg +
"exp[ (ln(A1) + M1 * omega^2 * (1 - vbar[1] * D)"
405 +
" * (X^2 - Xr^2)) / (2 * R * T) ]\n"
406 +
" + exp[ (N * ln(A1) + ln(N/(E * L)^(N - 1) + ln(K1,N) +"
407 +
" N * M * omega^2 * (1 - vbar[1] * D) * (X^2 - Xr^2)) /"
409 +
" + exp[ (ln(A2) + M2 * omega^2 * (1 - vbar[2] * D) *"
410 +
" (X^2 - Xr^2)) / (2 * R * T) ] + B";
411 comps <<
"N" <<
"X" <<
"Xr" <<
"Aa" <<
"E" <<
"L" <<
"K1"
412 <<
"M1" <<
"M2" <<
"A1" <<
"A2" <<
"D" <<
"R" <<
"T" <<
"B";
425 QString ms = tr(
"\n\nwhere:\n" );
428 if ( comps.contains(
"X" ) ) ms = ms +
"\t"
429 + tr(
"X = Radius\n" );
430 if ( comps.contains(
"Xr" ) ) ms = ms +
"\t"
431 + tr(
"Xr = Reference Radius\n" );
432 if ( comps.contains(
"Aa" ) ) ms = ms +
"\t"
433 + tr(
"A = Amplitude of component A *\n" );
434 if ( comps.contains(
"Ab" ) ) ms = ms +
"\t"
435 + tr(
"B = Amplitude of component B *\n" );
436 if ( comps.contains(
"N" ) ) ms = ms +
"\t"
437 + tr(
"N = User-Defined Association State\n" );
438 if ( comps.contains(
"M" ) ) ms = ms +
"\t"
439 + tr(
"M = Molecular Weight *\n" );
440 if ( comps.contains(
"E" ) ) ms = ms +
"\t"
441 + tr(
"E = Extinction Coefficient\n" );
442 if ( comps.contains(
"L" ) ) ms = ms +
"\t"
443 + tr(
"L = Pathlength\n" );
444 if ( comps.contains(
"Ai" ) ) ms = ms +
"\t"
445 + tr(
"A[i] = Amplitude of component \"i\" *\n" );
446 if ( comps.contains(
"Mi" ) ) ms = ms +
"\t"
447 + tr(
"M[i] = Molecular Weight of component \"i\" *\n" );
448 if ( comps.contains(
"N1" ) ) ms = ms +
"\t"
449 + tr(
"N1 = Stoichiometry of first Association\n" );
450 if ( comps.contains(
"N2" ) ) ms = ms +
"\t"
451 + tr(
"N2 = Stoichiometry of second Association\n" );
452 if ( comps.contains(
"K1" ) ) ms = ms +
"\t"
453 + tr(
"K1 = Monomer-Dimer Equilibrium Constant *,**\n" );
454 if ( comps.contains(
"KB" ) ) ms = ms +
"\t"
455 + tr(
"K_AB = AB Equilibrium Constant *,**\n" );
456 if ( comps.contains(
"KN" ) ) ms = ms +
"\t"
457 + tr(
"K_AN = A monomer-nmer Equilibrium Constant *,**\n" );
458 if ( comps.contains(
"MA" ) ) ms = ms +
"\t"
459 + tr(
"M_A = Molecular Weight of A *\n" );
460 if ( comps.contains(
"MB" ) ) ms = ms +
"\t"
461 + tr(
"M_B = Molecular Weight of B *\n" );
462 if ( comps.contains(
"MC" ) ) ms = ms +
"\t"
463 + tr(
"M_AB = Molecular Weight of AB\n" );
464 if ( comps.contains(
"M1" ) ) ms = ms +
"\t"
465 + tr(
"M1 = Monomer Molecular Weight *\n" );
466 if ( comps.contains(
"M2" ) ) ms = ms +
"\t"
467 + tr(
"M2 = Contaminant Molecular Weight *\n" );
468 if ( comps.contains(
"VA" ) ) ms = ms +
"\t"
469 + tr(
"vbar_A = vbar of A *\n" );
470 if ( comps.contains(
"VB" ) ) ms = ms +
"\t"
471 + tr(
"vbar_B = vbar of B *\n" );
472 if ( comps.contains(
"VC" ) ) ms = ms +
"\t"
473 + tr(
"vbar_AB = vbar of AB\n" );
474 if ( comps.contains(
"D" ) ) ms = ms +
"\t"
475 + tr(
"D = Density Coefficient\n" );
476 if ( comps.contains(
"R" ) ) ms = ms +
"\t"
477 + tr(
"R = Gas Constant\n" );
478 if ( comps.contains(
"T" ) ) ms = ms +
"\t"
479 + tr(
"T = Temperature\n" );
480 if ( comps.contains(
"A1" ) ) ms = ms +
"\t"
481 + tr(
"A1 = Reference Concentration of monomer *\n" );
482 if ( comps.contains(
"A2" ) ) ms = ms +
"\t"
483 + tr(
"A2 = Reference Concentration of incompetent monomer *\n" );
484 if ( comps.contains(
"A3" ) ) ms = ms +
"\t"
485 + tr(
"A3 = Reference Concentration of incompetent N-mer *\n" );
486 if ( comps.contains(
"B" ) ) ms = ms +
"\t"
487 + tr(
"B = Baseline *\n" );
492 if ( ms.contains(
"**\n" ) )
493 notef = ms.contains(
"***\n" ) ? 3 : 2;