General Purpose Geodetic Library
vgosDbCalcSupport.cpp
Go to the documentation of this file.
1 /*
2  * This file is a part of vgosDbCalc. vgosDbCalc is a part of CALC/SOLVE
3  * system and is designed to calculate theoretical values and store them
4  * in the vgosDb format.
5  * Copyright (C) 2016-2020 Sergei Bolotin.
6  *
7  * This program is free software: you can redistribute it and/or modify
8  * it under the terms of the GNU General Public License as published by
9  * the Free Software Foundation, either version 3 of the License, or
10  * (at your option) any later version.
11  *
12  * This program is distributed in the hope that it will be useful,
13  * but WITHOUT ANY WARRANTY; without even the implied warranty of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15  * GNU General Public License for more details.
16  *
17  * You should have received a copy of the GNU General Public License
18  * along with this program. If not, see <http://www.gnu.org/licenses/>.
19  *
20  */
21 
22 
23 #include <signal.h>
24 #include <string.h>
25 #include <unistd.h>
26 
27 
28 #include <QtCore/QCoreApplication>
29 #include <QtCore/QDir>
30 #include <QtCore/QFileInfo>
31 #include <QtCore/QSettings>
32 #include <QtCore/QString>
33 #include <QtCore/QStringList>
34 
35 #if QT_VERSION >= 0x050000
36 # include <QtWidgets/QApplication>
37 #else
38 # include <QtGui/QApplication>
39 #endif
40 
41 
42 
43 #include <SgIdentities.h>
44 #include <SgLogger.h>
45 #include <SgVgosDb.h>
46 #include <SgVlbiSession.h>
47 
48 
49 
50 #include "vgosDbCalc.h"
51 #include "VcCalc2SessionIfc.h"
52 
53 
54 
56 QString histIntroRec;
57 
58 
59 
60 
61 // stubs:
62 //
63 void kai_(short &kruc, UNUSED short &in, UNUSED short &iout, UNUSED short &istp,
64  char *lkynm_chr, short &iveri, char *lkout_chr,
65  UNUSED char *lfto_chr, short &ivero, UNUSED char *lfio_chr, short &kerr,
66  size_t len1, size_t len2, UNUSED size_t len3, UNUSED size_t len4)
67 {
68  QString inputDbName(QString::fromLatin1(lkynm_chr, len1));
69  QString outputDbName(QString::fromLatin1(lkout_chr, len2));
70 //QString inputDbDescriptor("TEMPLATE_LFIO_chr_TEMPLATE_LFIO_chr_TEMPLATE");
71 //QString outputDbDescriptor("TEMPLATE_LFTO_chr_TEMPLATE_LFTO_chr_TEMPLATE");
72 
73  if (inputDbName.at(0) == '$')
74  inputDbName = inputDbName.mid(1);
75 
76  c2s.mimic_Kai(kruc, inputDbName, iveri, outputDbName, ivero, kerr);
77 
78 /*
79  if (len3 < 256) // is it FORTRAN's bug?
80  qString2fortArray(outputDbDescriptor, lfto_chr, len3);
81  if (len4 < 256)
82  qString2fortArray(inputDbDescriptor, lfio_chr, len4);
83  if (len2 < 256)
84  qString2fortArray(outputDbName, lkout_chr, len2);
85 */
86 };
87 
88 
89 
90 //
91 void wridr_()
92 {
93 // std::cout << ".. wridr().\n";
94 };
95 
96 
97 
98 //
99 void ask_(const char *lcode, const short &ntoc, const short &dim1, const short &dim2,
100  const short &dim3, const short &nver, UNUSED const char* ltext_chr, UNUSED const short &ktype,
101  short &kerr, UNUSED size_t len1, UNUSED size_t len2)
102 {
103  if (fortArray2QString(lcode, 8) != "ROTEPOCH")
105  "ask_(): got a query on LCODE \"" + fortArray2QString(lcode, 8) + "\" (" +
106  QString("").setNum(dim1) + "," + QString("").setNum(dim2) + "," + QString("").setNum(dim3) +
107  ") of TOC=" + QString("").setNum(ntoc) + " and ver# " + QString("").setNum(nver));
108 
109  kerr = 1; // anyway: not found
110 };
111 
112 
113 
114 //
115 void mvrec_(short &ntoc, short &kmode, short &knum, short &kerr)
116 {
117  kerr = c2s.mimic_MvRec(ntoc, kmode, knum);
118 };
119 
120 
121 
122 //
123 void phist_(short &nhist, const char *lhist_chr, size_t len)
124 {
125  QString histString("");
126  if ((size_t)nhist < len)
127  histString = fortArray2QString(lhist_chr, len).left(nhist);
128  else
129  {
130  // try to workaround the CALC's bug:
131  histString = fortArray2QString(lhist_chr, len).trimmed();
132  if (histString.contains(histIntroRec))
133  histString = histIntroRec;
134  else
135  {
136  while (!histString.at(histString.size() - 1).isPrint())
137  histString.chop(1);
138  histString = histString.trimmed();
139  };
140  };
141  //
142  c2s.mimic_pHist(histString);
143 };
144 
145 
146 
147 //
148 void finis_(UNUSED short par)
149 {
150  c2s.mimic_Finis();
151 };
152 
153 
154 
155 //
156 void datsv_() {}; // just a stub
157 
158 
159 
160 //
161 //
162 // adds:
163 void adda_(const short& ntoc, const char *lcode, const char *descrText,
164  const short& dim1, const short& dim2, const short& dim3, size_t len1, size_t len2)
165 {
166  if (len1 < 8)
168  "adda_(): improper use of the function: len1 (" + QString("").setNum(len1) +
169  ") is less than 8 for the LCODE \"" + fortArray2QString(lcode, len1) + "\"");
170  if (len2 < 32)
172  "adda_(): improper use of the function: len2 (" + QString("").setNum(len2) +
173  ") is less than 32 for description of the LCODE \"" + fortArray2QString(lcode, len1) + "\"");
174  QString lCode(fortArray2QString(lcode, 8));
175  QString descr(fortArray2QString(descrText, 32));
176  c2s.mimicAddA(ntoc, lCode, descr, dim1, dim2, dim3);
177 };
178 
179 
180 
181 //
182 void addi_(const short& ntoc, const char *lcode, const char *descrText,
183  const short& dim1, const short& dim2, const short& dim3, size_t len1, size_t len2)
184 {
185  if (len1 < 8)
187  "addi_(): improper use of the function: len1 (" + QString("").setNum(len1) +
188  ") is less than 8 for the LCODE \"" + fortArray2QString(lcode, len1) + "\"");
189  if (len2 < 32)
191  "addi_(): improper use of the function: len2 (" + QString("").setNum(len2) +
192  ") is less than 32 for description of the LCODE \"" + fortArray2QString(lcode, len1) + "\"");
193  QString lCode(fortArray2QString(lcode, 8));
194  QString descr(fortArray2QString(descrText, 32));
195  c2s.mimicAddI(ntoc, lCode, descr, dim1, dim2, dim3);
196 };
197 
198 
199 
200 //
201 void addj_(const short& ntoc, const char *lcode, const char *descrText,
202  const short& dim1, const short& dim2, const short& dim3, size_t len1, size_t len2)
203 {
204  if (len1 < 8)
206  "addj_(): improper use of the function: len1 (" + QString("").setNum(len1) +
207  ") is less than 8 for the LCODE \"" + fortArray2QString(lcode, len1) + "\"");
208  if (len2 < 32)
210  "addj_(): improper use of the function: len2 (" + QString("").setNum(len2) +
211  ") is less than 32 for description of the LCODE \"" + fortArray2QString(lcode, len1) + "\"");
212  QString lCode(fortArray2QString(lcode, 8));
213  QString descr(fortArray2QString(descrText, 32));
214  c2s.mimicAddJ(ntoc, lCode, descr, dim1, dim2, dim3);
215 };
216 
217 
218 
219 //
220 void add4_(const short& ntoc, const char *lcode, const char *descrText,
221  const short& dim1, const short& dim2, const short& dim3, size_t len1, size_t len2)
222 {
223  if (len1 < 8)
225  "add4_(): improper use of the function: len1 (" + QString("").setNum(len1) +
226  ") is less than 8 for the LCODE \"" + fortArray2QString(lcode, len1) + "\"");
227  if (len2 < 32)
229  "add4_(): improper use of the function: len2 (" + QString("").setNum(len2) +
230  ") is less than 32 for description of the LCODE \"" + fortArray2QString(lcode, len1) + "\"");
231  QString lCode(fortArray2QString(lcode, 8));
232  QString descr(fortArray2QString(descrText, 32));
233  c2s.mimicAdd4(ntoc, lCode, descr, dim1, dim2, dim3);
234 };
235 
236 
237 
238 //
239 void addr_(const short& ntoc, const char *lcode, const char *descrText,
240  const short& dim1, const short& dim2, const short& dim3, size_t len1, size_t len2)
241 {
242  if (len1 < 8)
244  "addr_(): improper use of the function: len1 (" + QString("").setNum(len1) +
245  ") is less than 8 for the LCODE \"" + fortArray2QString(lcode, len1) + "\"");
246  if (len2 < 32)
248  "addr_(): improper use of the function: len2 (" + QString("").setNum(len2) +
249  ") is less than 32 for description of the LCODE \"" + fortArray2QString(lcode, len1) + "\"");
250  QString lCode(fortArray2QString(lcode, 8));
251  QString descr(fortArray2QString(descrText, 32));
252  c2s.mimicAddR(ntoc, lCode, descr, dim1, dim2, dim3);
253 };
254 
255 
256 
257 
258 //
259 //
260 // dels:
261 //
262 void dela_(const short& ntoc, const char *lcode, size_t len)
263 {
264  if (len < 8)
266  "dela_(): improper use of the function: len (" + QString("").setNum(len) +
267  ") is less than 8 for the LCODE \"" + fortArray2QString(lcode, len) + "\"");
268  QString lCode(fortArray2QString(lcode, 8));
269  c2s.mimicDelA(ntoc, lCode);
270 };
271 
272 
273 
274 //
275 void delr_(const short& ntoc, const char *lcode, size_t len)
276 {
277  if (len < 8)
279  "delr_(): improper use of the function: len (" + QString("").setNum(len) +
280  ") is less than 8 for the LCODE \"" + fortArray2QString(lcode, len) + "\"");
281  QString lCode(fortArray2QString(lcode, 8));
282  c2s.mimicDelR(ntoc, lCode);
283 };
284 
285 
286 
287 
288 //
289 //
290 // gets:
291 void geta_(const char *lcode, char values[], const short &dim1, const short &dim2, const short &dim3,
292  short numDims[], short &kerr, size_t len)
293 {
294  if (len < 8)
296  "geta_(): improper use of the function: len (" + QString("").setNum(len) +
297  ") is less than 8 for the LCODE \"" + fortArray2QString(lcode, len) + "\"");
298  QString lCode(fortArray2QString(lcode, 8));
299  kerr = c2s.mimicGetA(lCode, values, dim1, dim2, dim3, numDims);
300 // std::cout << " -------> getA returned:\n";
301 // QString str("");
302 // for (int j=0; j<numDims[1]; j++)
303 // for (int k=0; k<numDims[2]; k++)
304 // {
305 // str = fortArray2QString(values + 2*numDims[0]*j + 2*numDims[0]*numDims[0]*k, numDims[0]*2);
306 // std::cout << " " << j << ":" << k << " = \""
307 // << qPrintable(str) << "\"\n";
308 // };
309 };
310 
311 
312 //
313 void geti_(const char *lcode, short values[], const short &dim1, const short &dim2, const short &dim3,
314  short numDims[], short &kerr, size_t len)
315 {
316  if (len < 8)
318  "geti_(): improper use of the function: len (" + QString("").setNum(len) +
319  ") is less than 8 for the LCODE \"" + fortArray2QString(lcode, len) + "\"");
320  QString lCode(fortArray2QString(lcode, 8));
321  kerr = c2s.mimicGetI(lCode, values, dim1, dim2, dim3, numDims);
322 // std::cout << " -------> getI returned:\n";
323 // for (int i=0; i<numDims[0]; i++)
324 // for (int j=0; j<numDims[1]; j++)
325 // for (int k=0; k<numDims[2]; k++)
326 // std::cout << " " << i << ":" << j << ":" << k << " = "
327 // << values[i + numDims[0]*j + numDims[0]*numDims[1]*k] << "\n";
328 /*
329  std::cout << " ----\n ";
330  for (int i=0; i<dim1*dim2*dim3; i++)
331  std::cout << " (" << i << ")=" << value[i] << ", ";
332  std::cout << "\n";
333 */
334 };
335 
336 
337 
338 //extern "C" void getj_(char (&lcode)[14], int valu[], short *dim1, short *dim2, short *dim3,
339 // short numDims[], short &kerr, size_t len);
340 
341 void get4_(const char *lcode, double values[], const short &dim1, const short &dim2, const short &dim3,
342  short numDims[], short &kerr, size_t len)
343 {
344  if (len < 8)
346  "get4_(): improper use of the function: len (" + QString("").setNum(len) +
347  ") is less than 8 for the LCODE \"" + fortArray2QString(lcode, len) + "\"");
348  QString lCode(fortArray2QString(lcode, 8));
349  kerr = c2s.mimicGet4(lCode, values, dim1, dim2, dim3, numDims);
350 // std::cout << " -------> get4 returned:\n";
351 // for (int i=0; i<numDims[0]; i++)
352 // for (int j=0; j<numDims[1]; j++)
353 // for (int k=0; k<numDims[2]; k++)
354 // std::cout << " " << i << ":" << j << ":" << k << " = "
355 // << values[i + numDims[0]*j + numDims[0]*numDims[1]*k] << "\n";
356 };
357 
358 
359 
360 
361 
362 //
363 //
364 // puts:
365 //
366 void puta_(const char *lcode, const char vals[], const short &dim1, const short &dim2, const short &dim3,
367  size_t len)
368 {
369  if (len < 8)
371  "puta_(): improper use of the function: len (" + QString("").setNum(len) +
372  ") is less than 8 for the LCODE \"" + fortArray2QString(lcode, len) + "\"");
373  QString lCode(fortArray2QString(lcode, 8));
374  c2s.mimicPutA(lCode, vals, dim1, dim2, dim3);
375 };
376 
377 
378 
379 //
380 void puti_(const char *lcode, const short vals[],
381  const short &dim1, const short &dim2, const short &dim3, size_t len)
382 {
383  if (len < 8)
385  "puti_(): improper use of the function: len (" + QString("").setNum(len) +
386  ") is less than 8 for the LCODE \"" + fortArray2QString(lcode, len) + "\"");
387  QString lCode(fortArray2QString(lcode, 8));
388  c2s.mimicPutI(lCode, vals, dim1, dim2, dim3);
389 };
390 
391 
392 
393 //
394 void putr_(const char *lcode, const double vals[],
395  const short &dim1, const short &dim2, const short &dim3, size_t len)
396 {
397  if (len < 8)
399  "putr_(): improper use of the function: len (" + QString("").setNum(len) +
400  ") is less than 8 for the LCODE \"" + fortArray2QString(lcode, len) + "\"");
401  QString lCode(fortArray2QString(lcode, 8));
402  c2s.mimicPutR(lCode, vals, dim1, dim2, dim3);
403 };
404 
405 
406 
407 //
408 void put4_(const char *lcode, const double vals[],
409  const short &dim1, const short &dim2, const short &dim3, size_t len)
410 {
411  if (len < 8)
413  "put4_(): improper use of the function: len (" + QString("").setNum(len) +
414  ") is less than 8 for the LCODE \"" + fortArray2QString(lcode, len) + "\"");
415  QString lCode(fortArray2QString(lcode, 8));
416  c2s.mimicPut4(lCode, vals, dim1, dim2, dim3);
417 };
418 
419 
420 
421 
422 //
423 void puti_(UNUSED char (&lcode)[14], UNUSED short valu[], UNUSED short *dim1, UNUSED short *dim2,
424  UNUSED short *dim3, UNUSED size_t len)
425 {
426  std::cout << ".. puti().\n";
427 };
428 
429 
430 
431 
432 
433 //extern "C" void putj_(char (&lcode)[14], int vals[],
434 // short *dim1, short *dim2, short *dim3, size_t len);
435 
436 /*
437 void put4_(UNUSED char (&lcode)[14], UNUSED double vals[], UNUSED short *dim1, UNUSED short *dim2,
438  UNUSED short *dim3, UNUSED size_t len)
439 {
440  std::cout << ".. put4().\n";
441 };
442 
443 void putr_(UNUSED char (&lcode)[14], UNUSED double vals[],
444  UNUSED short *dim1, UNUSED short *dim2, UNUSED short *dim3, UNUSED size_t len)
445 {
446  std::cout << ".. putr().\n";
447 };
448 */
449 
450 
451 
452 //
453 // Aux:
454 //
455 short gethostname_(char *hostName, size_t len)
456 {
457  return gethostname(hostName, len);
458 };
459 
460 
461 
462 //
463 short trimlen_(char *chrs, size_t len)
464 {
465  short idx=len;
466  while (idx>0 && (chrs[idx-1] == ' ' || chrs[idx-1] == '\0'))
467  idx--;
468  return idx;
469 };
470 
471 
472 
473 //
474 void quit_calc_(UNUSED short iPar[])
475 {
477  {
479  "quit_calc_(): Quitting: legacy mode");
480  exit(0);
481  }
482  else
483  {
485  "quit_calc_(): Quitting: modern mode");
486  };
487 };
488 /*=====================================================================================================*/
489 
490 
491 
492 
493 
494 /*=====================================================================================================*/
495 // helpers:
496 QString fortArray2QString(const char *chrs, size_t len)
497 {
498  unsigned int l=strlen(chrs);
499  return QString::fromLatin1(chrs, l<len?l:len);
500  std::min(len, len);
501 };
502 
503 
504 
505 //
506 void qString2fortArray(const QString& str, char *chrs, size_t len)
507 {
508  // clear everythig:
509  memset(chrs, 0, len);
510 // strncpy(chrs, qPrintable(str), len-1);
511  strncpy(chrs, qPrintable(str), len);
512 };
513 /*=====================================================================================================*/
514 
515 
516 
517 
518 
519 /*=====================================================================================================*/
520 //
521 //
522 // CALC's main:
523 //
524 void mimicCalcMain(UNUSED int iArg1, int iArg2, const char* sArg3, const char* sArg4)
525 {
526  char sCalcOnName[128];
527  int kount, kend;
528  short iLuOut, iLu;
529 
530  memset(sCalcOnName, 0, sizeof(sCalcOnName));
531  memset(extrnl_.External_inputs, 0, sizeof(extrnl_.External_inputs));
532 
533  iLu = 6;
534  iLuOut = iArg2;
535 
536  if (sArg3 && strlen(sArg3)>0)
537  {
538  strcpy(sCalcOnName, sArg3);
539  std::cout << "CalcOn file name " << sCalcOnName << "\n";
540  };
541  if (sArg4 && strlen(sArg4)>0)
542  {
543  strcpy(extrnl_.External_inputs, sArg4);
544  extrnl_.External_aprioris = f_true;
545  std::cout << "External_inputs " << extrnl_.External_inputs << "\n";
546  };
547  //
548  // ok:
549  datsv_();
550  while (true)
551  {
552  start_(iLu, sCalcOnName, iLuOut, sizeof(sCalcOnName));
553  tocup_();
554  initl_(kount);
555 
556  while (true)
557  {
558  obsnt_(kount, kend);
559  if (kend == 1)
560  break;
561  drivr_();
562  wridr_();
563  };
564 
565  if (iLuOut != -1)
566  std::cout << " All data for this experiment has been processed.\n";
567  //
568  // for modern mode, return to calling function:
570  {
571  // just print some funny text:
572  start_(iLu, sCalcOnName, iLuOut, sizeof(sCalcOnName));
573  return;
574  };
575  //
576  };
577 };
578 
579 
580 
581 //
582 void mimicCalcMain2(UNUSED int iArg1, int iArg2, const char* sArg3, const char* sArg4,
583  const QList<QString>& bands)
584 {
585  char sCalcOnName[128];
586  int kount, kend;
587  short iLuOut, iLu;
588  kount = kend = 0;
589 
590  memset(sCalcOnName, 0, sizeof(sCalcOnName));
591  memset(extrnl_.External_inputs, 0, sizeof(extrnl_.External_inputs));
592 
593  iLu = 6;
594  iLuOut = iArg2;
595 
596  if (sArg3 && strlen(sArg3)>0)
597  {
598  strcpy(sCalcOnName, sArg3);
599  std::cout << "CalcOn file name " << sCalcOnName << "\n";
600  };
601  if (sArg4 && strlen(sArg4)>0)
602  {
603  strcpy(extrnl_.External_inputs, sArg4);
604  extrnl_.External_aprioris = f_true;
605  std::cout << "External_inputs " << extrnl_.External_inputs << "\n";
606  };
607  //
608  // ok:
609  c2s.setBandList(bands);
610  datsv_();
612  "mimicCalcMain2(): calling CALC's START");
613  start_(iLu, sCalcOnName, iLuOut, sizeof(sCalcOnName));
615  "mimicCalcMain2(): calling CALC's TOCUP");
616  tocup_();
617  // process for each band:
618  for (int i=0; i<bands.size(); i++)
619  {
620  const QString& bandKey=bands.at(i);
621  // the first band in the list is the primary band:
622  c2s.setCurrentBand(bandKey, i==0);
623 
625  "mimicCalcMain2(): processing " + bandKey + "-band has been started");
626 
627  initl_(kount);
628  while (true)
629  {
630  obsnt_(kount, kend);
631  if (kend == 1)
632  break;
633  drivr_();
634  wridr_();
635  };
637  "mimicCalcMain2(): processing " + bandKey + "-band has been finished");
638  c2s.rewind();
639  };
640  if (iLuOut != -1)
641  std::cout << " All data for this experiment has been processed.\n";
642  start_(iLu, sCalcOnName, iLuOut, sizeof(sCalcOnName));
643 };
644 /*=====================================================================================================*/
645 
646 
647 
648 
649 
650 
651 
652 /*
653 
654 Solve/CalcInfo.nc:
655  double RelativityMessage(Dim000001) ;
656  RelativityMessage:LCODE = "REL DATA" ;
657  RelativityMessage:CreateTime = "2015/09/14 11:30:01 " ;
658  RelativityMessage:Definition = "Relativity mod data (gamma)." ;
659 
660  char TheoryMessage(Char00079) ;
661  TheoryMessage:LCODE = "THE MESS" ;
662  TheoryMessage:CreateTime = "2015/09/14 15:14:16 " ;
663  TheoryMessage:Definition = "Theory module identification" ;
664 
665  char RelativityControl(Char00059) ;
666  RelativityControl:LCODE = "REL CFLG" ;
667  RelativityControl:CreateTime = "2015/09/14 15:14:16 " ;
668  RelativityControl:Definition = "Relativisitc bending use status" ;
669 
670 
671 
672 Solve/CalcERP.nc: ^
673  char CalcWobModule(Char00057) ; |
674  CalcWobModule:LCODE = "WOB MESS" ; ?????
675  CalcWobModule:CreateTime = "2015/09/14 15:14:16 " ;
676  CalcWobModule:Definition = "Wobble message definition." ;
677  char CalcUt1Module(Char00054) ;
678  CalcUt1Module:LCODE = "UT1 MESS" ; ?????
679  CalcUt1Module:CreateTime = "2015/09/14 15:14:16 " ;
680  CalcUt1Module:Definition = "UT1 Module message definition" ;
681 
682 
683 
684 
685 Solve/CalcInfo.nc: the lcodes are form dbedit(:-\‍), not calc:
686  double RelativityMessage(DimX000001) ;
687  RelativityMessage:CreateTime = "2016/12/23 14:57:53 UTC" ;
688  RelativityMessage:Definition = "Relativity mod data (gamma)." ;
689  RelativityMessage:LCODE = "REL DATA" ;
690  RelativityMessage:Size = 8 ;
691  double PrecessionData(DimX000001) ;
692  PrecessionData:CreateTime = "2016/12/23 14:57:53 UTC" ;
693  PrecessionData:Definition = "Precession constant (asec/cent)." ;
694  PrecessionData:LCODE = "PRE DATA" ;
695  PrecessionData:Size = 8 ;
696  double EarthTideData(DimX000003) ;
697  EarthTideData:CreateTime = "2016/12/23 14:57:53 UTC" ;
698  EarthTideData:Definition = "Earth tide module data (la. h l)" ;
699  EarthTideData:LCODE = "ETD DATA" ;
700  EarthTideData:Size = 24 ;
701 
702 
703 Solve/CalcInfo.nc: it is ot "info", move to CalcOceanLoading or something similar:
704  char OceanStationsFlag(Dim000005, Char00004) ;
705  OceanStationsFlag:LCODE = "OCE STAT" ;
706  OceanStationsFlag:CreateTime = "2015/09/14 15:14:16 " ;
707  OceanStationsFlag:Definition = "Ocean loading station status." ;
708  double OceanPoleTideCoef(Dim000005, Dim000006) ;
709  OceanPoleTideCoef:LCODE = "OPTLCOEF" ;
710  OceanPoleTideCoef:CreateTime = "2015/09/14 15:14:16 " ;
711  OceanPoleTideCoef:Definition = "Ocean Pole Tide loading Coefficients" ;
712  OceanPoleTideCoef:Units = "Radian" ;
713  ~~~~~~~~ <------ ?????
714  double OceanUpPhase(Dim000005, Dim000011) ;
715  OceanUpPhase:LCODE = "SITOCPHS" ;
716  OceanUpPhase:CreateTime = "2015/09/14 15:14:16 " ;
717  OceanUpPhase:Definition = "Vert ocean loading phases (rad)." ;
718  OceanUpPhase:Units = "Radian" ;
719  double OceanUpAmp(Dim000005, Dim000011) ;
720  OceanUpAmp:LCODE = "SITOCAMP" ;
721  OceanUpAmp:CreateTime = "2015/09/14 15:14:16 " ;
722  OceanUpAmp:Definition = "Vert ocean loading ampltudes (m)" ;
723  OceanUpAmp:Units = "M" ;
724  double OceanHorizontalAmp(Dim000005, Dim000002, Dim000011) ;
725  OceanHorizontalAmp:LCODE = "SITHOCAM" ;
726  OceanHorizontalAmp:CreateTime = "2015/09/14 15:14:16 " ;
727  OceanHorizontalAmp:Definition = "Horz ocean loading ampltudes (m)" ;
728  OceanHorizontalAmp:Units = "M" ;
729  double OceanHorizontalPhase(Dim000005, Dim000002, Dim000011) ;
730  OceanHorizontalPhase:LCODE = "SITHOCPH" ;
731  OceanHorizontalPhase:CreateTime = "2015/09/14 15:14:16 " ;
732  OceanHorizontalPhase:Definition = "Horz ocean loading phases (rad)." ;
733  OceanHorizontalPhase:Units = "Radian" ;
734 
735  ^
736  |
737  +order of stations? OceanLoadingStationList?
738 
739 
740 
741 
742  units: all units to the same convention: "M" => "meter"
743 
744 
745  per band:
746 
747  FeedCorrection
748 
749 
750 */
751 
752 
753 
754 
755 
756 
757 
758 
759 
760 /*=====================================================================================================*/
SgLogger * logger
Definition: SgLogger.cpp:231
#define UNUSED
virtual void write(LogLevel, quint32, const QString &, bool=false)
Definition: SgLogger.cpp:88
@ SESSION
Definition: SgLogger.h:77
short mimic_MvRec(short ntoc, short kmode, short knum)
void setBandList(const QList< QString > &bands)
void mimicPutI(const QString &lCode, const short values[], short dim1, short dim2, short dim3)
void mimicPutA(const QString &lCode, const char values[], short dim1, short dim2, short dim3)
void setCurrentBand(const QString &key, bool is)
void mimicDelR(short nToc, const QString &lCode)
short mimicGetI(const QString &lCode, short values[], short dim1, short dim2, short dim3, short actualDimension[])
void mimicAddI(short nToc, const QString &lCode, const QString &descr, short dim1, short dim2, short dim3)
CalcCallingMode getCalcCallingMode() const
void mimicAddJ(short nToc, const QString &lCode, const QString &descr, short dim1, short dim2, short dim3)
void mimicDelA(short nToc, const QString &lCode)
void mimicAddR(short nToc, const QString &lCode, const QString &descr, short dim1, short dim2, short dim3)
void mimic_pHist(const QString &histRecord)
void mimicAdd4(short nToc, const QString &lCode, const QString &descr, short dim1, short dim2, short dim3)
short mimicGetA(const QString &lCode, char values[], short dim1, short dim2, short dim3, short actualDimension[])
void mimic_Kai(short openMode, const QString &inputDbName, short inputDbVersion, const QString &outputDbName, short &outputDbVersion, short &errorFlag)
void mimicAddA(short nToc, const QString &lCode, const QString &descr, short dim1, short dim2, short dim3)
void mimicPutR(const QString &lCode, const double values[], short dim1, short dim2, short dim3)
short mimicGet4(const QString &lCode, double values[], short dim1, short dim2, short dim3, short actualDimension[])
void mimicPut4(const QString &lCode, const double values[], short dim1, short dim2, short dim3)
void adda_(const short &ntoc, const char *lcode, const char *descrText, const short &dim1, const short &dim2, const short &dim3, size_t len1, size_t len2)
void datsv_()
QString histIntroRec
void get4_(const char *lcode, double values[], const short &dim1, const short &dim2, const short &dim3, short numDims[], short &kerr, size_t len)
void puta_(const char *lcode, const char vals[], const short &dim1, const short &dim2, const short &dim3, size_t len)
void qString2fortArray(const QString &str, char *chrs, size_t len)
void put4_(const char *lcode, const double vals[], const short &dim1, const short &dim2, const short &dim3, size_t len)
void dela_(const short &ntoc, const char *lcode, size_t len)
void ask_(const char *lcode, const short &ntoc, const short &dim1, const short &dim2, const short &dim3, const short &nver, UNUSED const char *ltext_chr, UNUSED const short &ktype, short &kerr, UNUSED size_t len1, UNUSED size_t len2)
void mimicCalcMain2(UNUSED int iArg1, int iArg2, const char *sArg3, const char *sArg4, const QList< QString > &bands)
void mvrec_(short &ntoc, short &kmode, short &knum, short &kerr)
void finis_(UNUSED short par)
void addr_(const short &ntoc, const char *lcode, const char *descrText, const short &dim1, const short &dim2, const short &dim3, size_t len1, size_t len2)
void kai_(short &kruc, UNUSED short &in, UNUSED short &iout, UNUSED short &istp, char *lkynm_chr, short &iveri, char *lkout_chr, UNUSED char *lfto_chr, short &ivero, UNUSED char *lfio_chr, short &kerr, size_t len1, size_t len2, UNUSED size_t len3, UNUSED size_t len4)
void geti_(const char *lcode, short values[], const short &dim1, const short &dim2, const short &dim3, short numDims[], short &kerr, size_t len)
void phist_(short &nhist, const char *lhist_chr, size_t len)
void geta_(const char *lcode, char values[], const short &dim1, const short &dim2, const short &dim3, short numDims[], short &kerr, size_t len)
void wridr_()
void add4_(const short &ntoc, const char *lcode, const char *descrText, const short &dim1, const short &dim2, const short &dim3, size_t len1, size_t len2)
void delr_(const short &ntoc, const char *lcode, size_t len)
void quit_calc_(UNUSED short iPar[])
void addj_(const short &ntoc, const char *lcode, const char *descrText, const short &dim1, const short &dim2, const short &dim3, size_t len1, size_t len2)
void putr_(const char *lcode, const double vals[], const short &dim1, const short &dim2, const short &dim3, size_t len)
void puti_(const char *lcode, const short vals[], const short &dim1, const short &dim2, const short &dim3, size_t len)
short gethostname_(char *hostName, size_t len)
void mimicCalcMain(UNUSED int iArg1, int iArg2, const char *sArg3, const char *sArg4)
VcCalc2SessionIfc c2s
void addi_(const short &ntoc, const char *lcode, const char *descrText, const short &dim1, const short &dim2, const short &dim3, size_t len1, size_t len2)
short trimlen_(char *chrs, size_t len)
QString fortArray2QString(const char *chrs, size_t len)
void obsnt_(int &kount, int &kend)
void initl_(int &kount)
void start_(short &iLu, const char *calcOnName, short &iOut, size_t len)
void tocup_()
#define f_true
Definition: vgosDbCalc.h:41
struct @1 extrnl_
void drivr_()