Changeset 326 in Sophya for trunk/SophyaPI/PIext/basexecut.cc
- Timestamp:
- Jun 23, 1999, 4:41:47 PM (26 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/SophyaPI/PIext/basexecut.cc
r312 r326 13 13 #include "pistdimgapp.h" 14 14 #include "nobjmgr.h" 15 #include "servnobjm.h" 15 16 16 17 #include "histos.h" … … 252 253 np = atoi(tokens[3].c_str()); 253 254 xmin = atof(tokens[1].c_str()); xmax = atof(tokens[2].c_str()); 254 mObjMgr->PlotFunc(tokens[0], xmin, xmax, np, opt); 255 mObjMgr->GetServiceObj()->PlotFunc(tokens[0], xmin, xmax, np, opt); 256 } 257 else if ( (kw == "funcff") ) { 258 if (tokens.size() < 5) { cout << "Usage: funcff C-filename f(x)-name xmin xmax npt [opt]" << endl; return(0); } 259 string opt = "n"; 260 if (tokens.size() > 5) opt = tokens[5]; 261 int np; 262 float xmin, xmax; 263 np = 100; 264 xmin = 0.; xmax = 1.; 265 np = atoi(tokens[4].c_str()); 266 xmin = atof(tokens[2].c_str()); xmax = atof(tokens[3].c_str()); 267 mObjMgr->GetServiceObj()->PlotFuncFrCFile(tokens[0], tokens[1], xmin, xmax, np, opt); 255 268 } 256 269 else if ( (kw == "func2d") ) { … … 271 284 string opt = "n"; 272 285 if (tokens.size() > 7) opt = tokens[7]; 273 mObjMgr->PlotFunc2D(tokens[0], xmin, xmax, ymin, ymax, npx, npy, opt); 286 mObjMgr->GetServiceObj()->PlotFunc2D(tokens[0], xmin, xmax, ymin, ymax, npx, npy, opt); 287 } 288 else if ( (kw == "func2dff") ) { 289 if (tokens.size() < 8) { 290 cout << "Usage: func2d C-filename F(x,y)-name xmax nptx ymin ymax npty opt" << endl; 291 return(0); 292 } 293 int npx, npy; 294 float xmin, xmax; 295 float ymin, ymax; 296 npx = npy = 50; 297 xmin = 0.; xmax = 1.; 298 ymin = 0.; ymax = 1.; 299 npx = atoi(tokens[4].c_str()); 300 npy = atoi(tokens[7].c_str()); 301 xmin = atof(tokens[2].c_str()); xmax = atof(tokens[3].c_str()); 302 ymin = atof(tokens[5].c_str()); ymax = atof(tokens[6].c_str()); 303 string opt = "n"; 304 if (tokens.size() > 8) opt = tokens[8]; 305 mObjMgr->GetServiceObj()->PlotFunc2DFrCFile(tokens[0], tokens[1], xmin, xmax, ymin, ymax, npx, npy, opt); 274 306 } 275 307 … … 551 583 usage = "Displays a function y=f(x) (Fills a vector with function values)"; 552 584 usage += "\n Usage: func f(x) xmin xmax npt [graphic_attributes]"; 553 usage += "\n Related commands: func2d "; 585 usage += "\n Related commands: funcff func2d func2dff "; 586 mpiac->RegisterCommand(kw, usage, this); 587 kw = "funcff"; 588 usage = "Displays a function y=f(x) from a C-file (Fills a vector with function values)"; 589 usage += "\n Usage: funcff C-FileName FunctionName xmin xmax npt [graphic_attributes]"; 590 usage += "\n Related commands: func func2d func2dff "; 554 591 mpiac->RegisterCommand(kw, usage, this); 555 592 kw = "func2d"; … … 557 594 usage += "\n Usage: func2d f(x,y) xmin xmax nptx ymin ymax npty [graphic_attributes]"; 558 595 usage += "\n Related commands: func"; 596 mpiac->RegisterCommand(kw, usage, this); 597 kw = "func2dff"; 598 usage = "Displays a function z=f(x,y) from a C-file (Fills a matrix with function values)"; 599 usage += "\n Usage: func2dff C-FileName FunctionName xmin xmax nptx ymin ymax npty [graphic_attributes]"; 600 usage += "\n Related commands: func funcff func2d "; 559 601 mpiac->RegisterCommand(kw, usage, this); 560 602
Note:
See TracChangeset
for help on using the changeset viewer.