Overview
Comment:Improved message format, directed to file (MTT.Hybrd_messages).
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | origin/master | trunk
Files: files | file ages | folders
SHA3-256: 645637041f802642ee1dfb38e19b3fc672f4cc8cd2ae0c4d96857bc425506984
User & Date: geraint@users.sourceforge.net on 2002-03-26 12:10:04
Other Links: branch diff | manifest | tags
Context
2002-03-26
12:11:12
Added abs => fabs rule. check-in: ace0503385 user: geraint@users.sourceforge.net tags: origin/master, trunk
12:10:04
Improved message format, directed to file (MTT.Hybrd_messages). check-in: 645637041f user: geraint@users.sourceforge.net tags: origin/master, trunk
12:06:16
Changed initial solver value from 1.0 to 0.0. check-in: 9b3e5aebaa user: geraint@users.sourceforge.net tags: origin/master, trunk
Changes

Modified mttroot/mtt/lib/cc/mtt_Hybrd_Solver.cc from [83e5c993ac] to [7e75a7fc89].

12
13
14
15
16
17
18

19
20
21
22
23
24
25
26
27
28
29

30
31
32
33
34
35
36
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29

30
31
32
33
34
35
36
37







+










-
+







  MTT::Hybrd_Solver::static_ptr->_yz = MTT::Hybrd_Solver::static_ptr->eval(tryUi);
  return MTT::Hybrd_Solver::static_ptr->_yz;
}

void
MTT::Hybrd_Solver::Solve (void)
{    
  static std::fstream ferr ("MTT.Hybrd_messages", ios::out | ios::trunc | ios::app);
  int info;
  static int input_errors;
  static int user_errors;
  static int convergences;
  static int progress_errors;
  static int limit_errors;
  static int unknown_errors;
  
  NLFunc fcn(&Hybrd_Solver::f_hybrd);
  NLEqn	 eqn(Solver::_ui,fcn);
  eqn.set_tolerance(0.000001);
  eqn.set_tolerance(1.0e-3);
  Solver::_ui = eqn.solve(info);

  switch (info)
    {
    case 1:
      convergences++;
      break;
51
52
53
54
55
56
57
58

59
60

61
62
63
64




65

66
52
53
54
55
56
57
58

59


60




61
62
63
64
65
66
67







-
+
-
-
+
-
-
-
-
+
+
+
+

+

      break;
    default:
      unknown_errors++;
      break;
    }
  if (1 != info)
    {
      std::cerr << "input (" << input_errors << ") "
      std::cerr
		<< "  user (" << user_errors << ") "
		<< "  converge (" << convergences << ") "
	<< " converge (" << convergences << ") "
		<< "  progress (" << progress_errors << ") "
		<< "  limit (" << limit_errors << ")"
		<< "  unknown (" << unknown_errors << ")"
		<< "  (max error = " << std::abs(eval(_ui).max()) << ")" << std::endl;
	<< " limit (" << limit_errors << ")"
	<< " (max error = " << std::abs (eval(_ui).max()) << ")"
	<< " other (" << input_errors + user_errors + progress_errors + unknown_errors << ") "
	<< std::endl;
    }
  ferr << info << " ";
}

Modified mttroot/mtt/lib/cc/mtt_Hybrd_Solver.hh from [dbef8ec549] to [7dad372c91].

1
2
3
4

5
6
7
8
9
10
11
1
2
3
4
5
6
7
8
9
10
11
12




+








#ifndef MTT_HYBRDSOLVER
#define MTT_HYBRDSOLVER

#include <fstream>

#include <octave/NLEqn.h>
#include "mtt_AlgebraicSolver.hh"


namespace MTT
{


MTT: Model Transformation Tools
GitHub | SourceHut | Sourceforge | Fossil RSS ]