|\^/| Maple 12 (IBM INTEL LINUX)
._|\| |/|_. Copyright (c) Maplesoft, a division of Waterloo Maple Inc. 2008
\ MAPLE / All rights reserved. Maple is a trademark of
<____ ____> Waterloo Maple Inc.
| Type ? for help.
> #BEGIN OUTFILE1
>
> # Begin Function number 3
> display_alot := proc(iter)
> global
> DEBUGMASSIVE,
> DEBUGL,
> glob_max_terms,
> INFO,
> glob_iolevel,
> ALWAYS,
> #Top Generate Globals Decl
> glob_iter,
> glob_max_sec,
> glob_hmin,
> glob_clock_start_sec,
> glob_almost_1,
> min_in_hour,
> glob_dump,
> glob_log10_relerr,
> centuries_in_millinium,
> glob_max_opt_iter,
> glob_subiter_method,
> glob_log10abserr,
> glob_unchanged_h_cnt,
> glob_max_iter,
> glob_reached_optimal_h,
> glob_percent_done,
> MAX_UNCHANGED,
> glob_relerr,
> glob_hmin_init,
> glob_not_yet_finished,
> hours_in_day,
> djd_debug2,
> glob_log10relerr,
> glob_warned2,
> glob_optimal_start,
> glob_last_good_h,
> years_in_century,
> djd_debug,
> glob_normmax,
> glob_current_iter,
> glob_curr_iter_when_opt,
> glob_warned,
> glob_small_float,
> glob_no_eqs,
> glob_max_hours,
> glob_log10_abserr,
> glob_hmax,
> glob_max_minutes,
> glob_orig_start_sec,
> glob_smallish_float,
> glob_max_trunc_err,
> glob_max_rel_trunc_err,
> glob_abserr,
> glob_large_float,
> days_in_year,
> sec_in_minute,
> glob_good_digits,
> glob_log10normmin,
> glob_dump_analytic,
> glob_look_poles,
> glob_disp_incr,
> glob_optimal_done,
> glob_not_yet_start_msg,
> glob_initial_pass,
> glob_clock_sec,
> glob_html_log,
> glob_h,
> glob_display_flag,
> glob_optimal_expect_sec,
> glob_start,
> glob_optimal_clock_start_sec,
> #Bottom Generate Globals Decl
> #BEGIN CONST
> array_const_1D0,
> array_const_1,
> array_const_0D0,
> #END CONST
> array_y,
> array_x,
> array_norms,
> array_last_rel_error,
> array_type_pole,
> array_fact_1,
> array_pole,
> array_m1,
> array_y_init,
> array_1st_rel_error,
> array_tmp0,
> array_tmp1,
> array_tmp2,
> array_y_set_initial,
> array_complex_pole,
> array_fact_2,
> array_y_higher,
> array_real_pole,
> array_poles,
> array_y_higher_work,
> array_y_higher_work2,
> glob_last;
>
> local abserr, analytic_val_y, ind_var, numeric_val, relerr, term_no;
>
>
>
>
>
> #TOP DISPLAY ALOT
> if (iter >= 0) then # if number 1
> ind_var := array_x[1];
> omniout_float(ALWAYS,"x[1] ",33,ind_var,20," ");
> analytic_val_y := exact_soln_y(ind_var);
> omniout_float(ALWAYS,"y[1] (analytic) ",33,analytic_val_y,20," ");
> term_no := 1;
> numeric_val := array_y[term_no];
> abserr := omniabs(numeric_val - analytic_val_y);
> omniout_float(ALWAYS,"y[1] (numeric) ",33,numeric_val,20," ");
> if (omniabs(analytic_val_y) <> 0.0) then # if number 2
> relerr := abserr*100.0/omniabs(analytic_val_y);
> if (relerr <> 0.0) then # if number 3
> glob_good_digits := -trunc(log10(relerr/100.0));
> else
> glob_good_digits := Digits;
> fi;# end if 3
> ;
> else
> relerr := -1.0 ;
> glob_good_digits := -1;
> fi;# end if 2
> ;
> if (glob_iter = 1) then # if number 2
> array_1st_rel_error[1] := relerr;
> else
> array_last_rel_error[1] := relerr;
> fi;# end if 2
> ;
> omniout_float(ALWAYS,"absolute error ",4,abserr,20," ");
> omniout_float(ALWAYS,"relative error ",4,relerr,20,"%");
> omniout_int(INFO,"Correct digits ",32,glob_good_digits,4," ")
> ;
> omniout_float(ALWAYS,"h ",4,glob_h,20," ");
> #BOTTOM DISPLAY ALOT
> fi;# end if 1
> ;
>
> # End Function number 3
> end;
display_alot := proc(iter)
local abserr, analytic_val_y, ind_var, numeric_val, relerr, term_no;
global DEBUGMASSIVE, DEBUGL, glob_max_terms, INFO, glob_iolevel, ALWAYS,
glob_iter, glob_max_sec, glob_hmin, glob_clock_start_sec, glob_almost_1,
min_in_hour, glob_dump, glob_log10_relerr, centuries_in_millinium,
glob_max_opt_iter, glob_subiter_method, glob_log10abserr,
glob_unchanged_h_cnt, glob_max_iter, glob_reached_optimal_h,
glob_percent_done, MAX_UNCHANGED, glob_relerr, glob_hmin_init,
glob_not_yet_finished, hours_in_day, djd_debug2, glob_log10relerr,
glob_warned2, glob_optimal_start, glob_last_good_h, years_in_century,
djd_debug, glob_normmax, glob_current_iter, glob_curr_iter_when_opt,
glob_warned, glob_small_float, glob_no_eqs, glob_max_hours,
glob_log10_abserr, glob_hmax, glob_max_minutes, glob_orig_start_sec,
glob_smallish_float, glob_max_trunc_err, glob_max_rel_trunc_err,
glob_abserr, glob_large_float, days_in_year, sec_in_minute,
glob_good_digits, glob_log10normmin, glob_dump_analytic, glob_look_poles,
glob_disp_incr, glob_optimal_done, glob_not_yet_start_msg,
glob_initial_pass, glob_clock_sec, glob_html_log, glob_h, glob_display_flag,
glob_optimal_expect_sec, glob_start, glob_optimal_clock_start_sec,
array_const_1D0, array_const_1, array_const_0D0, array_y, array_x,
array_norms, array_last_rel_error, array_type_pole, array_fact_1,
array_pole, array_m1, array_y_init, array_1st_rel_error, array_tmp0,
array_tmp1, array_tmp2, array_y_set_initial, array_complex_pole,
array_fact_2, array_y_higher, array_real_pole, array_poles,
array_y_higher_work, array_y_higher_work2, glob_last;
if 0 <= iter then
ind_var := array_x[1];
omniout_float(ALWAYS, "x[1] ", 33,
ind_var, 20, " ");
analytic_val_y := exact_soln_y(ind_var);
omniout_float(ALWAYS, "y[1] (analytic) ", 33,
analytic_val_y, 20, " ");
term_no := 1;
numeric_val := array_y[term_no];
abserr := omniabs(numeric_val - analytic_val_y);
omniout_float(ALWAYS, "y[1] (numeric) ", 33,
numeric_val, 20, " ");
if omniabs(analytic_val_y) <> 0. then
relerr := abserr*100.0/omniabs(analytic_val_y);
if relerr <> 0. then
glob_good_digits := -trunc(log10(relerr/100.0))
else glob_good_digits := Digits
end if
else relerr := -1.0; glob_good_digits := -1
end if;
if glob_iter = 1 then array_1st_rel_error[1] := relerr
else array_last_rel_error[1] := relerr
end if;
omniout_float(ALWAYS, "absolute error ", 4,
abserr, 20, " ");
omniout_float(ALWAYS, "relative error ", 4,
relerr, 20, "%");
omniout_int(INFO, "Correct digits ", 32,
glob_good_digits, 4, " ");
omniout_float(ALWAYS, "h ", 4,
glob_h, 20, " ")
end if
end proc
> # Begin Function number 4
> adjust_for_pole := proc(h_param)
> global
> DEBUGMASSIVE,
> DEBUGL,
> glob_max_terms,
> INFO,
> glob_iolevel,
> ALWAYS,
> #Top Generate Globals Decl
> glob_iter,
> glob_max_sec,
> glob_hmin,
> glob_clock_start_sec,
> glob_almost_1,
> min_in_hour,
> glob_dump,
> glob_log10_relerr,
> centuries_in_millinium,
> glob_max_opt_iter,
> glob_subiter_method,
> glob_log10abserr,
> glob_unchanged_h_cnt,
> glob_max_iter,
> glob_reached_optimal_h,
> glob_percent_done,
> MAX_UNCHANGED,
> glob_relerr,
> glob_hmin_init,
> glob_not_yet_finished,
> hours_in_day,
> djd_debug2,
> glob_log10relerr,
> glob_warned2,
> glob_optimal_start,
> glob_last_good_h,
> years_in_century,
> djd_debug,
> glob_normmax,
> glob_current_iter,
> glob_curr_iter_when_opt,
> glob_warned,
> glob_small_float,
> glob_no_eqs,
> glob_max_hours,
> glob_log10_abserr,
> glob_hmax,
> glob_max_minutes,
> glob_orig_start_sec,
> glob_smallish_float,
> glob_max_trunc_err,
> glob_max_rel_trunc_err,
> glob_abserr,
> glob_large_float,
> days_in_year,
> sec_in_minute,
> glob_good_digits,
> glob_log10normmin,
> glob_dump_analytic,
> glob_look_poles,
> glob_disp_incr,
> glob_optimal_done,
> glob_not_yet_start_msg,
> glob_initial_pass,
> glob_clock_sec,
> glob_html_log,
> glob_h,
> glob_display_flag,
> glob_optimal_expect_sec,
> glob_start,
> glob_optimal_clock_start_sec,
> #Bottom Generate Globals Decl
> #BEGIN CONST
> array_const_1D0,
> array_const_1,
> array_const_0D0,
> #END CONST
> array_y,
> array_x,
> array_norms,
> array_last_rel_error,
> array_type_pole,
> array_fact_1,
> array_pole,
> array_m1,
> array_y_init,
> array_1st_rel_error,
> array_tmp0,
> array_tmp1,
> array_tmp2,
> array_y_set_initial,
> array_complex_pole,
> array_fact_2,
> array_y_higher,
> array_real_pole,
> array_poles,
> array_y_higher_work,
> array_y_higher_work2,
> glob_last;
>
> local hnew, sz2, tmp;
>
>
>
> #TOP ADJUST FOR POLE
>
> hnew := h_param;
> glob_normmax := glob_small_float;
> if (omniabs(array_y_higher[1,1]) > glob_small_float) then # if number 1
> tmp := omniabs(array_y_higher[1,1]);
> if (tmp < glob_normmax) then # if number 2
> glob_normmax := tmp;
> fi;# end if 2
> fi;# end if 1
> ;
> if (glob_look_poles and (omniabs(array_pole[1]) > glob_small_float) and (array_pole[1] <> glob_large_float)) then # if number 1
> sz2 := array_pole[1]/10.0;
> if (sz2 < hnew) then # if number 2
> omniout_float(INFO,"glob_h adjusted to ",20,h_param,12,"due to singularity.");
> omniout_str(INFO,"Reached Optimal");
> return(hnew);
> fi;# end if 2
> fi;# end if 1
> ;
> if ( not glob_reached_optimal_h) then # if number 1
> glob_reached_optimal_h := true;
> glob_curr_iter_when_opt := glob_current_iter;
> glob_optimal_clock_start_sec := elapsed_time_seconds();
> glob_optimal_start := array_x[1];
> fi;# end if 1
> ;
> hnew := sz2;
> ;#END block
> return(hnew);
> #BOTTOM ADJUST FOR POLE
>
> # End Function number 4
> end;
adjust_for_pole := proc(h_param)
local hnew, sz2, tmp;
global DEBUGMASSIVE, DEBUGL, glob_max_terms, INFO, glob_iolevel, ALWAYS,
glob_iter, glob_max_sec, glob_hmin, glob_clock_start_sec, glob_almost_1,
min_in_hour, glob_dump, glob_log10_relerr, centuries_in_millinium,
glob_max_opt_iter, glob_subiter_method, glob_log10abserr,
glob_unchanged_h_cnt, glob_max_iter, glob_reached_optimal_h,
glob_percent_done, MAX_UNCHANGED, glob_relerr, glob_hmin_init,
glob_not_yet_finished, hours_in_day, djd_debug2, glob_log10relerr,
glob_warned2, glob_optimal_start, glob_last_good_h, years_in_century,
djd_debug, glob_normmax, glob_current_iter, glob_curr_iter_when_opt,
glob_warned, glob_small_float, glob_no_eqs, glob_max_hours,
glob_log10_abserr, glob_hmax, glob_max_minutes, glob_orig_start_sec,
glob_smallish_float, glob_max_trunc_err, glob_max_rel_trunc_err,
glob_abserr, glob_large_float, days_in_year, sec_in_minute,
glob_good_digits, glob_log10normmin, glob_dump_analytic, glob_look_poles,
glob_disp_incr, glob_optimal_done, glob_not_yet_start_msg,
glob_initial_pass, glob_clock_sec, glob_html_log, glob_h, glob_display_flag,
glob_optimal_expect_sec, glob_start, glob_optimal_clock_start_sec,
array_const_1D0, array_const_1, array_const_0D0, array_y, array_x,
array_norms, array_last_rel_error, array_type_pole, array_fact_1,
array_pole, array_m1, array_y_init, array_1st_rel_error, array_tmp0,
array_tmp1, array_tmp2, array_y_set_initial, array_complex_pole,
array_fact_2, array_y_higher, array_real_pole, array_poles,
array_y_higher_work, array_y_higher_work2, glob_last;
hnew := h_param;
glob_normmax := glob_small_float;
if glob_small_float < omniabs(array_y_higher[1, 1]) then
tmp := omniabs(array_y_higher[1, 1]);
if tmp < glob_normmax then glob_normmax := tmp end if
end if;
if glob_look_poles and glob_small_float < omniabs(array_pole[1]) and
array_pole[1] <> glob_large_float then
sz2 := array_pole[1]/10.0;
if sz2 < hnew then
omniout_float(INFO, "glob_h adjusted to ", 20, h_param, 12,
"due to singularity.");
omniout_str(INFO, "Reached Optimal");
return hnew
end if
end if;
if not glob_reached_optimal_h then
glob_reached_optimal_h := true;
glob_curr_iter_when_opt := glob_current_iter;
glob_optimal_clock_start_sec := elapsed_time_seconds();
glob_optimal_start := array_x[1]
end if;
hnew := sz2;
return hnew
end proc
> # Begin Function number 5
> prog_report := proc(x_start,x_end)
> global
> DEBUGMASSIVE,
> DEBUGL,
> glob_max_terms,
> INFO,
> glob_iolevel,
> ALWAYS,
> #Top Generate Globals Decl
> glob_iter,
> glob_max_sec,
> glob_hmin,
> glob_clock_start_sec,
> glob_almost_1,
> min_in_hour,
> glob_dump,
> glob_log10_relerr,
> centuries_in_millinium,
> glob_max_opt_iter,
> glob_subiter_method,
> glob_log10abserr,
> glob_unchanged_h_cnt,
> glob_max_iter,
> glob_reached_optimal_h,
> glob_percent_done,
> MAX_UNCHANGED,
> glob_relerr,
> glob_hmin_init,
> glob_not_yet_finished,
> hours_in_day,
> djd_debug2,
> glob_log10relerr,
> glob_warned2,
> glob_optimal_start,
> glob_last_good_h,
> years_in_century,
> djd_debug,
> glob_normmax,
> glob_current_iter,
> glob_curr_iter_when_opt,
> glob_warned,
> glob_small_float,
> glob_no_eqs,
> glob_max_hours,
> glob_log10_abserr,
> glob_hmax,
> glob_max_minutes,
> glob_orig_start_sec,
> glob_smallish_float,
> glob_max_trunc_err,
> glob_max_rel_trunc_err,
> glob_abserr,
> glob_large_float,
> days_in_year,
> sec_in_minute,
> glob_good_digits,
> glob_log10normmin,
> glob_dump_analytic,
> glob_look_poles,
> glob_disp_incr,
> glob_optimal_done,
> glob_not_yet_start_msg,
> glob_initial_pass,
> glob_clock_sec,
> glob_html_log,
> glob_h,
> glob_display_flag,
> glob_optimal_expect_sec,
> glob_start,
> glob_optimal_clock_start_sec,
> #Bottom Generate Globals Decl
> #BEGIN CONST
> array_const_1D0,
> array_const_1,
> array_const_0D0,
> #END CONST
> array_y,
> array_x,
> array_norms,
> array_last_rel_error,
> array_type_pole,
> array_fact_1,
> array_pole,
> array_m1,
> array_y_init,
> array_1st_rel_error,
> array_tmp0,
> array_tmp1,
> array_tmp2,
> array_y_set_initial,
> array_complex_pole,
> array_fact_2,
> array_y_higher,
> array_real_pole,
> array_poles,
> array_y_higher_work,
> array_y_higher_work2,
> glob_last;
>
> local clock_sec, opt_clock_sec, clock_sec1, expect_sec, left_sec, percent_done, total_clock_sec;
>
>
>
>
>
> #TOP PROGRESS REPORT
> clock_sec1 := elapsed_time_seconds();
> total_clock_sec := convfloat(clock_sec1) - convfloat(glob_orig_start_sec);
> glob_clock_sec := convfloat(clock_sec1) - convfloat(glob_clock_start_sec);
> left_sec := convfloat(glob_max_sec) + convfloat(glob_orig_start_sec) - convfloat(clock_sec1);
> expect_sec := comp_expect_sec(convfloat(x_end),convfloat(x_start),convfloat(array_x[1]) + convfloat(glob_h) ,convfloat( clock_sec1) - convfloat(glob_orig_start_sec));
> opt_clock_sec := convfloat( clock_sec1) - convfloat(glob_optimal_clock_start_sec);
> glob_optimal_expect_sec := comp_expect_sec(convfloat(x_end),convfloat(x_start),convfloat(array_x[1]) +convfloat( glob_h) ,convfloat( opt_clock_sec));
> percent_done := comp_percent(convfloat(x_end),convfloat(x_start),convfloat(array_x[1]) + convfloat(glob_h));
> glob_percent_done := percent_done;
> omniout_str_noeol(INFO,"Total Elapsed Time ");
> omniout_timestr(convfloat(total_clock_sec));
> omniout_str_noeol(INFO,"Elapsed Time(since restart) ");
> omniout_timestr(convfloat(glob_clock_sec));
> if (convfloat(percent_done) < convfloat(100.0)) then # if number 1
> omniout_str_noeol(INFO,"Expected Time Remaining ");
> omniout_timestr(convfloat(expect_sec));
> omniout_str_noeol(INFO,"Optimized Time Remaining ");
> omniout_timestr(convfloat(glob_optimal_expect_sec));
> fi;# end if 1
> ;
> omniout_str_noeol(INFO,"Time to Timeout ");
> omniout_timestr(convfloat(left_sec));
> omniout_float(INFO, "Percent Done ",33,percent_done,4,"%");
> #BOTTOM PROGRESS REPORT
>
> # End Function number 5
> end;
prog_report := proc(x_start, x_end)
local clock_sec, opt_clock_sec, clock_sec1, expect_sec, left_sec,
percent_done, total_clock_sec;
global DEBUGMASSIVE, DEBUGL, glob_max_terms, INFO, glob_iolevel, ALWAYS,
glob_iter, glob_max_sec, glob_hmin, glob_clock_start_sec, glob_almost_1,
min_in_hour, glob_dump, glob_log10_relerr, centuries_in_millinium,
glob_max_opt_iter, glob_subiter_method, glob_log10abserr,
glob_unchanged_h_cnt, glob_max_iter, glob_reached_optimal_h,
glob_percent_done, MAX_UNCHANGED, glob_relerr, glob_hmin_init,
glob_not_yet_finished, hours_in_day, djd_debug2, glob_log10relerr,
glob_warned2, glob_optimal_start, glob_last_good_h, years_in_century,
djd_debug, glob_normmax, glob_current_iter, glob_curr_iter_when_opt,
glob_warned, glob_small_float, glob_no_eqs, glob_max_hours,
glob_log10_abserr, glob_hmax, glob_max_minutes, glob_orig_start_sec,
glob_smallish_float, glob_max_trunc_err, glob_max_rel_trunc_err,
glob_abserr, glob_large_float, days_in_year, sec_in_minute,
glob_good_digits, glob_log10normmin, glob_dump_analytic, glob_look_poles,
glob_disp_incr, glob_optimal_done, glob_not_yet_start_msg,
glob_initial_pass, glob_clock_sec, glob_html_log, glob_h, glob_display_flag,
glob_optimal_expect_sec, glob_start, glob_optimal_clock_start_sec,
array_const_1D0, array_const_1, array_const_0D0, array_y, array_x,
array_norms, array_last_rel_error, array_type_pole, array_fact_1,
array_pole, array_m1, array_y_init, array_1st_rel_error, array_tmp0,
array_tmp1, array_tmp2, array_y_set_initial, array_complex_pole,
array_fact_2, array_y_higher, array_real_pole, array_poles,
array_y_higher_work, array_y_higher_work2, glob_last;
clock_sec1 := elapsed_time_seconds();
total_clock_sec :=
convfloat(clock_sec1) - convfloat(glob_orig_start_sec);
glob_clock_sec :=
convfloat(clock_sec1) - convfloat(glob_clock_start_sec);
left_sec := convfloat(glob_max_sec) + convfloat(glob_orig_start_sec)
- convfloat(clock_sec1);
expect_sec := comp_expect_sec(convfloat(x_end), convfloat(x_start),
convfloat(array_x[1]) + convfloat(glob_h),
convfloat(clock_sec1) - convfloat(glob_orig_start_sec));
opt_clock_sec :=
convfloat(clock_sec1) - convfloat(glob_optimal_clock_start_sec);
glob_optimal_expect_sec := comp_expect_sec(convfloat(x_end),
convfloat(x_start), convfloat(array_x[1]) + convfloat(glob_h),
convfloat(opt_clock_sec));
percent_done := comp_percent(convfloat(x_end), convfloat(x_start),
convfloat(array_x[1]) + convfloat(glob_h));
glob_percent_done := percent_done;
omniout_str_noeol(INFO, "Total Elapsed Time ");
omniout_timestr(convfloat(total_clock_sec));
omniout_str_noeol(INFO, "Elapsed Time(since restart) ");
omniout_timestr(convfloat(glob_clock_sec));
if convfloat(percent_done) < convfloat(100.0) then
omniout_str_noeol(INFO, "Expected Time Remaining ");
omniout_timestr(convfloat(expect_sec));
omniout_str_noeol(INFO, "Optimized Time Remaining ");
omniout_timestr(convfloat(glob_optimal_expect_sec))
end if;
omniout_str_noeol(INFO, "Time to Timeout ");
omniout_timestr(convfloat(left_sec));
omniout_float(INFO, "Percent Done ", 33,
percent_done, 4, "%")
end proc
> # Begin Function number 6
> check_for_pole := proc()
> global
> DEBUGMASSIVE,
> DEBUGL,
> glob_max_terms,
> INFO,
> glob_iolevel,
> ALWAYS,
> #Top Generate Globals Decl
> glob_iter,
> glob_max_sec,
> glob_hmin,
> glob_clock_start_sec,
> glob_almost_1,
> min_in_hour,
> glob_dump,
> glob_log10_relerr,
> centuries_in_millinium,
> glob_max_opt_iter,
> glob_subiter_method,
> glob_log10abserr,
> glob_unchanged_h_cnt,
> glob_max_iter,
> glob_reached_optimal_h,
> glob_percent_done,
> MAX_UNCHANGED,
> glob_relerr,
> glob_hmin_init,
> glob_not_yet_finished,
> hours_in_day,
> djd_debug2,
> glob_log10relerr,
> glob_warned2,
> glob_optimal_start,
> glob_last_good_h,
> years_in_century,
> djd_debug,
> glob_normmax,
> glob_current_iter,
> glob_curr_iter_when_opt,
> glob_warned,
> glob_small_float,
> glob_no_eqs,
> glob_max_hours,
> glob_log10_abserr,
> glob_hmax,
> glob_max_minutes,
> glob_orig_start_sec,
> glob_smallish_float,
> glob_max_trunc_err,
> glob_max_rel_trunc_err,
> glob_abserr,
> glob_large_float,
> days_in_year,
> sec_in_minute,
> glob_good_digits,
> glob_log10normmin,
> glob_dump_analytic,
> glob_look_poles,
> glob_disp_incr,
> glob_optimal_done,
> glob_not_yet_start_msg,
> glob_initial_pass,
> glob_clock_sec,
> glob_html_log,
> glob_h,
> glob_display_flag,
> glob_optimal_expect_sec,
> glob_start,
> glob_optimal_clock_start_sec,
> #Bottom Generate Globals Decl
> #BEGIN CONST
> array_const_1D0,
> array_const_1,
> array_const_0D0,
> #END CONST
> array_y,
> array_x,
> array_norms,
> array_last_rel_error,
> array_type_pole,
> array_fact_1,
> array_pole,
> array_m1,
> array_y_init,
> array_1st_rel_error,
> array_tmp0,
> array_tmp1,
> array_tmp2,
> array_y_set_initial,
> array_complex_pole,
> array_fact_2,
> array_y_higher,
> array_real_pole,
> array_poles,
> array_y_higher_work,
> array_y_higher_work2,
> glob_last;
>
> local cnt, dr1, dr2, ds1, ds2, hdrc, m, n, nr1, nr2, ord_no, rad_c, rcs, rm0, rm1, rm2, rm3, rm4, found;
>
>
>
>
>
> #TOP CHECK FOR POLE
> #IN RADII REAL EQ = 1
> #Computes radius of convergence and r_order of pole from 3 adjacent Taylor series terms. EQUATUON NUMBER 1
> #Applies to pole of arbitrary r_order on the real axis,
> #Due to Prof. George Corliss.
> n := glob_max_terms;
> m := n - 1 - 1;
> while ((m >= 10) and ((omniabs(array_y_higher[1,m]) < glob_small_float) or (omniabs(array_y_higher[1,m-1]) < glob_small_float) or (omniabs(array_y_higher[1,m-2]) < glob_small_float ))) do # do number 2
> m := m - 1;
> od;# end do number 2
> ;
> if (m > 10) then # if number 1
> rm0 := array_y_higher[1,m]/array_y_higher[1,m-1];
> rm1 := array_y_higher[1,m-1]/array_y_higher[1,m-2];
> hdrc := convfloat(m-1)*rm0-convfloat(m-2)*rm1;
> if (omniabs(hdrc) > glob_small_float) then # if number 2
> rcs := glob_h/hdrc;
> ord_no := convfloat(m-1)*rm0/hdrc - convfloat(m) + 2.0;
> array_real_pole[1,1] := rcs;
> array_real_pole[1,2] := ord_no;
> else
> array_real_pole[1,1] := glob_large_float;
> array_real_pole[1,2] := glob_large_float;
> fi;# end if 2
> else
> array_real_pole[1,1] := glob_large_float;
> array_real_pole[1,2] := glob_large_float;
> fi;# end if 1
> ;
> #BOTTOM RADII REAL EQ = 1
> #TOP RADII COMPLEX EQ = 1
> #Computes radius of convergence for complex conjugate pair of poles.
> #from 6 adjacent Taylor series terms
> #Also computes r_order of poles.
> #Due to Manuel Prieto.
> #With a correction by Dennis J. Darland
> n := glob_max_terms - 1 - 1;
> cnt := 0;
> while ((cnt < 5) and (n >= 10)) do # do number 2
> if (omniabs(array_y_higher[1,n]) > glob_small_float) then # if number 1
> cnt := cnt + 1;
> else
> cnt := 0;
> fi;# end if 1
> ;
> n := n - 1;
> od;# end do number 2
> ;
> m := n + cnt;
> if (m <= 10) then # if number 1
> array_complex_pole[1,1] := glob_large_float;
> array_complex_pole[1,2] := glob_large_float;
> elif ((omniabs(array_y_higher[1,m]) >= (glob_large_float)) or (omniabs(array_y_higher[1,m-1]) >=(glob_large_float)) or (omniabs(array_y_higher[1,m-2]) >= (glob_large_float)) or (omniabs(array_y_higher[1,m-3]) >= (glob_large_float)) or (omniabs(array_y_higher[1,m-4]) >= (glob_large_float)) or (omniabs(array_y_higher[1,m-5]) >= (glob_large_float))) then # if number 2
> array_complex_pole[1,1] := glob_large_float;
> array_complex_pole[1,2] := glob_large_float;
> else
> rm0 := (array_y_higher[1,m])/(array_y_higher[1,m-1]);
> rm1 := (array_y_higher[1,m-1])/(array_y_higher[1,m-2]);
> rm2 := (array_y_higher[1,m-2])/(array_y_higher[1,m-3]);
> rm3 := (array_y_higher[1,m-3])/(array_y_higher[1,m-4]);
> rm4 := (array_y_higher[1,m-4])/(array_y_higher[1,m-5]);
> nr1 := convfloat(m-1)*rm0 - 2.0*convfloat(m-2)*rm1 + convfloat(m-3)*rm2;
> nr2 := convfloat(m-2)*rm1 - 2.0*convfloat(m-3)*rm2 + convfloat(m-4)*rm3;
> dr1 := (-1.0)/rm1 + 2.0/rm2 - 1.0/rm3;
> dr2 := (-1.0)/rm2 + 2.0/rm3 - 1.0/rm4;
> ds1 := 3.0/rm1 - 8.0/rm2 + 5.0/rm3;
> ds2 := 3.0/rm2 - 8.0/rm3 + 5.0/rm4;
> if ((omniabs(nr1 * dr2 - nr2 * dr1) <= glob_small_float) or (omniabs(dr1) <= glob_small_float)) then # if number 3
> array_complex_pole[1,1] := glob_large_float;
> array_complex_pole[1,2] := glob_large_float;
> else
> if (omniabs(nr1*dr2 - nr2 * dr1) > glob_small_float) then # if number 4
> rcs := ((ds1*dr2 - ds2*dr1 +dr1*dr2)/(nr1*dr2 - nr2 * dr1));
> #(Manuels) rcs := (ds1*dr2 - ds2*dr1)/(nr1*dr2 - nr2 * dr1)
> ord_no := (rcs*nr1 - ds1)/(2.0*dr1) -convfloat(m)/2.0;
> if (omniabs(rcs) > glob_small_float) then # if number 5
> if (rcs > 0.0) then # if number 6
> rad_c := sqrt(rcs) * glob_h;
> else
> rad_c := glob_large_float;
> fi;# end if 6
> else
> rad_c := glob_large_float;
> ord_no := glob_large_float;
> fi;# end if 5
> else
> rad_c := glob_large_float;
> ord_no := glob_large_float;
> fi;# end if 4
> fi;# end if 3
> ;
> array_complex_pole[1,1] := rad_c;
> array_complex_pole[1,2] := ord_no;
> fi;# end if 2
> ;
> #BOTTOM RADII COMPLEX EQ = 1
> found := false;
> #TOP WHICH RADII EQ = 1
> if ( not found and ((array_real_pole[1,1] = glob_large_float) or (array_real_pole[1,2] = glob_large_float)) and ((array_complex_pole[1,1] <> glob_large_float) and (array_complex_pole[1,2] <> glob_large_float)) and ((array_complex_pole[1,1] > 0.0) and (array_complex_pole[1,2] > 0.0))) then # if number 2
> array_poles[1,1] := array_complex_pole[1,1];
> array_poles[1,2] := array_complex_pole[1,2];
> found := true;
> array_type_pole[1] := 2;
> if (glob_display_flag) then # if number 3
> omniout_str(ALWAYS,"Complex estimate of poles used");
> fi;# end if 3
> ;
> fi;# end if 2
> ;
> if ( not found and ((array_real_pole[1,1] <> glob_large_float) and (array_real_pole[1,2] <> glob_large_float) and (array_real_pole[1,1] > 0.0) and (array_real_pole[1,2] > 0.0) and ((array_complex_pole[1,1] = glob_large_float) or (array_complex_pole[1,2] = glob_large_float) or (array_complex_pole[1,1] <= 0.0 ) or (array_complex_pole[1,2] <= 0.0)))) then # if number 2
> array_poles[1,1] := array_real_pole[1,1];
> array_poles[1,2] := array_real_pole[1,2];
> found := true;
> array_type_pole[1] := 1;
> if (glob_display_flag) then # if number 3
> omniout_str(ALWAYS,"Real estimate of pole used");
> fi;# end if 3
> ;
> fi;# end if 2
> ;
> if ( not found and (((array_real_pole[1,1] = glob_large_float) or (array_real_pole[1,2] = glob_large_float)) and ((array_complex_pole[1,1] = glob_large_float) or (array_complex_pole[1,2] = glob_large_float)))) then # if number 2
> array_poles[1,1] := glob_large_float;
> array_poles[1,2] := glob_large_float;
> found := true;
> array_type_pole[1] := 3;
> if (glob_display_flag) then # if number 3
> omniout_str(ALWAYS,"NO POLE");
> fi;# end if 3
> ;
> fi;# end if 2
> ;
> if ( not found and ((array_real_pole[1,1] < array_complex_pole[1,1]) and (array_real_pole[1,1] > 0.0) and (array_real_pole[1,2] > 0.0))) then # if number 2
> array_poles[1,1] := array_real_pole[1,1];
> array_poles[1,2] := array_real_pole[1,2];
> found := true;
> array_type_pole[1] := 1;
> if (glob_display_flag) then # if number 3
> omniout_str(ALWAYS,"Real estimate of pole used");
> fi;# end if 3
> ;
> fi;# end if 2
> ;
> if ( not found and ((array_complex_pole[1,1] <> glob_large_float) and (array_complex_pole[1,2] <> glob_large_float) and (array_complex_pole[1,1] > 0.0) and (array_complex_pole[1,2] > 0.0))) then # if number 2
> array_poles[1,1] := array_complex_pole[1,1];
> array_poles[1,2] := array_complex_pole[1,2];
> array_type_pole[1] := 2;
> found := true;
> if (glob_display_flag) then # if number 3
> omniout_str(ALWAYS,"Complex estimate of poles used");
> fi;# end if 3
> ;
> fi;# end if 2
> ;
> if ( not found ) then # if number 2
> array_poles[1,1] := glob_large_float;
> array_poles[1,2] := glob_large_float;
> array_type_pole[1] := 3;
> if (glob_display_flag) then # if number 3
> omniout_str(ALWAYS,"NO POLE");
> fi;# end if 3
> ;
> fi;# end if 2
> ;
> #BOTTOM WHICH RADII EQ = 1
> array_pole[1] := glob_large_float;
> array_pole[2] := glob_large_float;
> #TOP WHICH RADIUS EQ = 1
> if (array_pole[1] > array_poles[1,1]) then # if number 2
> array_pole[1] := array_poles[1,1];
> array_pole[2] := array_poles[1,2];
> fi;# end if 2
> ;
> #BOTTOM WHICH RADIUS EQ = 1
> #BOTTOM CHECK FOR POLE
> display_pole();
>
> # End Function number 6
> end;
check_for_pole := proc()
local cnt, dr1, dr2, ds1, ds2, hdrc, m, n, nr1, nr2, ord_no, rad_c, rcs,
rm0, rm1, rm2, rm3, rm4, found;
global DEBUGMASSIVE, DEBUGL, glob_max_terms, INFO, glob_iolevel, ALWAYS,
glob_iter, glob_max_sec, glob_hmin, glob_clock_start_sec, glob_almost_1,
min_in_hour, glob_dump, glob_log10_relerr, centuries_in_millinium,
glob_max_opt_iter, glob_subiter_method, glob_log10abserr,
glob_unchanged_h_cnt, glob_max_iter, glob_reached_optimal_h,
glob_percent_done, MAX_UNCHANGED, glob_relerr, glob_hmin_init,
glob_not_yet_finished, hours_in_day, djd_debug2, glob_log10relerr,
glob_warned2, glob_optimal_start, glob_last_good_h, years_in_century,
djd_debug, glob_normmax, glob_current_iter, glob_curr_iter_when_opt,
glob_warned, glob_small_float, glob_no_eqs, glob_max_hours,
glob_log10_abserr, glob_hmax, glob_max_minutes, glob_orig_start_sec,
glob_smallish_float, glob_max_trunc_err, glob_max_rel_trunc_err,
glob_abserr, glob_large_float, days_in_year, sec_in_minute,
glob_good_digits, glob_log10normmin, glob_dump_analytic, glob_look_poles,
glob_disp_incr, glob_optimal_done, glob_not_yet_start_msg,
glob_initial_pass, glob_clock_sec, glob_html_log, glob_h, glob_display_flag,
glob_optimal_expect_sec, glob_start, glob_optimal_clock_start_sec,
array_const_1D0, array_const_1, array_const_0D0, array_y, array_x,
array_norms, array_last_rel_error, array_type_pole, array_fact_1,
array_pole, array_m1, array_y_init, array_1st_rel_error, array_tmp0,
array_tmp1, array_tmp2, array_y_set_initial, array_complex_pole,
array_fact_2, array_y_higher, array_real_pole, array_poles,
array_y_higher_work, array_y_higher_work2, glob_last;
n := glob_max_terms;
m := n - 2;
while 10 <= m and (omniabs(array_y_higher[1, m]) < glob_small_float or
omniabs(array_y_higher[1, m - 1]) < glob_small_float or
omniabs(array_y_higher[1, m - 2]) < glob_small_float) do m := m - 1
end do;
if 10 < m then
rm0 := array_y_higher[1, m]/array_y_higher[1, m - 1];
rm1 := array_y_higher[1, m - 1]/array_y_higher[1, m - 2];
hdrc := convfloat(m - 1)*rm0 - convfloat(m - 2)*rm1;
if glob_small_float < omniabs(hdrc) then
rcs := glob_h/hdrc;
ord_no := convfloat(m - 1)*rm0/hdrc - convfloat(m) + 2.0;
array_real_pole[1, 1] := rcs;
array_real_pole[1, 2] := ord_no
else
array_real_pole[1, 1] := glob_large_float;
array_real_pole[1, 2] := glob_large_float
end if
else
array_real_pole[1, 1] := glob_large_float;
array_real_pole[1, 2] := glob_large_float
end if;
n := glob_max_terms - 2;
cnt := 0;
while cnt < 5 and 10 <= n do
if glob_small_float < omniabs(array_y_higher[1, n]) then
cnt := cnt + 1
else cnt := 0
end if;
n := n - 1
end do;
m := n + cnt;
if m <= 10 then
array_complex_pole[1, 1] := glob_large_float;
array_complex_pole[1, 2] := glob_large_float
elif glob_large_float <= omniabs(array_y_higher[1, m]) or
glob_large_float <= omniabs(array_y_higher[1, m - 1]) or
glob_large_float <= omniabs(array_y_higher[1, m - 2]) or
glob_large_float <= omniabs(array_y_higher[1, m - 3]) or
glob_large_float <= omniabs(array_y_higher[1, m - 4]) or
glob_large_float <= omniabs(array_y_higher[1, m - 5]) then
array_complex_pole[1, 1] := glob_large_float;
array_complex_pole[1, 2] := glob_large_float
else
rm0 := array_y_higher[1, m]/array_y_higher[1, m - 1];
rm1 := array_y_higher[1, m - 1]/array_y_higher[1, m - 2];
rm2 := array_y_higher[1, m - 2]/array_y_higher[1, m - 3];
rm3 := array_y_higher[1, m - 3]/array_y_higher[1, m - 4];
rm4 := array_y_higher[1, m - 4]/array_y_higher[1, m - 5];
nr1 := convfloat(m - 1)*rm0 - 2.0*convfloat(m - 2)*rm1
+ convfloat(m - 3)*rm2;
nr2 := convfloat(m - 2)*rm1 - 2.0*convfloat(m - 3)*rm2
+ convfloat(m - 4)*rm3;
dr1 := (-1)*(1.0)/rm1 + 2.0/rm2 - 1.0/rm3;
dr2 := (-1)*(1.0)/rm2 + 2.0/rm3 - 1.0/rm4;
ds1 := 3.0/rm1 - 8.0/rm2 + 5.0/rm3;
ds2 := 3.0/rm2 - 8.0/rm3 + 5.0/rm4;
if omniabs(nr1*dr2 - nr2*dr1) <= glob_small_float or
omniabs(dr1) <= glob_small_float then
array_complex_pole[1, 1] := glob_large_float;
array_complex_pole[1, 2] := glob_large_float
else
if glob_small_float < omniabs(nr1*dr2 - nr2*dr1) then
rcs := (ds1*dr2 - ds2*dr1 + dr1*dr2)/(nr1*dr2 - nr2*dr1);
ord_no := (rcs*nr1 - ds1)/(2.0*dr1) - convfloat(m)/2.0;
if glob_small_float < omniabs(rcs) then
if 0. < rcs then rad_c := sqrt(rcs)*glob_h
else rad_c := glob_large_float
end if
else rad_c := glob_large_float; ord_no := glob_large_float
end if
else rad_c := glob_large_float; ord_no := glob_large_float
end if
end if;
array_complex_pole[1, 1] := rad_c;
array_complex_pole[1, 2] := ord_no
end if;
found := false;
if not found and (array_real_pole[1, 1] = glob_large_float or
array_real_pole[1, 2] = glob_large_float) and
array_complex_pole[1, 1] <> glob_large_float and
array_complex_pole[1, 2] <> glob_large_float and
0. < array_complex_pole[1, 1] and 0. < array_complex_pole[1, 2] then
array_poles[1, 1] := array_complex_pole[1, 1];
array_poles[1, 2] := array_complex_pole[1, 2];
found := true;
array_type_pole[1] := 2;
if glob_display_flag then
omniout_str(ALWAYS, "Complex estimate of poles used")
end if
end if;
if not found and array_real_pole[1, 1] <> glob_large_float and
array_real_pole[1, 2] <> glob_large_float and
0. < array_real_pole[1, 1] and 0. < array_real_pole[1, 2] and (
array_complex_pole[1, 1] = glob_large_float or
array_complex_pole[1, 2] = glob_large_float or
array_complex_pole[1, 1] <= 0. or array_complex_pole[1, 2] <= 0.) then
array_poles[1, 1] := array_real_pole[1, 1];
array_poles[1, 2] := array_real_pole[1, 2];
found := true;
array_type_pole[1] := 1;
if glob_display_flag then
omniout_str(ALWAYS, "Real estimate of pole used")
end if
end if;
if not found and (array_real_pole[1, 1] = glob_large_float or
array_real_pole[1, 2] = glob_large_float) and (
array_complex_pole[1, 1] = glob_large_float or
array_complex_pole[1, 2] = glob_large_float) then
array_poles[1, 1] := glob_large_float;
array_poles[1, 2] := glob_large_float;
found := true;
array_type_pole[1] := 3;
if glob_display_flag then omniout_str(ALWAYS, "NO POLE") end if
end if;
if not found and array_real_pole[1, 1] < array_complex_pole[1, 1] and
0. < array_real_pole[1, 1] and 0. < array_real_pole[1, 2] then
array_poles[1, 1] := array_real_pole[1, 1];
array_poles[1, 2] := array_real_pole[1, 2];
found := true;
array_type_pole[1] := 1;
if glob_display_flag then
omniout_str(ALWAYS, "Real estimate of pole used")
end if
end if;
if not found and array_complex_pole[1, 1] <> glob_large_float and
array_complex_pole[1, 2] <> glob_large_float and
0. < array_complex_pole[1, 1] and 0. < array_complex_pole[1, 2] then
array_poles[1, 1] := array_complex_pole[1, 1];
array_poles[1, 2] := array_complex_pole[1, 2];
array_type_pole[1] := 2;
found := true;
if glob_display_flag then
omniout_str(ALWAYS, "Complex estimate of poles used")
end if
end if;
if not found then
array_poles[1, 1] := glob_large_float;
array_poles[1, 2] := glob_large_float;
array_type_pole[1] := 3;
if glob_display_flag then omniout_str(ALWAYS, "NO POLE") end if
end if;
array_pole[1] := glob_large_float;
array_pole[2] := glob_large_float;
if array_poles[1, 1] < array_pole[1] then
array_pole[1] := array_poles[1, 1];
array_pole[2] := array_poles[1, 2]
end if;
display_pole()
end proc
> # Begin Function number 7
> get_norms := proc()
> global
> DEBUGMASSIVE,
> DEBUGL,
> glob_max_terms,
> INFO,
> glob_iolevel,
> ALWAYS,
> #Top Generate Globals Decl
> glob_iter,
> glob_max_sec,
> glob_hmin,
> glob_clock_start_sec,
> glob_almost_1,
> min_in_hour,
> glob_dump,
> glob_log10_relerr,
> centuries_in_millinium,
> glob_max_opt_iter,
> glob_subiter_method,
> glob_log10abserr,
> glob_unchanged_h_cnt,
> glob_max_iter,
> glob_reached_optimal_h,
> glob_percent_done,
> MAX_UNCHANGED,
> glob_relerr,
> glob_hmin_init,
> glob_not_yet_finished,
> hours_in_day,
> djd_debug2,
> glob_log10relerr,
> glob_warned2,
> glob_optimal_start,
> glob_last_good_h,
> years_in_century,
> djd_debug,
> glob_normmax,
> glob_current_iter,
> glob_curr_iter_when_opt,
> glob_warned,
> glob_small_float,
> glob_no_eqs,
> glob_max_hours,
> glob_log10_abserr,
> glob_hmax,
> glob_max_minutes,
> glob_orig_start_sec,
> glob_smallish_float,
> glob_max_trunc_err,
> glob_max_rel_trunc_err,
> glob_abserr,
> glob_large_float,
> days_in_year,
> sec_in_minute,
> glob_good_digits,
> glob_log10normmin,
> glob_dump_analytic,
> glob_look_poles,
> glob_disp_incr,
> glob_optimal_done,
> glob_not_yet_start_msg,
> glob_initial_pass,
> glob_clock_sec,
> glob_html_log,
> glob_h,
> glob_display_flag,
> glob_optimal_expect_sec,
> glob_start,
> glob_optimal_clock_start_sec,
> #Bottom Generate Globals Decl
> #BEGIN CONST
> array_const_1D0,
> array_const_1,
> array_const_0D0,
> #END CONST
> array_y,
> array_x,
> array_norms,
> array_last_rel_error,
> array_type_pole,
> array_fact_1,
> array_pole,
> array_m1,
> array_y_init,
> array_1st_rel_error,
> array_tmp0,
> array_tmp1,
> array_tmp2,
> array_y_set_initial,
> array_complex_pole,
> array_fact_2,
> array_y_higher,
> array_real_pole,
> array_poles,
> array_y_higher_work,
> array_y_higher_work2,
> glob_last;
>
> local iii;
>
>
>
> if ( not glob_initial_pass) then # if number 2
> iii := 1;
> while (iii <= glob_max_terms) do # do number 2
> array_norms[iii] := 0.0;
> iii := iii + 1;
> od;# end do number 2
> ;
> #TOP GET NORMS
> iii := 1;
> while (iii <= glob_max_terms) do # do number 2
> if (omniabs(array_y[iii]) > array_norms[iii]) then # if number 3
> array_norms[iii] := omniabs(array_y[iii]);
> fi;# end if 3
> ;
> iii := iii + 1;
> od;# end do number 2
> #BOTTOM GET NORMS
> ;
> fi;# end if 2
> ;
>
> # End Function number 7
> end;
get_norms := proc()
local iii;
global DEBUGMASSIVE, DEBUGL, glob_max_terms, INFO, glob_iolevel, ALWAYS,
glob_iter, glob_max_sec, glob_hmin, glob_clock_start_sec, glob_almost_1,
min_in_hour, glob_dump, glob_log10_relerr, centuries_in_millinium,
glob_max_opt_iter, glob_subiter_method, glob_log10abserr,
glob_unchanged_h_cnt, glob_max_iter, glob_reached_optimal_h,
glob_percent_done, MAX_UNCHANGED, glob_relerr, glob_hmin_init,
glob_not_yet_finished, hours_in_day, djd_debug2, glob_log10relerr,
glob_warned2, glob_optimal_start, glob_last_good_h, years_in_century,
djd_debug, glob_normmax, glob_current_iter, glob_curr_iter_when_opt,
glob_warned, glob_small_float, glob_no_eqs, glob_max_hours,
glob_log10_abserr, glob_hmax, glob_max_minutes, glob_orig_start_sec,
glob_smallish_float, glob_max_trunc_err, glob_max_rel_trunc_err,
glob_abserr, glob_large_float, days_in_year, sec_in_minute,
glob_good_digits, glob_log10normmin, glob_dump_analytic, glob_look_poles,
glob_disp_incr, glob_optimal_done, glob_not_yet_start_msg,
glob_initial_pass, glob_clock_sec, glob_html_log, glob_h, glob_display_flag,
glob_optimal_expect_sec, glob_start, glob_optimal_clock_start_sec,
array_const_1D0, array_const_1, array_const_0D0, array_y, array_x,
array_norms, array_last_rel_error, array_type_pole, array_fact_1,
array_pole, array_m1, array_y_init, array_1st_rel_error, array_tmp0,
array_tmp1, array_tmp2, array_y_set_initial, array_complex_pole,
array_fact_2, array_y_higher, array_real_pole, array_poles,
array_y_higher_work, array_y_higher_work2, glob_last;
if not glob_initial_pass then
iii := 1;
while iii <= glob_max_terms do
array_norms[iii] := 0.; iii := iii + 1
end do;
iii := 1;
while iii <= glob_max_terms do
if array_norms[iii] < omniabs(array_y[iii]) then
array_norms[iii] := omniabs(array_y[iii])
end if;
iii := iii + 1
end do
end if
end proc
> # Begin Function number 8
> atomall := proc()
> global
> DEBUGMASSIVE,
> DEBUGL,
> glob_max_terms,
> INFO,
> glob_iolevel,
> ALWAYS,
> #Top Generate Globals Decl
> glob_iter,
> glob_max_sec,
> glob_hmin,
> glob_clock_start_sec,
> glob_almost_1,
> min_in_hour,
> glob_dump,
> glob_log10_relerr,
> centuries_in_millinium,
> glob_max_opt_iter,
> glob_subiter_method,
> glob_log10abserr,
> glob_unchanged_h_cnt,
> glob_max_iter,
> glob_reached_optimal_h,
> glob_percent_done,
> MAX_UNCHANGED,
> glob_relerr,
> glob_hmin_init,
> glob_not_yet_finished,
> hours_in_day,
> djd_debug2,
> glob_log10relerr,
> glob_warned2,
> glob_optimal_start,
> glob_last_good_h,
> years_in_century,
> djd_debug,
> glob_normmax,
> glob_current_iter,
> glob_curr_iter_when_opt,
> glob_warned,
> glob_small_float,
> glob_no_eqs,
> glob_max_hours,
> glob_log10_abserr,
> glob_hmax,
> glob_max_minutes,
> glob_orig_start_sec,
> glob_smallish_float,
> glob_max_trunc_err,
> glob_max_rel_trunc_err,
> glob_abserr,
> glob_large_float,
> days_in_year,
> sec_in_minute,
> glob_good_digits,
> glob_log10normmin,
> glob_dump_analytic,
> glob_look_poles,
> glob_disp_incr,
> glob_optimal_done,
> glob_not_yet_start_msg,
> glob_initial_pass,
> glob_clock_sec,
> glob_html_log,
> glob_h,
> glob_display_flag,
> glob_optimal_expect_sec,
> glob_start,
> glob_optimal_clock_start_sec,
> #Bottom Generate Globals Decl
> #BEGIN CONST
> array_const_1D0,
> array_const_1,
> array_const_0D0,
> #END CONST
> array_y,
> array_x,
> array_norms,
> array_last_rel_error,
> array_type_pole,
> array_fact_1,
> array_pole,
> array_m1,
> array_y_init,
> array_1st_rel_error,
> array_tmp0,
> array_tmp1,
> array_tmp2,
> array_y_set_initial,
> array_complex_pole,
> array_fact_2,
> array_y_higher,
> array_real_pole,
> array_poles,
> array_y_higher_work,
> array_y_higher_work2,
> glob_last;
>
> local kkk, order_d, adj2, temporary, term;
>
>
>
>
>
> #TOP ATOMALL
> #END OUTFILE1
> #BEGIN ATOMHDR1
> #emit pre add CONST FULL $eq_no = 1 i = 1
> array_tmp1[1] := array_const_0D0[1] + array_y[1];
> #emit pre sub FULL - CONST $eq_no = 1 i = 1
> array_tmp2[1] := array_tmp1[1] - array_const_1D0[1];
> #emit pre assign xxx $eq_no = 1 i = 1 $min_hdrs = 5
> if ( not array_y_set_initial[1,2]) then # if number 1
> if (1 <= glob_max_terms) then # if number 2
> temporary := array_tmp2[1] * expt(glob_h , (1)) * factorial_3(0,1);
> array_y[2] := temporary;
> array_y_higher[1,2] := temporary;
> temporary := temporary / glob_h * (2.0);
> array_y_higher[2,1] := temporary
> ;
> fi;# end if 2
> ;
> fi;# end if 1
> ;
> kkk := 2;
> #END ATOMHDR1
> #BEGIN ATOMHDR2
> #emit pre add CONST FULL $eq_no = 1 i = 2
> array_tmp1[2] := array_y[2];
> #emit pre sub FULL CONST $eq_no = 1 i = 2
> array_tmp2[2] := array_tmp1[2];
> #emit pre assign xxx $eq_no = 1 i = 2 $min_hdrs = 5
> if ( not array_y_set_initial[1,3]) then # if number 1
> if (2 <= glob_max_terms) then # if number 2
> temporary := array_tmp2[2] * expt(glob_h , (1)) * factorial_3(1,2);
> array_y[3] := temporary;
> array_y_higher[1,3] := temporary;
> temporary := temporary / glob_h * (2.0);
> array_y_higher[2,2] := temporary
> ;
> fi;# end if 2
> ;
> fi;# end if 1
> ;
> kkk := 3;
> #END ATOMHDR2
> #BEGIN ATOMHDR3
> #emit pre add CONST FULL $eq_no = 1 i = 3
> array_tmp1[3] := array_y[3];
> #emit pre sub FULL CONST $eq_no = 1 i = 3
> array_tmp2[3] := array_tmp1[3];
> #emit pre assign xxx $eq_no = 1 i = 3 $min_hdrs = 5
> if ( not array_y_set_initial[1,4]) then # if number 1
> if (3 <= glob_max_terms) then # if number 2
> temporary := array_tmp2[3] * expt(glob_h , (1)) * factorial_3(2,3);
> array_y[4] := temporary;
> array_y_higher[1,4] := temporary;
> temporary := temporary / glob_h * (2.0);
> array_y_higher[2,3] := temporary
> ;
> fi;# end if 2
> ;
> fi;# end if 1
> ;
> kkk := 4;
> #END ATOMHDR3
> #BEGIN ATOMHDR4
> #emit pre add CONST FULL $eq_no = 1 i = 4
> array_tmp1[4] := array_y[4];
> #emit pre sub FULL CONST $eq_no = 1 i = 4
> array_tmp2[4] := array_tmp1[4];
> #emit pre assign xxx $eq_no = 1 i = 4 $min_hdrs = 5
> if ( not array_y_set_initial[1,5]) then # if number 1
> if (4 <= glob_max_terms) then # if number 2
> temporary := array_tmp2[4] * expt(glob_h , (1)) * factorial_3(3,4);
> array_y[5] := temporary;
> array_y_higher[1,5] := temporary;
> temporary := temporary / glob_h * (2.0);
> array_y_higher[2,4] := temporary
> ;
> fi;# end if 2
> ;
> fi;# end if 1
> ;
> kkk := 5;
> #END ATOMHDR4
> #BEGIN ATOMHDR5
> #emit pre add CONST FULL $eq_no = 1 i = 5
> array_tmp1[5] := array_y[5];
> #emit pre sub FULL CONST $eq_no = 1 i = 5
> array_tmp2[5] := array_tmp1[5];
> #emit pre assign xxx $eq_no = 1 i = 5 $min_hdrs = 5
> if ( not array_y_set_initial[1,6]) then # if number 1
> if (5 <= glob_max_terms) then # if number 2
> temporary := array_tmp2[5] * expt(glob_h , (1)) * factorial_3(4,5);
> array_y[6] := temporary;
> array_y_higher[1,6] := temporary;
> temporary := temporary / glob_h * (2.0);
> array_y_higher[2,5] := temporary
> ;
> fi;# end if 2
> ;
> fi;# end if 1
> ;
> kkk := 6;
> #END ATOMHDR5
> #BEGIN OUTFILE3
> #Top Atomall While Loop-- outfile3
> while (kkk <= glob_max_terms) do # do number 1
> #END OUTFILE3
> #BEGIN OUTFILE4
> #emit NOT FULL - FULL add $eq_no = 1
> array_tmp1[kkk] := array_y[kkk];
> #emit FULL - NOT FULL sub $eq_no = 1
> array_tmp2[kkk] := array_tmp1[kkk];
> #emit assign $eq_no = 1
> order_d := 1;
> if (kkk + order_d + 1 <= glob_max_terms) then # if number 1
> if ( not array_y_set_initial[1,kkk + order_d]) then # if number 2
> temporary := array_tmp2[kkk] * expt(glob_h , (order_d)) / factorial_3((kkk - 1),(kkk + order_d - 1));
> array_y[kkk + order_d] := temporary;
> array_y_higher[1,kkk + order_d] := temporary;
> term := kkk + order_d - 1;
> adj2 := 2;
> while ((adj2 <= order_d + 1) and (term >= 1)) do # do number 2
> temporary := temporary / glob_h * convfp(adj2);
> array_y_higher[adj2,term] := temporary;
> adj2 := adj2 + 1;
> term := term - 1;
> od;# end do number 2
> fi;# end if 2
> fi;# end if 1
> ;
> kkk := kkk + 1;
> od;# end do number 1
> ;
> #BOTTOM ATOMALL
> #END OUTFILE4
> #BEGIN OUTFILE5
>
> #BOTTOM ATOMALL ???
> # End Function number 8
> end;
atomall := proc()
local kkk, order_d, adj2, temporary, term;
global DEBUGMASSIVE, DEBUGL, glob_max_terms, INFO, glob_iolevel, ALWAYS,
glob_iter, glob_max_sec, glob_hmin, glob_clock_start_sec, glob_almost_1,
min_in_hour, glob_dump, glob_log10_relerr, centuries_in_millinium,
glob_max_opt_iter, glob_subiter_method, glob_log10abserr,
glob_unchanged_h_cnt, glob_max_iter, glob_reached_optimal_h,
glob_percent_done, MAX_UNCHANGED, glob_relerr, glob_hmin_init,
glob_not_yet_finished, hours_in_day, djd_debug2, glob_log10relerr,
glob_warned2, glob_optimal_start, glob_last_good_h, years_in_century,
djd_debug, glob_normmax, glob_current_iter, glob_curr_iter_when_opt,
glob_warned, glob_small_float, glob_no_eqs, glob_max_hours,
glob_log10_abserr, glob_hmax, glob_max_minutes, glob_orig_start_sec,
glob_smallish_float, glob_max_trunc_err, glob_max_rel_trunc_err,
glob_abserr, glob_large_float, days_in_year, sec_in_minute,
glob_good_digits, glob_log10normmin, glob_dump_analytic, glob_look_poles,
glob_disp_incr, glob_optimal_done, glob_not_yet_start_msg,
glob_initial_pass, glob_clock_sec, glob_html_log, glob_h, glob_display_flag,
glob_optimal_expect_sec, glob_start, glob_optimal_clock_start_sec,
array_const_1D0, array_const_1, array_const_0D0, array_y, array_x,
array_norms, array_last_rel_error, array_type_pole, array_fact_1,
array_pole, array_m1, array_y_init, array_1st_rel_error, array_tmp0,
array_tmp1, array_tmp2, array_y_set_initial, array_complex_pole,
array_fact_2, array_y_higher, array_real_pole, array_poles,
array_y_higher_work, array_y_higher_work2, glob_last;
array_tmp1[1] := array_const_0D0[1] + array_y[1];
array_tmp2[1] := array_tmp1[1] - array_const_1D0[1];
if not array_y_set_initial[1, 2] then
if 1 <= glob_max_terms then
temporary := array_tmp2[1]*expt(glob_h, 1)*factorial_3(0, 1);
array_y[2] := temporary;
array_y_higher[1, 2] := temporary;
temporary := temporary*2.0/glob_h;
array_y_higher[2, 1] := temporary
end if
end if;
kkk := 2;
array_tmp1[2] := array_y[2];
array_tmp2[2] := array_tmp1[2];
if not array_y_set_initial[1, 3] then
if 2 <= glob_max_terms then
temporary := array_tmp2[2]*expt(glob_h, 1)*factorial_3(1, 2);
array_y[3] := temporary;
array_y_higher[1, 3] := temporary;
temporary := temporary*2.0/glob_h;
array_y_higher[2, 2] := temporary
end if
end if;
kkk := 3;
array_tmp1[3] := array_y[3];
array_tmp2[3] := array_tmp1[3];
if not array_y_set_initial[1, 4] then
if 3 <= glob_max_terms then
temporary := array_tmp2[3]*expt(glob_h, 1)*factorial_3(2, 3);
array_y[4] := temporary;
array_y_higher[1, 4] := temporary;
temporary := temporary*2.0/glob_h;
array_y_higher[2, 3] := temporary
end if
end if;
kkk := 4;
array_tmp1[4] := array_y[4];
array_tmp2[4] := array_tmp1[4];
if not array_y_set_initial[1, 5] then
if 4 <= glob_max_terms then
temporary := array_tmp2[4]*expt(glob_h, 1)*factorial_3(3, 4);
array_y[5] := temporary;
array_y_higher[1, 5] := temporary;
temporary := temporary*2.0/glob_h;
array_y_higher[2, 4] := temporary
end if
end if;
kkk := 5;
array_tmp1[5] := array_y[5];
array_tmp2[5] := array_tmp1[5];
if not array_y_set_initial[1, 6] then
if 5 <= glob_max_terms then
temporary := array_tmp2[5]*expt(glob_h, 1)*factorial_3(4, 5);
array_y[6] := temporary;
array_y_higher[1, 6] := temporary;
temporary := temporary*2.0/glob_h;
array_y_higher[2, 5] := temporary
end if
end if;
kkk := 6;
while kkk <= glob_max_terms do
array_tmp1[kkk] := array_y[kkk];
array_tmp2[kkk] := array_tmp1[kkk];
order_d := 1;
if kkk + order_d + 1 <= glob_max_terms then
if not array_y_set_initial[1, kkk + order_d] then
temporary := array_tmp2[kkk]*expt(glob_h, order_d)/
factorial_3(kkk - 1, kkk + order_d - 1);
array_y[kkk + order_d] := temporary;
array_y_higher[1, kkk + order_d] := temporary;
term := kkk + order_d - 1;
adj2 := 2;
while adj2 <= order_d + 1 and 1 <= term do
temporary := temporary*convfp(adj2)/glob_h;
array_y_higher[adj2, term] := temporary;
adj2 := adj2 + 1;
term := term - 1
end do
end if
end if;
kkk := kkk + 1
end do
end proc
> #BEGIN ATS LIBRARY BLOCK
> omniout_str := proc(iolevel,str)
> global glob_iolevel;
> if (glob_iolevel >= iolevel) then
> printf("%s\n",str);
> fi;
> # End Function number 1
> end;
omniout_str := proc(iolevel, str)
global glob_iolevel;
if iolevel <= glob_iolevel then printf("%s\n", str) end if
end proc
> omniout_str_noeol := proc(iolevel,str)
> global glob_iolevel;
> if (glob_iolevel >= iolevel) then
> printf("%s",str);
> fi;
> # End Function number 1
> end;
omniout_str_noeol := proc(iolevel, str)
global glob_iolevel;
if iolevel <= glob_iolevel then printf("%s", str) end if
end proc
> omniout_labstr := proc(iolevel,label,str)
> global glob_iolevel;
> if (glob_iolevel >= iolevel) then
> print(label,str);
> fi;
> # End Function number 1
> end;
omniout_labstr := proc(iolevel, label, str)
global glob_iolevel;
if iolevel <= glob_iolevel then print(label, str) end if
end proc
> omniout_float := proc(iolevel,prelabel,prelen,value,vallen,postlabel)
> global glob_iolevel;
> if (glob_iolevel >= iolevel) then
> if vallen = 4 then
> printf("%-30s = %-42.4g %s \n",prelabel,value, postlabel);
> else
> printf("%-30s = %-42.32g %s \n",prelabel,value, postlabel);
> fi;
> fi;
> # End Function number 1
> end;
omniout_float := proc(iolevel, prelabel, prelen, value, vallen, postlabel)
global glob_iolevel;
if iolevel <= glob_iolevel then
if vallen = 4 then
printf("%-30s = %-42.4g %s \n", prelabel, value, postlabel)
else printf("%-30s = %-42.32g %s \n", prelabel, value, postlabel)
end if
end if
end proc
> omniout_int := proc(iolevel,prelabel,prelen,value,vallen,postlabel)
> global glob_iolevel;
> if (glob_iolevel >= iolevel) then
> if vallen = 5 then
> printf("%-30s = %-32d %s\n",prelabel,value, postlabel);
> else
> printf("%-30s = %-32d %s \n",prelabel,value, postlabel);
> fi;
> fi;
> # End Function number 1
> end;
omniout_int := proc(iolevel, prelabel, prelen, value, vallen, postlabel)
global glob_iolevel;
if iolevel <= glob_iolevel then
if vallen = 5 then
printf("%-30s = %-32d %s\n", prelabel, value, postlabel)
else printf("%-30s = %-32d %s \n", prelabel, value, postlabel)
end if
end if
end proc
> omniout_float_arr := proc(iolevel,prelabel,elemnt,prelen,value,vallen,postlabel)
> global glob_iolevel;
> if (glob_iolevel >= iolevel) then
> print(prelabel,"[",elemnt,"]",value, postlabel);
> fi;
> # End Function number 1
> end;
omniout_float_arr := proc(
iolevel, prelabel, elemnt, prelen, value, vallen, postlabel)
global glob_iolevel;
if iolevel <= glob_iolevel then
print(prelabel, "[", elemnt, "]", value, postlabel)
end if
end proc
> dump_series := proc(iolevel,dump_label,series_name,
> array_series,numb)
> global glob_iolevel;
> local i;
> if (glob_iolevel >= iolevel) then
> i := 1;
> while (i <= numb) do
> print(dump_label,series_name
> ,i,array_series[i]);
> i := i + 1;
> od;
> fi;
> # End Function number 1
> end;
dump_series := proc(iolevel, dump_label, series_name, array_series, numb)
local i;
global glob_iolevel;
if iolevel <= glob_iolevel then
i := 1;
while i <= numb do
print(dump_label, series_name, i, array_series[i]); i := i + 1
end do
end if
end proc
> dump_series_2 := proc(iolevel,dump_label,series_name2,
> array_series2,numb,subnum,array_x)
> global glob_iolevel;
> local i,sub,ts_term;
> if (glob_iolevel >= iolevel) then
> sub := 1;
> while (sub <= subnum) do
> i := 1;
> while (i <= numb) do
> print(dump_label,series_name2,sub,i,array_series2[sub,i]);
> od;
> sub := sub + 1;
> od;
> fi;
> # End Function number 1
> end;
dump_series_2 := proc(
iolevel, dump_label, series_name2, array_series2, numb, subnum, array_x)
local i, sub, ts_term;
global glob_iolevel;
if iolevel <= glob_iolevel then
sub := 1;
while sub <= subnum do
i := 1;
while i <= numb do print(dump_label, series_name2, sub, i,
array_series2[sub, i])
end do;
sub := sub + 1
end do
end if
end proc
> cs_info := proc(iolevel,str)
> global glob_iolevel,glob_correct_start_flag,glob_h,glob_reached_optimal_h;
> if (glob_iolevel >= iolevel) then
> print("cs_info " , str , " glob_correct_start_flag = " , glob_correct_start_flag , "glob_h := " , glob_h , "glob_reached_optimal_h := " , glob_reached_optimal_h)
> fi;
> # End Function number 1
> end;
cs_info := proc(iolevel, str)
global
glob_iolevel, glob_correct_start_flag, glob_h, glob_reached_optimal_h;
if iolevel <= glob_iolevel then print("cs_info ", str,
" glob_correct_start_flag = ", glob_correct_start_flag,
"glob_h := ", glob_h, "glob_reached_optimal_h := ",
glob_reached_optimal_h)
end if
end proc
> # Begin Function number 2
> logitem_time := proc(fd,secs_in)
> global centuries_in_millinium, days_in_year, hours_in_day, min_in_hour, sec_in_minute, years_in_century;
> local cent_int, centuries, days, days_int, hours, hours_int, millinium_int, milliniums, minutes, minutes_int, sec_in_millinium, sec_int, seconds, secs, years, years_int;
> secs := (secs_in);
> fprintf(fd,"
");
> if (secs >= 0.0) then # if number 1
> sec_in_millinium := convfloat(sec_in_minute * min_in_hour * hours_in_day * days_in_year * years_in_century * centuries_in_millinium);
> milliniums := convfloat(secs / sec_in_millinium);
> millinium_int := floor(milliniums);
> centuries := (milliniums - millinium_int)*centuries_in_millinium;
> cent_int := floor(centuries);
> years := (centuries - cent_int) * years_in_century;
> years_int := floor(years);
> days := (years - years_int) * days_in_year;
> days_int := floor(days);
> hours := (days - days_int) * hours_in_day;
> hours_int := floor(hours);
> minutes := (hours - hours_int) * min_in_hour;
> minutes_int := floor(minutes);
> seconds := (minutes - minutes_int) * sec_in_minute;
> sec_int := floor(seconds);
> if (millinium_int > 0) then # if number 2
> fprintf(fd,"%d Millinia %d Centuries %d Years %d Days %d Hours %d Minutes %d Seconds",millinium_int,cent_int,years_int,days_int,hours_int,minutes_int,sec_int);
> elif (cent_int > 0) then # if number 3
> fprintf(fd,"%d Centuries %d Years %d Days %d Hours %d Minutes %d Seconds",cent_int,years_int,days_int,hours_int,minutes_int,sec_int);
> elif (years_int > 0) then # if number 4
> fprintf(fd,"%d Years %d Days %d Hours %d Minutes %d Seconds",years_int,days_int,hours_int,minutes_int,sec_int);
> elif (days_int > 0) then # if number 5
> fprintf(fd,"%d Days %d Hours %d Minutes %d Seconds",days_int,hours_int,minutes_int,sec_int);
> elif (hours_int > 0) then # if number 6
> fprintf(fd,"%d Hours %d Minutes %d Seconds",hours_int,minutes_int,sec_int);
> elif (minutes_int > 0) then # if number 7
> fprintf(fd,"%d Minutes %d Seconds",minutes_int,sec_int);
> else
> fprintf(fd,"%d Seconds",sec_int);
> fi;# end if 7
> else
> fprintf(fd,"Unknown");
> fi;# end if 6
> fprintf(fd," | ");
> # End Function number 2
> end;
logitem_time := proc(fd, secs_in)
local cent_int, centuries, days, days_int, hours, hours_int, millinium_int,
milliniums, minutes, minutes_int, sec_in_millinium, sec_int, seconds, secs,
years, years_int;
global centuries_in_millinium, days_in_year, hours_in_day, min_in_hour,
sec_in_minute, years_in_century;
secs := secs_in;
fprintf(fd, "");
if 0. <= secs then
sec_in_millinium := convfloat(sec_in_minute*min_in_hour*
hours_in_day*days_in_year*years_in_century*
centuries_in_millinium);
milliniums := convfloat(secs/sec_in_millinium);
millinium_int := floor(milliniums);
centuries := (milliniums - millinium_int)*centuries_in_millinium;
cent_int := floor(centuries);
years := (centuries - cent_int)*years_in_century;
years_int := floor(years);
days := (years - years_int)*days_in_year;
days_int := floor(days);
hours := (days - days_int)*hours_in_day;
hours_int := floor(hours);
minutes := (hours - hours_int)*min_in_hour;
minutes_int := floor(minutes);
seconds := (minutes - minutes_int)*sec_in_minute;
sec_int := floor(seconds);
if 0 < millinium_int then fprintf(fd, "%d Millinia %d Centuries %\
d Years %d Days %d Hours %d Minutes %d Seconds", millinium_int,
cent_int, years_int, days_int, hours_int, minutes_int, sec_int)
elif 0 < cent_int then fprintf(fd,
"%d Centuries %d Years %d Days %d Hours %d Minutes %d Seconds",
cent_int, years_int, days_int, hours_int, minutes_int, sec_int)
elif 0 < years_int then fprintf(fd,
"%d Years %d Days %d Hours %d Minutes %d Seconds", years_int,
days_int, hours_int, minutes_int, sec_int)
elif 0 < days_int then fprintf(fd,
"%d Days %d Hours %d Minutes %d Seconds", days_int, hours_int,
minutes_int, sec_int)
elif 0 < hours_int then fprintf(fd,
"%d Hours %d Minutes %d Seconds", hours_int, minutes_int,
sec_int)
elif 0 < minutes_int then
fprintf(fd, "%d Minutes %d Seconds", minutes_int, sec_int)
else fprintf(fd, "%d Seconds", sec_int)
end if
else fprintf(fd, "Unknown")
end if;
fprintf(fd, " | ")
end proc
> omniout_timestr := proc (secs_in)
> global centuries_in_millinium, days_in_year, hours_in_day, min_in_hour, sec_in_minute, years_in_century;
> local cent_int, centuries, days, days_int, hours, hours_int, millinium_int, milliniums, minutes, minutes_int, sec_in_millinium, sec_int, seconds, secs, years, years_int;
> secs := convfloat(secs_in);
> if (secs >= 0.0) then # if number 6
> sec_in_millinium := convfloat(sec_in_minute * min_in_hour * hours_in_day * days_in_year * years_in_century * centuries_in_millinium);
> milliniums := convfloat(secs / sec_in_millinium);
> millinium_int := floor(milliniums);
> centuries := (milliniums - millinium_int)*centuries_in_millinium;
> cent_int := floor(centuries);
> years := (centuries - cent_int) * years_in_century;
> years_int := floor(years);
> days := (years - years_int) * days_in_year;
> days_int := floor(days);
> hours := (days - days_int) * hours_in_day;
> hours_int := floor(hours);
> minutes := (hours - hours_int) * min_in_hour;
> minutes_int := floor(minutes);
> seconds := (minutes - minutes_int) * sec_in_minute;
> sec_int := floor(seconds);
>
> if (millinium_int > 0) then # if number 7
> printf(" = %d Millinia %d Centuries %d Years %d Days %d Hours %d Minutes %d Seconds\n",millinium_int,cent_int,years_int,days_int,hours_int,minutes_int,sec_int);
> elif (cent_int > 0) then # if number 8
> printf(" = %d Centuries %d Years %d Days %d Hours %d Minutes %d Seconds\n",cent_int,years_int,days_int,hours_int,minutes_int,sec_int);
> elif (years_int > 0) then # if number 9
> printf(" = %d Years %d Days %d Hours %d Minutes %d Seconds\n",years_int,days_int,hours_int,minutes_int,sec_int);
> elif (days_int > 0) then # if number 10
> printf(" = %d Days %d Hours %d Minutes %d Seconds\n",days_int,hours_int,minutes_int,sec_int);
> elif (hours_int > 0) then # if number 11
> printf(" = %d Hours %d Minutes %d Seconds\n",hours_int,minutes_int,sec_int);
> elif (minutes_int > 0) then # if number 12
> printf(" = %d Minutes %d Seconds\n",minutes_int,sec_int);
> else
> printf(" = %d Seconds\n",sec_int);
> fi;# end if 12
> else
> printf(" Unknown\n");
> fi;# end if 11
> # End Function number 2
> end;
omniout_timestr := proc(secs_in)
local cent_int, centuries, days, days_int, hours, hours_int, millinium_int,
milliniums, minutes, minutes_int, sec_in_millinium, sec_int, seconds, secs,
years, years_int;
global centuries_in_millinium, days_in_year, hours_in_day, min_in_hour,
sec_in_minute, years_in_century;
secs := convfloat(secs_in);
if 0. <= secs then
sec_in_millinium := convfloat(sec_in_minute*min_in_hour*
hours_in_day*days_in_year*years_in_century*
centuries_in_millinium);
milliniums := convfloat(secs/sec_in_millinium);
millinium_int := floor(milliniums);
centuries := (milliniums - millinium_int)*centuries_in_millinium;
cent_int := floor(centuries);
years := (centuries - cent_int)*years_in_century;
years_int := floor(years);
days := (years - years_int)*days_in_year;
days_int := floor(days);
hours := (days - days_int)*hours_in_day;
hours_int := floor(hours);
minutes := (hours - hours_int)*min_in_hour;
minutes_int := floor(minutes);
seconds := (minutes - minutes_int)*sec_in_minute;
sec_int := floor(seconds);
if 0 < millinium_int then printf(" = %d Millinia %d Centuries %d\
Years %d Days %d Hours %d Minutes %d Seconds\n", millinium_int,
cent_int, years_int, days_int, hours_int, minutes_int, sec_int)
elif 0 < cent_int then printf(" = %d Centuries %d Years %d Days \
%d Hours %d Minutes %d Seconds\n", cent_int, years_int,
days_int, hours_int, minutes_int, sec_int)
elif 0 < years_int then printf(
" = %d Years %d Days %d Hours %d Minutes %d Seconds\n",
years_int, days_int, hours_int, minutes_int, sec_int)
elif 0 < days_int then printf(
" = %d Days %d Hours %d Minutes %d Seconds\n", days_int,
hours_int, minutes_int, sec_int)
elif 0 < hours_int then printf(
" = %d Hours %d Minutes %d Seconds\n", hours_int, minutes_int,
sec_int)
elif 0 < minutes_int then
printf(" = %d Minutes %d Seconds\n", minutes_int, sec_int)
else printf(" = %d Seconds\n", sec_int)
end if
else printf(" Unknown\n")
end if
end proc
> # Begin Function number 3
> ats := proc(
> mmm_ats,array_a,array_b,jjj_ats)
> local iii_ats, lll_ats,ma_ats, ret_ats;
>
>
>
>
>
> ret_ats := 0.0;
> if (jjj_ats <= mmm_ats) then # if number 11
> ma_ats := mmm_ats + 1;
> iii_ats := jjj_ats;
> while (iii_ats <= mmm_ats) do # do number 1
> lll_ats := ma_ats - iii_ats;
> ret_ats := ret_ats + array_a[iii_ats]*array_b[lll_ats];
> iii_ats := iii_ats + 1;
> od;# end do number 1
> fi;# end if 11
> ;
> ret_ats;
>
> # End Function number 3
> end;
ats := proc(mmm_ats, array_a, array_b, jjj_ats)
local iii_ats, lll_ats, ma_ats, ret_ats;
ret_ats := 0.;
if jjj_ats <= mmm_ats then
ma_ats := mmm_ats + 1;
iii_ats := jjj_ats;
while iii_ats <= mmm_ats do
lll_ats := ma_ats - iii_ats;
ret_ats := ret_ats + array_a[iii_ats]*array_b[lll_ats];
iii_ats := iii_ats + 1
end do
end if;
ret_ats
end proc
> # Begin Function number 4
> att := proc(
> mmm_att,array_aa,array_bb,jjj_att)
> global glob_max_terms;
> local al_att, iii_att,lll_att, ma_att, ret_att;
>
>
>
>
>
> ret_att := 0.0;
> if (jjj_att <= mmm_att) then # if number 11
> ma_att := mmm_att + 2;
> iii_att := jjj_att;
> while (iii_att <= mmm_att) do # do number 1
> lll_att := ma_att - iii_att;
> al_att := (lll_att - 1);
> if (lll_att <= glob_max_terms) then # if number 12
> ret_att := ret_att + array_aa[iii_att]*array_bb[lll_att]* convfp(al_att);
> fi;# end if 12
> ;
> iii_att := iii_att + 1;
> od;# end do number 1
> ;
> ret_att := ret_att / convfp(mmm_att) ;
> fi;# end if 11
> ;
> ret_att;
>
> # End Function number 4
> end;
att := proc(mmm_att, array_aa, array_bb, jjj_att)
local al_att, iii_att, lll_att, ma_att, ret_att;
global glob_max_terms;
ret_att := 0.;
if jjj_att <= mmm_att then
ma_att := mmm_att + 2;
iii_att := jjj_att;
while iii_att <= mmm_att do
lll_att := ma_att - iii_att;
al_att := lll_att - 1;
if lll_att <= glob_max_terms then ret_att := ret_att
+ array_aa[iii_att]*array_bb[lll_att]*convfp(al_att)
end if;
iii_att := iii_att + 1
end do;
ret_att := ret_att/convfp(mmm_att)
end if;
ret_att
end proc
> # Begin Function number 5
> display_pole := proc()
> global ALWAYS,glob_display_flag, glob_large_float, array_pole;
> if ((array_pole[1] <> glob_large_float) and (array_pole[1] > 0.0) and (array_pole[2] <> glob_large_float) and (array_pole[2]> 0.0) and glob_display_flag) then # if number 11
> omniout_float(ALWAYS,"Radius of convergence ",4, array_pole[1],4," ");
> omniout_float(ALWAYS,"Order of pole ",4, array_pole[2],4," ");
> fi;# end if 11
> # End Function number 5
> end;
display_pole := proc()
global ALWAYS, glob_display_flag, glob_large_float, array_pole;
if array_pole[1] <> glob_large_float and 0. < array_pole[1] and
array_pole[2] <> glob_large_float and 0. < array_pole[2] and
glob_display_flag then
omniout_float(ALWAYS, "Radius of convergence ", 4,
array_pole[1], 4, " ");
omniout_float(ALWAYS, "Order of pole ", 4,
array_pole[2], 4, " ")
end if
end proc
> # Begin Function number 6
> logditto := proc(file)
> fprintf(file,"");
> fprintf(file,"ditto");
> fprintf(file," | ");
> # End Function number 6
> end;
logditto := proc(file)
fprintf(file, ""); fprintf(file, "ditto"); fprintf(file, " | ")
end proc
> # Begin Function number 7
> logitem_integer := proc(file,n)
> fprintf(file,"");
> fprintf(file,"%d",n);
> fprintf(file," | ");
> # End Function number 7
> end;
logitem_integer := proc(file, n)
fprintf(file, ""); fprintf(file, "%d", n); fprintf(file, " | ")
end proc
> # Begin Function number 8
> logitem_str := proc(file,str)
> fprintf(file,"");
> fprintf(file,str);
> fprintf(file," | ");
> # End Function number 8
> end;
logitem_str := proc(file, str)
fprintf(file, ""); fprintf(file, str); fprintf(file, " | ")
end proc
> # Begin Function number 9
> logitem_good_digits := proc(file,rel_error)
> global glob_small_float;
>
> local good_digits;
>
>
> fprintf(file,"");
> if (rel_error <> -1.0) then # if number 11
> if (rel_error <> 0.0) then # if number 12
> good_digits := -trunc(log10(rel_error/100.0));
> fprintf(file,"%d",good_digits);
> else
> good_digits := Digits;
> fprintf(file,"%d",good_digits);
> fi;# end if 12
> ;
> else
> fprintf(file,"Unknown");
> fi;# end if 11
> ;
> fprintf(file," | ");
>
> # End Function number 9
> end;
logitem_good_digits := proc(file, rel_error)
local good_digits;
global glob_small_float;
fprintf(file, "");
if rel_error <> -1.0 then
if rel_error <> 0. then
good_digits := -trunc(log10(rel_error/100.0));
fprintf(file, "%d", good_digits)
else good_digits := Digits; fprintf(file, "%d", good_digits)
end if
else fprintf(file, "Unknown")
end if;
fprintf(file, " | ")
end proc
> # Begin Function number 10
> log_revs := proc(file,revs)
> fprintf(file,revs);
> # End Function number 10
> end;
log_revs := proc(file, revs) fprintf(file, revs) end proc
> # Begin Function number 11
> logitem_float := proc(file,x)
> fprintf(file,"");
> fprintf(file,"%g",x);
> fprintf(file," | ");
> # End Function number 11
> end;
logitem_float := proc(file, x)
fprintf(file, ""); fprintf(file, "%g", x); fprintf(file, " | ")
end proc
> # Begin Function number 12
> logitem_pole := proc(file,pole)
> fprintf(file,"");
> if (pole = 0) then # if number 11
> fprintf(file,"NA");
> elif (pole = 1) then # if number 12
> fprintf(file,"Real");
> elif (pole = 2) then # if number 13
> fprintf(file,"Complex");
> else
> fprintf(file,"No Pole");
> fi;# end if 13
> fprintf(file," | ");
> # End Function number 12
> end;
logitem_pole := proc(file, pole)
fprintf(file, "");
if pole = 0 then fprintf(file, "NA")
elif pole = 1 then fprintf(file, "Real")
elif pole = 2 then fprintf(file, "Complex")
else fprintf(file, "No Pole")
end if;
fprintf(file, " | ")
end proc
> # Begin Function number 13
> logstart := proc(file)
> fprintf(file,"");
> # End Function number 13
> end;
logstart := proc(file) fprintf(file, "
") end proc
> # Begin Function number 14
> logend := proc(file)
> fprintf(file,"
\n");
> # End Function number 14
> end;
logend := proc(file) fprintf(file, "\n") end proc
> # Begin Function number 15
> chk_data := proc()
> global glob_max_iter,ALWAYS, glob_max_terms;
> local errflag;
>
>
>
> errflag := false;
>
> if ((glob_max_terms < 15) or (glob_max_terms > 512)) then # if number 13
> omniout_str(ALWAYS,"Illegal max_terms = -- Using 30");
> glob_max_terms := 30;
> fi;# end if 13
> ;
> if (glob_max_iter < 2) then # if number 13
> omniout_str(ALWAYS,"Illegal max_iter");
> errflag := true;
> fi;# end if 13
> ;
> if (errflag) then # if number 13
>
> quit;
> fi;# end if 13
>
> # End Function number 15
> end;
chk_data := proc()
local errflag;
global glob_max_iter, ALWAYS, glob_max_terms;
errflag := false;
if glob_max_terms < 15 or 512 < glob_max_terms then
omniout_str(ALWAYS, "Illegal max_terms = -- Using 30");
glob_max_terms := 30
end if;
if glob_max_iter < 2 then
omniout_str(ALWAYS, "Illegal max_iter"); errflag := true
end if;
if errflag then quit end if
end proc
> # Begin Function number 16
> comp_expect_sec := proc(t_end2,t_start2,t2,clock_sec2)
> global glob_small_float;
> local ms2, rrr, sec_left, sub1, sub2;
>
>
>
> ;
> ms2 := clock_sec2;
> sub1 := (t_end2-t_start2);
> sub2 := (t2-t_start2);
> if (sub1 = 0.0) then # if number 13
> sec_left := 0.0;
> else
> if (sub2 > 0.0) then # if number 14
> rrr := (sub1/sub2);
> sec_left := rrr * ms2 - ms2;
> else
> sec_left := 0.0;
> fi;# end if 14
> fi;# end if 13
> ;
> sec_left;
>
> # End Function number 16
> end;
comp_expect_sec := proc(t_end2, t_start2, t2, clock_sec2)
local ms2, rrr, sec_left, sub1, sub2;
global glob_small_float;
ms2 := clock_sec2;
sub1 := t_end2 - t_start2;
sub2 := t2 - t_start2;
if sub1 = 0. then sec_left := 0.
else
if 0. < sub2 then rrr := sub1/sub2; sec_left := rrr*ms2 - ms2
else sec_left := 0.
end if
end if;
sec_left
end proc
> # Begin Function number 17
> comp_percent := proc(t_end2,t_start2, t2)
> global glob_small_float;
> local rrr, sub1, sub2;
>
>
>
> sub1 := (t_end2-t_start2);
> sub2 := (t2-t_start2);
> if (sub2 > glob_small_float) then # if number 13
> rrr := (100.0*sub2)/sub1;
> else
> rrr := 0.0;
> fi;# end if 13
> ;
> rrr;
>
> # End Function number 17
> end;
comp_percent := proc(t_end2, t_start2, t2)
local rrr, sub1, sub2;
global glob_small_float;
sub1 := t_end2 - t_start2;
sub2 := t2 - t_start2;
if glob_small_float < sub2 then rrr := 100.0*sub2/sub1
else rrr := 0.
end if;
rrr
end proc
> # Begin Function number 18
> factorial_2 := proc(nnn)
> local ret;
>
>
>
> ret := nnn!;
>
> # End Function number 18
> end;
factorial_2 := proc(nnn) local ret; ret := nnn! end proc
> # Begin Function number 19
> factorial_1 := proc(nnn)
> global glob_max_terms,array_fact_1;
> local ret;
>
>
>
> if (nnn <= glob_max_terms) then # if number 13
> if (array_fact_1[nnn] = 0) then # if number 14
> ret := factorial_2(nnn);
> array_fact_1[nnn] := ret;
> else
> ret := array_fact_1[nnn];
> fi;# end if 14
> ;
> else
> ret := factorial_2(nnn);
> fi;# end if 13
> ;
> ret;
>
> # End Function number 19
> end;
factorial_1 := proc(nnn)
local ret;
global glob_max_terms, array_fact_1;
if nnn <= glob_max_terms then
if array_fact_1[nnn] = 0 then
ret := factorial_2(nnn); array_fact_1[nnn] := ret
else ret := array_fact_1[nnn]
end if
else ret := factorial_2(nnn)
end if;
ret
end proc
> # Begin Function number 20
> factorial_3 := proc(mmm,nnn)
> global glob_max_terms,array_fact_2;
> local ret;
>
>
>
> if ((nnn <= glob_max_terms) and (mmm <= glob_max_terms)) then # if number 13
> if (array_fact_2[mmm,nnn] = 0) then # if number 14
> ret := factorial_1(mmm)/factorial_1(nnn);
> array_fact_2[mmm,nnn] := ret;
> else
> ret := array_fact_2[mmm,nnn];
> fi;# end if 14
> ;
> else
> ret := factorial_2(mmm)/factorial_2(nnn);
> fi;# end if 13
> ;
> ret;
>
> # End Function number 20
> end;
factorial_3 := proc(mmm, nnn)
local ret;
global glob_max_terms, array_fact_2;
if nnn <= glob_max_terms and mmm <= glob_max_terms then
if array_fact_2[mmm, nnn] = 0 then
ret := factorial_1(mmm)/factorial_1(nnn);
array_fact_2[mmm, nnn] := ret
else ret := array_fact_2[mmm, nnn]
end if
else ret := factorial_2(mmm)/factorial_2(nnn)
end if;
ret
end proc
> # Begin Function number 21
> convfp := proc(mmm)
> (mmm);
>
> # End Function number 21
> end;
convfp := proc(mmm) mmm end proc
> # Begin Function number 22
> convfloat := proc(mmm)
> (mmm);
>
> # End Function number 22
> end;
convfloat := proc(mmm) mmm end proc
> elapsed_time_seconds := proc()
> time();
> end;
elapsed_time_seconds := proc() time() end proc
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
> omniabs := proc(x)
> abs(x);
> end;
omniabs := proc(x) abs(x) end proc
> expt := proc(x,y)
> (x^y);
> end;
expt := proc(x, y) x^y end proc
> #END ATS LIBRARY BLOCK
> #BEGIN USER DEF BLOCK
> #BEGIN USER DEF BLOCK
> exact_soln_y := proc(x)
> return(1.0 + exp(x));
> end;
exact_soln_y := proc(x) return 1.0 + exp(x) end proc
>
> #END USER DEF BLOCK
> #END USER DEF BLOCK
> #END OUTFILE5
> # Begin Function number 2
> main := proc()
> #BEGIN OUTFIEMAIN
> local d1,d2,d3,d4,est_err_2,niii,done_once,
> term,ord,order_diff,term_no,html_log_file,iiif,jjjf,
> rows,r_order,sub_iter,calc_term,iii,temp_sum,current_iter,
> x_start,x_end
> ,it, log10norm, max_terms, opt_iter, tmp,subiter;
> global
> DEBUGMASSIVE,
> DEBUGL,
> glob_max_terms,
> INFO,
> glob_iolevel,
> ALWAYS,
> #Top Generate Globals Decl
> glob_iter,
> glob_max_sec,
> glob_hmin,
> glob_clock_start_sec,
> glob_almost_1,
> min_in_hour,
> glob_dump,
> glob_log10_relerr,
> centuries_in_millinium,
> glob_max_opt_iter,
> glob_subiter_method,
> glob_log10abserr,
> glob_unchanged_h_cnt,
> glob_max_iter,
> glob_reached_optimal_h,
> glob_percent_done,
> MAX_UNCHANGED,
> glob_relerr,
> glob_hmin_init,
> glob_not_yet_finished,
> hours_in_day,
> djd_debug2,
> glob_log10relerr,
> glob_warned2,
> glob_optimal_start,
> glob_last_good_h,
> years_in_century,
> djd_debug,
> glob_normmax,
> glob_current_iter,
> glob_curr_iter_when_opt,
> glob_warned,
> glob_small_float,
> glob_no_eqs,
> glob_max_hours,
> glob_log10_abserr,
> glob_hmax,
> glob_max_minutes,
> glob_orig_start_sec,
> glob_smallish_float,
> glob_max_trunc_err,
> glob_max_rel_trunc_err,
> glob_abserr,
> glob_large_float,
> days_in_year,
> sec_in_minute,
> glob_good_digits,
> glob_log10normmin,
> glob_dump_analytic,
> glob_look_poles,
> glob_disp_incr,
> glob_optimal_done,
> glob_not_yet_start_msg,
> glob_initial_pass,
> glob_clock_sec,
> glob_html_log,
> glob_h,
> glob_display_flag,
> glob_optimal_expect_sec,
> glob_start,
> glob_optimal_clock_start_sec,
> #Bottom Generate Globals Decl
> #BEGIN CONST
> array_const_1D0,
> array_const_1,
> array_const_0D0,
> #END CONST
> array_y,
> array_x,
> array_norms,
> array_last_rel_error,
> array_type_pole,
> array_fact_1,
> array_pole,
> array_m1,
> array_y_init,
> array_1st_rel_error,
> array_tmp0,
> array_tmp1,
> array_tmp2,
> array_y_set_initial,
> array_complex_pole,
> array_fact_2,
> array_y_higher,
> array_real_pole,
> array_poles,
> array_y_higher_work,
> array_y_higher_work2,
> glob_last;
> glob_last;
> ALWAYS := 1;
> INFO := 2;
> DEBUGL := 3;
> DEBUGMASSIVE := 4;
> glob_iolevel := INFO;
> DEBUGMASSIVE := 4;
> DEBUGL := 3;
> glob_max_terms := 30;
> INFO := 2;
> glob_iolevel := 5;
> ALWAYS := 1;
> glob_iter := 0;
> glob_max_sec := 10000.0;
> glob_hmin := 0.00000000001;
> glob_clock_start_sec := 0.0;
> glob_almost_1 := 0.9990;
> min_in_hour := 60;
> glob_dump := false;
> glob_log10_relerr := 0.1e-10;
> centuries_in_millinium := 10;
> glob_max_opt_iter := 10;
> glob_subiter_method := 3;
> glob_log10abserr := 0.0;
> glob_unchanged_h_cnt := 0;
> glob_max_iter := 1000;
> glob_reached_optimal_h := false;
> glob_percent_done := 0.0;
> MAX_UNCHANGED := 10;
> glob_relerr := 0.1e-10;
> glob_hmin_init := 0.001;
> glob_not_yet_finished := true;
> hours_in_day := 24;
> djd_debug2 := true;
> glob_log10relerr := 0.0;
> glob_warned2 := false;
> glob_optimal_start := 0.0;
> glob_last_good_h := 0.1;
> years_in_century := 100;
> djd_debug := true;
> glob_normmax := 0.0;
> glob_current_iter := 0;
> glob_curr_iter_when_opt := 0;
> glob_warned := false;
> glob_small_float := 0.1e-50;
> glob_no_eqs := 0;
> glob_max_hours := 0.0;
> glob_log10_abserr := 0.1e-10;
> glob_hmax := 1.0;
> glob_max_minutes := 0.0;
> glob_orig_start_sec := 0.0;
> glob_smallish_float := 0.1e-100;
> glob_max_trunc_err := 0.1e-10;
> glob_max_rel_trunc_err := 0.1e-10;
> glob_abserr := 0.1e-10;
> glob_large_float := 9.0e100;
> days_in_year := 365;
> sec_in_minute := 60;
> glob_good_digits := 0;
> glob_log10normmin := 0.1;
> glob_dump_analytic := false;
> glob_look_poles := false;
> glob_disp_incr := 0.1;
> glob_optimal_done := false;
> glob_not_yet_start_msg := true;
> glob_initial_pass := true;
> glob_clock_sec := 0.0;
> glob_html_log := true;
> glob_h := 0.1;
> glob_display_flag := true;
> glob_optimal_expect_sec := 0.1;
> glob_start := 0;
> glob_optimal_clock_start_sec := 0.0;
> #Write Set Defaults
> glob_orig_start_sec := elapsed_time_seconds();
> MAX_UNCHANGED := 10;
> glob_curr_iter_when_opt := 0;
> glob_display_flag := true;
> glob_no_eqs := 1;
> glob_iter := -1;
> opt_iter := -1;
> glob_max_iter := 50000;
> glob_max_hours := 0.0;
> glob_max_minutes := 15.0;
> omniout_str(ALWAYS,"##############ECHO OF PROBLEM#################");
> omniout_str(ALWAYS,"##############temp/diff0postode.ode#################");
> omniout_str(ALWAYS,"diff ( y , x , 1 ) = y - 1.0;");
> omniout_str(ALWAYS,"!");
> omniout_str(ALWAYS,"#BEGIN FIRST INPUT BLOCK");
> omniout_str(ALWAYS,"Digits := 32;");
> omniout_str(ALWAYS,"max_terms := 30;");
> omniout_str(ALWAYS,"!");
> omniout_str(ALWAYS,"#END FIRST INPUT BLOCK");
> omniout_str(ALWAYS,"#BEGIN SECOND INPUT BLOCK");
> omniout_str(ALWAYS,"x_start := 1.1;");
> omniout_str(ALWAYS,"x_end := 5.0 ;");
> omniout_str(ALWAYS,"array_y_init[0 + 1] := exact_soln_y(x_start);");
> omniout_str(ALWAYS,"glob_h := 0.01 ;");
> omniout_str(ALWAYS,"glob_look_poles := true;");
> omniout_str(ALWAYS,"glob_max_iter := 100;");
> omniout_str(ALWAYS,"#END SECOND INPUT BLOCK");
> omniout_str(ALWAYS,"#BEGIN OVERRIDE BLOCK");
> omniout_str(ALWAYS,"glob_h := 0.00001 ;");
> omniout_str(ALWAYS,"glob_look_poles := true;");
> omniout_str(ALWAYS,"glob_max_iter := 100;");
> omniout_str(ALWAYS,"glob_max_minutes := 1;");
> omniout_str(ALWAYS,"#END OVERRIDE BLOCK");
> omniout_str(ALWAYS,"!");
> omniout_str(ALWAYS,"#BEGIN USER DEF BLOCK");
> omniout_str(ALWAYS,"exact_soln_y := proc(x)");
> omniout_str(ALWAYS,"return(1.0 + exp(x));");
> omniout_str(ALWAYS,"end;");
> omniout_str(ALWAYS,"");
> omniout_str(ALWAYS,"#END USER DEF BLOCK");
> omniout_str(ALWAYS,"#######END OF ECHO OF PROBLEM#################");
> glob_unchanged_h_cnt := 0;
> glob_warned := false;
> glob_warned2 := false;
> glob_small_float := 1.0e-200;
> glob_smallish_float := 1.0e-64;
> glob_large_float := 1.0e100;
> glob_almost_1 := 0.99;
> glob_log10_abserr := -8.0;
> glob_log10_relerr := -8.0;
> glob_hmax := 0.01;
> #BEGIN FIRST INPUT BLOCK
> #BEGIN FIRST INPUT BLOCK
> Digits := 32;
> max_terms := 30;
> #END FIRST INPUT BLOCK
> #START OF INITS AFTER INPUT BLOCK
> glob_max_terms := max_terms;
> glob_html_log := true;
> #END OF INITS AFTER INPUT BLOCK
> array_y:= Array(0..(max_terms + 1),[]);
> array_x:= Array(0..(max_terms + 1),[]);
> array_norms:= Array(0..(max_terms + 1),[]);
> array_last_rel_error:= Array(0..(max_terms + 1),[]);
> array_type_pole:= Array(0..(max_terms + 1),[]);
> array_fact_1:= Array(0..(max_terms + 1),[]);
> array_pole:= Array(0..(max_terms + 1),[]);
> array_m1:= Array(0..(max_terms + 1),[]);
> array_y_init:= Array(0..(max_terms + 1),[]);
> array_1st_rel_error:= Array(0..(max_terms + 1),[]);
> array_tmp0:= Array(0..(max_terms + 1),[]);
> array_tmp1:= Array(0..(max_terms + 1),[]);
> array_tmp2:= Array(0..(max_terms + 1),[]);
> array_y_set_initial := Array(0..(2+ 1) ,(0..max_terms+ 1),[]);
> array_complex_pole := Array(0..(1+ 1) ,(0..3+ 1),[]);
> array_fact_2 := Array(0..(max_terms+ 1) ,(0..max_terms+ 1),[]);
> array_y_higher := Array(0..(2+ 1) ,(0..max_terms+ 1),[]);
> array_real_pole := Array(0..(1+ 1) ,(0..3+ 1),[]);
> array_poles := Array(0..(1+ 1) ,(0..3+ 1),[]);
> array_y_higher_work := Array(0..(2+ 1) ,(0..max_terms+ 1),[]);
> array_y_higher_work2 := Array(0..(2+ 1) ,(0..max_terms+ 1),[]);
> term := 1;
> while (term <= max_terms) do # do number 2
> array_y[term] := 0.0;
> term := term + 1;
> od;# end do number 2
> ;
> term := 1;
> while (term <= max_terms) do # do number 2
> array_x[term] := 0.0;
> term := term + 1;
> od;# end do number 2
> ;
> term := 1;
> while (term <= max_terms) do # do number 2
> array_norms[term] := 0.0;
> term := term + 1;
> od;# end do number 2
> ;
> term := 1;
> while (term <= max_terms) do # do number 2
> array_last_rel_error[term] := 0.0;
> term := term + 1;
> od;# end do number 2
> ;
> term := 1;
> while (term <= max_terms) do # do number 2
> array_type_pole[term] := 0.0;
> term := term + 1;
> od;# end do number 2
> ;
> term := 1;
> while (term <= max_terms) do # do number 2
> array_fact_1[term] := 0.0;
> term := term + 1;
> od;# end do number 2
> ;
> term := 1;
> while (term <= max_terms) do # do number 2
> array_pole[term] := 0.0;
> term := term + 1;
> od;# end do number 2
> ;
> term := 1;
> while (term <= max_terms) do # do number 2
> array_m1[term] := 0.0;
> term := term + 1;
> od;# end do number 2
> ;
> term := 1;
> while (term <= max_terms) do # do number 2
> array_y_init[term] := 0.0;
> term := term + 1;
> od;# end do number 2
> ;
> term := 1;
> while (term <= max_terms) do # do number 2
> array_1st_rel_error[term] := 0.0;
> term := term + 1;
> od;# end do number 2
> ;
> term := 1;
> while (term <= max_terms) do # do number 2
> array_tmp0[term] := 0.0;
> term := term + 1;
> od;# end do number 2
> ;
> term := 1;
> while (term <= max_terms) do # do number 2
> array_tmp1[term] := 0.0;
> term := term + 1;
> od;# end do number 2
> ;
> term := 1;
> while (term <= max_terms) do # do number 2
> array_tmp2[term] := 0.0;
> term := term + 1;
> od;# end do number 2
> ;
> ord := 1;
> while (ord <=2) do # do number 2
> term := 1;
> while (term <= max_terms) do # do number 3
> array_y_set_initial[ord,term] := 0.0;
> term := term + 1;
> od;# end do number 3
> ;
> ord := ord + 1;
> od;# end do number 2
> ;
> ord := 1;
> while (ord <=1) do # do number 2
> term := 1;
> while (term <= 3) do # do number 3
> array_complex_pole[ord,term] := 0.0;
> term := term + 1;
> od;# end do number 3
> ;
> ord := ord + 1;
> od;# end do number 2
> ;
> ord := 1;
> while (ord <=max_terms) do # do number 2
> term := 1;
> while (term <= max_terms) do # do number 3
> array_fact_2[ord,term] := 0.0;
> term := term + 1;
> od;# end do number 3
> ;
> ord := ord + 1;
> od;# end do number 2
> ;
> ord := 1;
> while (ord <=2) do # do number 2
> term := 1;
> while (term <= max_terms) do # do number 3
> array_y_higher[ord,term] := 0.0;
> term := term + 1;
> od;# end do number 3
> ;
> ord := ord + 1;
> od;# end do number 2
> ;
> ord := 1;
> while (ord <=1) do # do number 2
> term := 1;
> while (term <= 3) do # do number 3
> array_real_pole[ord,term] := 0.0;
> term := term + 1;
> od;# end do number 3
> ;
> ord := ord + 1;
> od;# end do number 2
> ;
> ord := 1;
> while (ord <=1) do # do number 2
> term := 1;
> while (term <= 3) do # do number 3
> array_poles[ord,term] := 0.0;
> term := term + 1;
> od;# end do number 3
> ;
> ord := ord + 1;
> od;# end do number 2
> ;
> ord := 1;
> while (ord <=2) do # do number 2
> term := 1;
> while (term <= max_terms) do # do number 3
> array_y_higher_work[ord,term] := 0.0;
> term := term + 1;
> od;# end do number 3
> ;
> ord := ord + 1;
> od;# end do number 2
> ;
> ord := 1;
> while (ord <=2) do # do number 2
> term := 1;
> while (term <= max_terms) do # do number 3
> array_y_higher_work2[ord,term] := 0.0;
> term := term + 1;
> od;# end do number 3
> ;
> ord := ord + 1;
> od;# end do number 2
> ;
> #BEGIN ARRAYS DEFINED AND INITIALIZATED
> array_x := Array(1..(max_terms+1 + 1),[]);
> term := 1;
> while (term <= max_terms + 1) do # do number 2
> array_x[term] := 0.0;
> term := term + 1;
> od;# end do number 2
> ;
> array_y := Array(1..(max_terms+1 + 1),[]);
> term := 1;
> while (term <= max_terms + 1) do # do number 2
> array_y[term] := 0.0;
> term := term + 1;
> od;# end do number 2
> ;
> array_tmp2 := Array(1..(max_terms+1 + 1),[]);
> term := 1;
> while (term <= max_terms + 1) do # do number 2
> array_tmp2[term] := 0.0;
> term := term + 1;
> od;# end do number 2
> ;
> array_tmp1 := Array(1..(max_terms+1 + 1),[]);
> term := 1;
> while (term <= max_terms + 1) do # do number 2
> array_tmp1[term] := 0.0;
> term := term + 1;
> od;# end do number 2
> ;
> array_tmp0 := Array(1..(max_terms+1 + 1),[]);
> term := 1;
> while (term <= max_terms + 1) do # do number 2
> array_tmp0[term] := 0.0;
> term := term + 1;
> od;# end do number 2
> ;
> array_const_1D0 := Array(1..(max_terms+1 + 1),[]);
> term := 1;
> while (term <= max_terms + 1) do # do number 2
> array_const_1D0[term] := 0.0;
> term := term + 1;
> od;# end do number 2
> ;
> array_const_1D0[1] := 1.0;
> array_const_1 := Array(1..(max_terms+1 + 1),[]);
> term := 1;
> while (term <= max_terms + 1) do # do number 2
> array_const_1[term] := 0.0;
> term := term + 1;
> od;# end do number 2
> ;
> array_const_1[1] := 1;
> array_const_0D0 := Array(1..(max_terms+1 + 1),[]);
> term := 1;
> while (term <= max_terms + 1) do # do number 2
> array_const_0D0[term] := 0.0;
> term := term + 1;
> od;# end do number 2
> ;
> array_const_0D0[1] := 0.0;
> array_m1 := Array(1..(max_terms+1 + 1),[]);
> term := 1;
> while (term <= max_terms) do # do number 2
> array_m1[term] := 0.0;
> term := term + 1;
> od;# end do number 2
> ;
> array_m1[1] := -1.0;
> #END ARRAYS DEFINED AND INITIALIZATED
> #Initing Factorial Tables
> iiif := 0;
> while (iiif <= glob_max_terms) do # do number 2
> jjjf := 0;
> while (jjjf <= glob_max_terms) do # do number 3
> array_fact_1[iiif] := 0;
> array_fact_2[iiif,jjjf] := 0;
> jjjf := jjjf + 1;
> od;# end do number 3
> ;
> iiif := iiif + 1;
> od;# end do number 2
> ;
> #Done Initing Factorial Tables
> #TOP SECOND INPUT BLOCK
> #BEGIN SECOND INPUT BLOCK
> #END FIRST INPUT BLOCK
> #BEGIN SECOND INPUT BLOCK
> x_start := 1.1;
> x_end := 5.0 ;
> array_y_init[0 + 1] := exact_soln_y(x_start);
> glob_h := 0.01 ;
> glob_look_poles := true;
> glob_max_iter := 100;
> #END SECOND INPUT BLOCK
> #BEGIN OVERRIDE BLOCK
> glob_h := 0.00001 ;
> glob_look_poles := true;
> glob_max_iter := 100;
> glob_max_minutes := 1;
> #END OVERRIDE BLOCK
> #END SECOND INPUT BLOCK
> #BEGIN INITS AFTER SECOND INPUT BLOCK
> glob_last_good_h := glob_h;
> glob_max_terms := max_terms;
> glob_max_sec := convfloat(60.0) * convfloat(glob_max_minutes) + convfloat(3600.0) * convfloat(glob_max_hours);
> glob_abserr := expt(10.0 , (glob_log10_abserr));
> glob_relerr := expt(10.0 , (glob_log10_relerr));
> chk_data();
> #AFTER INITS AFTER SECOND INPUT BLOCK
> array_y_set_initial[1,1] := true;
> array_y_set_initial[1,2] := false;
> array_y_set_initial[1,3] := false;
> array_y_set_initial[1,4] := false;
> array_y_set_initial[1,5] := false;
> array_y_set_initial[1,6] := false;
> array_y_set_initial[1,7] := false;
> array_y_set_initial[1,8] := false;
> array_y_set_initial[1,9] := false;
> array_y_set_initial[1,10] := false;
> array_y_set_initial[1,11] := false;
> array_y_set_initial[1,12] := false;
> array_y_set_initial[1,13] := false;
> array_y_set_initial[1,14] := false;
> array_y_set_initial[1,15] := false;
> array_y_set_initial[1,16] := false;
> array_y_set_initial[1,17] := false;
> array_y_set_initial[1,18] := false;
> array_y_set_initial[1,19] := false;
> array_y_set_initial[1,20] := false;
> array_y_set_initial[1,21] := false;
> array_y_set_initial[1,22] := false;
> array_y_set_initial[1,23] := false;
> array_y_set_initial[1,24] := false;
> array_y_set_initial[1,25] := false;
> array_y_set_initial[1,26] := false;
> array_y_set_initial[1,27] := false;
> array_y_set_initial[1,28] := false;
> array_y_set_initial[1,29] := false;
> array_y_set_initial[1,30] := false;
> if (glob_html_log) then # if number 2
> html_log_file := fopen("html/entry.html",WRITE,TEXT);
> fi;# end if 2
> ;
> #BEGIN SOLUTION CODE
> omniout_str(ALWAYS,"START of Soultion");
> #Start Series -- INITIALIZE FOR SOLUTION
> array_x[1] := x_start;
> array_x[2] := glob_h;
> order_diff := 1;
> #Start Series array_y
> term_no := 1;
> while (term_no <= order_diff) do # do number 2
> array_y[term_no] := array_y_init[term_no] * expt(glob_h , (term_no - 1)) / factorial_1(term_no - 1);
> term_no := term_no + 1;
> od;# end do number 2
> ;
> rows := order_diff;
> r_order := 1;
> while (r_order <= rows) do # do number 2
> term_no := 1;
> while (term_no <= (rows - r_order + 1)) do # do number 3
> it := term_no + r_order - 1;
> array_y_higher[r_order,term_no] := array_y_init[it]* expt(glob_h , (term_no - 1)) / ((factorial_1(term_no - 1)));
> term_no := term_no + 1;
> od;# end do number 3
> ;
> r_order := r_order + 1;
> od;# end do number 2
> ;
> current_iter := 1;
> glob_clock_start_sec := elapsed_time_seconds();
> if (omniabs(array_y_higher[1,1]) > glob_small_float) then # if number 2
> tmp := omniabs(array_y_higher[1,1]);
> log10norm := (log10(tmp));
> if (log10norm < glob_log10normmin) then # if number 3
> glob_log10normmin := log10norm;
> fi;# end if 3
> fi;# end if 2
> ;
> display_alot(current_iter)
> ;
> glob_clock_sec := elapsed_time_seconds();
> glob_current_iter := 0;
> glob_iter := 0;
> omniout_str(DEBUGL," ");
> glob_reached_optimal_h := true;
> glob_optimal_clock_start_sec := elapsed_time_seconds();
> while ((glob_current_iter < glob_max_iter) and (array_x[1] <= x_end ) and ((convfloat(glob_clock_sec) - convfloat(glob_orig_start_sec)) < convfloat(glob_max_sec))) do # do number 2
> #left paren 0001C
> omniout_str(INFO," ");
> omniout_str(INFO,"TOP MAIN SOLVE Loop");
> glob_iter := glob_iter + 1;
> glob_clock_sec := elapsed_time_seconds();
> glob_current_iter := glob_current_iter + 1;
> atomall();
> if (glob_look_poles) then # if number 2
> #left paren 0004C
> check_for_pole();
> fi;# end if 2
> ;#was right paren 0004C
> array_x[1] := array_x[1] + glob_h;
> array_x[2] := glob_h;
> #Jump Series array_y
> order_diff := 1;
> #START PART 1 SUM AND ADJUST
> #START SUM AND ADJUST EQ =1
> #sum_and_adjust array_y
> #BEFORE ADJUST SUBSERIES EQ =1
> ord := 2;
> calc_term := 1;
> #adjust_subseriesarray_y
> iii := glob_max_terms;
> while (iii >= calc_term) do # do number 3
> array_y_higher_work[2,iii] := array_y_higher[2,iii] / expt(glob_h , (calc_term - 1)) / factorial_3(iii - calc_term , iii - 1);
> iii := iii - 1;
> od;# end do number 3
> ;
> #AFTER ADJUST SUBSERIES EQ =1
> #BEFORE SUM SUBSERIES EQ =1
> temp_sum := 0.0;
> ord := 2;
> calc_term := 1;
> #sum_subseriesarray_y
> iii := glob_max_terms;
> while (iii >= calc_term) do # do number 3
> temp_sum := temp_sum + array_y_higher_work[ord,iii];
> iii := iii - 1;
> od;# end do number 3
> ;
> array_y_higher_work2[ord,calc_term] := temp_sum * expt(glob_h , (calc_term - 1)) / (factorial_1(calc_term - 1));
> #AFTER SUM SUBSERIES EQ =1
> #BEFORE ADJUST SUBSERIES EQ =1
> ord := 1;
> calc_term := 2;
> #adjust_subseriesarray_y
> iii := glob_max_terms;
> while (iii >= calc_term) do # do number 3
> array_y_higher_work[1,iii] := array_y_higher[1,iii] / expt(glob_h , (calc_term - 1)) / factorial_3(iii - calc_term , iii - 1);
> iii := iii - 1;
> od;# end do number 3
> ;
> #AFTER ADJUST SUBSERIES EQ =1
> #BEFORE SUM SUBSERIES EQ =1
> temp_sum := 0.0;
> ord := 1;
> calc_term := 2;
> #sum_subseriesarray_y
> iii := glob_max_terms;
> while (iii >= calc_term) do # do number 3
> temp_sum := temp_sum + array_y_higher_work[ord,iii];
> iii := iii - 1;
> od;# end do number 3
> ;
> array_y_higher_work2[ord,calc_term] := temp_sum * expt(glob_h , (calc_term - 1)) / (factorial_1(calc_term - 1));
> #AFTER SUM SUBSERIES EQ =1
> #BEFORE ADJUST SUBSERIES EQ =1
> ord := 1;
> calc_term := 1;
> #adjust_subseriesarray_y
> iii := glob_max_terms;
> while (iii >= calc_term) do # do number 3
> array_y_higher_work[1,iii] := array_y_higher[1,iii] / expt(glob_h , (calc_term - 1)) / factorial_3(iii - calc_term , iii - 1);
> iii := iii - 1;
> od;# end do number 3
> ;
> #AFTER ADJUST SUBSERIES EQ =1
> #BEFORE SUM SUBSERIES EQ =1
> temp_sum := 0.0;
> ord := 1;
> calc_term := 1;
> #sum_subseriesarray_y
> iii := glob_max_terms;
> while (iii >= calc_term) do # do number 3
> temp_sum := temp_sum + array_y_higher_work[ord,iii];
> iii := iii - 1;
> od;# end do number 3
> ;
> array_y_higher_work2[ord,calc_term] := temp_sum * expt(glob_h , (calc_term - 1)) / (factorial_1(calc_term - 1));
> #AFTER SUM SUBSERIES EQ =1
> #END SUM AND ADJUST EQ =1
> #END PART 1
> #START PART 2 MOVE TERMS to REGULAR Array
> term_no := glob_max_terms;
> while (term_no >= 1) do # do number 3
> array_y[term_no] := array_y_higher_work2[1,term_no];
> ord := 1;
> while (ord <= order_diff) do # do number 4
> array_y_higher[ord,term_no] := array_y_higher_work2[ord,term_no];
> ord := ord + 1;
> od;# end do number 4
> ;
> term_no := term_no - 1;
> od;# end do number 3
> ;
> #END PART 2 HEVE MOVED TERMS to REGULAR Array
> display_alot(current_iter)
> ;
> od;# end do number 2
> ;#right paren 0001C
> omniout_str(ALWAYS,"Finished!");
> if (glob_iter >= glob_max_iter) then # if number 2
> omniout_str(ALWAYS,"Maximum Iterations Reached before Solution Completed!");
> fi;# end if 2
> ;
> if (elapsed_time_seconds() - convfloat(glob_orig_start_sec) >= convfloat(glob_max_sec )) then # if number 2
> omniout_str(ALWAYS,"Maximum Time Reached before Solution Completed!");
> fi;# end if 2
> ;
> glob_clock_sec := elapsed_time_seconds();
> omniout_str(INFO,"diff ( y , x , 1 ) = y - 1.0;");
> omniout_int(INFO,"Iterations ",32,glob_iter,4," ")
> ;
> prog_report(x_start,x_end);
> if (glob_html_log) then # if number 2
> logstart(html_log_file);
> logitem_str(html_log_file,"2012-09-02T21:22:02-05:00")
> ;
> logitem_str(html_log_file,"Maple")
> ;
> logitem_str(html_log_file,"diff0")
> ;
> logitem_str(html_log_file,"diff ( y , x , 1 ) = y - 1.0;")
> ;
> logitem_float(html_log_file,x_start)
> ;
> logitem_float(html_log_file,x_end)
> ;
> logitem_float(html_log_file,array_x[1])
> ;
> logitem_float(html_log_file,glob_h)
> ;
> logitem_integer(html_log_file,Digits)
> ;
> ;
> logitem_good_digits(html_log_file,array_last_rel_error[1])
> ;
> logitem_integer(html_log_file,glob_max_terms)
> ;
> logitem_float(html_log_file,array_1st_rel_error[1])
> ;
> logitem_float(html_log_file,array_last_rel_error[1])
> ;
> logitem_integer(html_log_file,glob_iter)
> ;
> logitem_pole(html_log_file,array_type_pole[1])
> ;
> if (array_type_pole[1] = 1 or array_type_pole[1] = 2) then # if number 3
> logitem_float(html_log_file,array_pole[1])
> ;
> logitem_float(html_log_file,array_pole[2])
> ;
> 0;
> else
> logitem_str(html_log_file,"NA")
> ;
> logitem_str(html_log_file,"NA")
> ;
> 0;
> fi;# end if 3
> ;
> logitem_time(html_log_file,convfloat(glob_clock_sec))
> ;
> if (glob_percent_done < 100.0) then # if number 3
> logitem_time(html_log_file,convfloat(glob_optimal_expect_sec))
> ;
> 0;
> else
> logitem_str(html_log_file,"Done")
> ;
> 0;
> fi;# end if 3
> ;
> log_revs(html_log_file," 126 | ")
> ;
> logitem_str(html_log_file,"diff0 diffeq.mxt")
> ;
> logitem_str(html_log_file,"diff0 maple results")
> ;
> logitem_str(html_log_file,"c c++ Maple and Maxima")
> ;
> logend(html_log_file)
> ;
> ;
> fi;# end if 2
> ;
> if (glob_html_log) then # if number 2
> fclose(html_log_file);
> fi;# end if 2
> ;
> ;;
> #END OUTFILEMAIN
>
> # End Function number 8
> end;
main := proc()
local d1, d2, d3, d4, est_err_2, niii, done_once, term, ord, order_diff,
term_no, html_log_file, iiif, jjjf, rows, r_order, sub_iter, calc_term, iii,
temp_sum, current_iter, x_start, x_end, it, log10norm, max_terms, opt_iter,
tmp, subiter;
global DEBUGMASSIVE, DEBUGL, glob_max_terms, INFO, glob_iolevel, ALWAYS,
glob_iter, glob_max_sec, glob_hmin, glob_clock_start_sec, glob_almost_1,
min_in_hour, glob_dump, glob_log10_relerr, centuries_in_millinium,
glob_max_opt_iter, glob_subiter_method, glob_log10abserr,
glob_unchanged_h_cnt, glob_max_iter, glob_reached_optimal_h,
glob_percent_done, MAX_UNCHANGED, glob_relerr, glob_hmin_init,
glob_not_yet_finished, hours_in_day, djd_debug2, glob_log10relerr,
glob_warned2, glob_optimal_start, glob_last_good_h, years_in_century,
djd_debug, glob_normmax, glob_current_iter, glob_curr_iter_when_opt,
glob_warned, glob_small_float, glob_no_eqs, glob_max_hours,
glob_log10_abserr, glob_hmax, glob_max_minutes, glob_orig_start_sec,
glob_smallish_float, glob_max_trunc_err, glob_max_rel_trunc_err,
glob_abserr, glob_large_float, days_in_year, sec_in_minute,
glob_good_digits, glob_log10normmin, glob_dump_analytic, glob_look_poles,
glob_disp_incr, glob_optimal_done, glob_not_yet_start_msg,
glob_initial_pass, glob_clock_sec, glob_html_log, glob_h, glob_display_flag,
glob_optimal_expect_sec, glob_start, glob_optimal_clock_start_sec,
array_const_1D0, array_const_1, array_const_0D0, array_y, array_x,
array_norms, array_last_rel_error, array_type_pole, array_fact_1,
array_pole, array_m1, array_y_init, array_1st_rel_error, array_tmp0,
array_tmp1, array_tmp2, array_y_set_initial, array_complex_pole,
array_fact_2, array_y_higher, array_real_pole, array_poles,
array_y_higher_work, array_y_higher_work2, glob_last;
glob_last;
ALWAYS := 1;
INFO := 2;
DEBUGL := 3;
DEBUGMASSIVE := 4;
glob_iolevel := INFO;
DEBUGMASSIVE := 4;
DEBUGL := 3;
glob_max_terms := 30;
INFO := 2;
glob_iolevel := 5;
ALWAYS := 1;
glob_iter := 0;
glob_max_sec := 10000.0;
glob_hmin := 0.1*10^(-10);
glob_clock_start_sec := 0.;
glob_almost_1 := 0.9990;
min_in_hour := 60;
glob_dump := false;
glob_log10_relerr := 0.1*10^(-10);
centuries_in_millinium := 10;
glob_max_opt_iter := 10;
glob_subiter_method := 3;
glob_log10abserr := 0.;
glob_unchanged_h_cnt := 0;
glob_max_iter := 1000;
glob_reached_optimal_h := false;
glob_percent_done := 0.;
MAX_UNCHANGED := 10;
glob_relerr := 0.1*10^(-10);
glob_hmin_init := 0.001;
glob_not_yet_finished := true;
hours_in_day := 24;
djd_debug2 := true;
glob_log10relerr := 0.;
glob_warned2 := false;
glob_optimal_start := 0.;
glob_last_good_h := 0.1;
years_in_century := 100;
djd_debug := true;
glob_normmax := 0.;
glob_current_iter := 0;
glob_curr_iter_when_opt := 0;
glob_warned := false;
glob_small_float := 0.1*10^(-50);
glob_no_eqs := 0;
glob_max_hours := 0.;
glob_log10_abserr := 0.1*10^(-10);
glob_hmax := 1.0;
glob_max_minutes := 0.;
glob_orig_start_sec := 0.;
glob_smallish_float := 0.1*10^(-100);
glob_max_trunc_err := 0.1*10^(-10);
glob_max_rel_trunc_err := 0.1*10^(-10);
glob_abserr := 0.1*10^(-10);
glob_large_float := 0.90*10^101;
days_in_year := 365;
sec_in_minute := 60;
glob_good_digits := 0;
glob_log10normmin := 0.1;
glob_dump_analytic := false;
glob_look_poles := false;
glob_disp_incr := 0.1;
glob_optimal_done := false;
glob_not_yet_start_msg := true;
glob_initial_pass := true;
glob_clock_sec := 0.;
glob_html_log := true;
glob_h := 0.1;
glob_display_flag := true;
glob_optimal_expect_sec := 0.1;
glob_start := 0;
glob_optimal_clock_start_sec := 0.;
glob_orig_start_sec := elapsed_time_seconds();
MAX_UNCHANGED := 10;
glob_curr_iter_when_opt := 0;
glob_display_flag := true;
glob_no_eqs := 1;
glob_iter := -1;
opt_iter := -1;
glob_max_iter := 50000;
glob_max_hours := 0.;
glob_max_minutes := 15.0;
omniout_str(ALWAYS, "##############ECHO OF PROBLEM#################");
omniout_str(ALWAYS,
"##############temp/diff0postode.ode#################");
omniout_str(ALWAYS, "diff ( y , x , 1 ) = y - 1.0;");
omniout_str(ALWAYS, "!");
omniout_str(ALWAYS, "#BEGIN FIRST INPUT BLOCK");
omniout_str(ALWAYS, "Digits := 32;");
omniout_str(ALWAYS, "max_terms := 30;");
omniout_str(ALWAYS, "!");
omniout_str(ALWAYS, "#END FIRST INPUT BLOCK");
omniout_str(ALWAYS, "#BEGIN SECOND INPUT BLOCK");
omniout_str(ALWAYS, "x_start := 1.1;");
omniout_str(ALWAYS, "x_end := 5.0 ;");
omniout_str(ALWAYS, "array_y_init[0 + 1] := exact_soln_y(x_start);");
omniout_str(ALWAYS, "glob_h := 0.01 ;");
omniout_str(ALWAYS, "glob_look_poles := true;");
omniout_str(ALWAYS, "glob_max_iter := 100;");
omniout_str(ALWAYS, "#END SECOND INPUT BLOCK");
omniout_str(ALWAYS, "#BEGIN OVERRIDE BLOCK");
omniout_str(ALWAYS, "glob_h := 0.00001 ;");
omniout_str(ALWAYS, "glob_look_poles := true;");
omniout_str(ALWAYS, "glob_max_iter := 100;");
omniout_str(ALWAYS, "glob_max_minutes := 1;");
omniout_str(ALWAYS, "#END OVERRIDE BLOCK");
omniout_str(ALWAYS, "!");
omniout_str(ALWAYS, "#BEGIN USER DEF BLOCK");
omniout_str(ALWAYS, "exact_soln_y := proc(x)");
omniout_str(ALWAYS, "return(1.0 + exp(x));");
omniout_str(ALWAYS, "end;");
omniout_str(ALWAYS, "");
omniout_str(ALWAYS, "#END USER DEF BLOCK");
omniout_str(ALWAYS, "#######END OF ECHO OF PROBLEM#################");
glob_unchanged_h_cnt := 0;
glob_warned := false;
glob_warned2 := false;
glob_small_float := 0.10*10^(-199);
glob_smallish_float := 0.10*10^(-63);
glob_large_float := 0.10*10^101;
glob_almost_1 := 0.99;
glob_log10_abserr := -8.0;
glob_log10_relerr := -8.0;
glob_hmax := 0.01;
Digits := 32;
max_terms := 30;
glob_max_terms := max_terms;
glob_html_log := true;
array_y := Array(0 .. max_terms + 1, []);
array_x := Array(0 .. max_terms + 1, []);
array_norms := Array(0 .. max_terms + 1, []);
array_last_rel_error := Array(0 .. max_terms + 1, []);
array_type_pole := Array(0 .. max_terms + 1, []);
array_fact_1 := Array(0 .. max_terms + 1, []);
array_pole := Array(0 .. max_terms + 1, []);
array_m1 := Array(0 .. max_terms + 1, []);
array_y_init := Array(0 .. max_terms + 1, []);
array_1st_rel_error := Array(0 .. max_terms + 1, []);
array_tmp0 := Array(0 .. max_terms + 1, []);
array_tmp1 := Array(0 .. max_terms + 1, []);
array_tmp2 := Array(0 .. max_terms + 1, []);
array_y_set_initial := Array(0 .. 3, 0 .. max_terms + 1, []);
array_complex_pole := Array(0 .. 2, 0 .. 4, []);
array_fact_2 := Array(0 .. max_terms + 1, 0 .. max_terms + 1, []);
array_y_higher := Array(0 .. 3, 0 .. max_terms + 1, []);
array_real_pole := Array(0 .. 2, 0 .. 4, []);
array_poles := Array(0 .. 2, 0 .. 4, []);
array_y_higher_work := Array(0 .. 3, 0 .. max_terms + 1, []);
array_y_higher_work2 := Array(0 .. 3, 0 .. max_terms + 1, []);
term := 1;
while term <= max_terms do array_y[term] := 0.; term := term + 1 end do
;
term := 1;
while term <= max_terms do array_x[term] := 0.; term := term + 1 end do
;
term := 1;
while term <= max_terms do array_norms[term] := 0.; term := term + 1
end do;
term := 1;
while term <= max_terms do
array_last_rel_error[term] := 0.; term := term + 1
end do;
term := 1;
while term <= max_terms do
array_type_pole[term] := 0.; term := term + 1
end do;
term := 1;
while term <= max_terms do array_fact_1[term] := 0.; term := term + 1
end do;
term := 1;
while term <= max_terms do array_pole[term] := 0.; term := term + 1
end do;
term := 1;
while term <= max_terms do array_m1[term] := 0.; term := term + 1
end do;
term := 1;
while term <= max_terms do array_y_init[term] := 0.; term := term + 1
end do;
term := 1;
while term <= max_terms do
array_1st_rel_error[term] := 0.; term := term + 1
end do;
term := 1;
while term <= max_terms do array_tmp0[term] := 0.; term := term + 1
end do;
term := 1;
while term <= max_terms do array_tmp1[term] := 0.; term := term + 1
end do;
term := 1;
while term <= max_terms do array_tmp2[term] := 0.; term := term + 1
end do;
ord := 1;
while ord <= 2 do
term := 1;
while term <= max_terms do
array_y_set_initial[ord, term] := 0.; term := term + 1
end do;
ord := ord + 1
end do;
ord := 1;
while ord <= 1 do
term := 1;
while term <= 3 do
array_complex_pole[ord, term] := 0.; term := term + 1
end do;
ord := ord + 1
end do;
ord := 1;
while ord <= max_terms do
term := 1;
while term <= max_terms do
array_fact_2[ord, term] := 0.; term := term + 1
end do;
ord := ord + 1
end do;
ord := 1;
while ord <= 2 do
term := 1;
while term <= max_terms do
array_y_higher[ord, term] := 0.; term := term + 1
end do;
ord := ord + 1
end do;
ord := 1;
while ord <= 1 do
term := 1;
while term <= 3 do
array_real_pole[ord, term] := 0.; term := term + 1
end do;
ord := ord + 1
end do;
ord := 1;
while ord <= 1 do
term := 1;
while term <= 3 do array_poles[ord, term] := 0.; term := term + 1
end do;
ord := ord + 1
end do;
ord := 1;
while ord <= 2 do
term := 1;
while term <= max_terms do
array_y_higher_work[ord, term] := 0.; term := term + 1
end do;
ord := ord + 1
end do;
ord := 1;
while ord <= 2 do
term := 1;
while term <= max_terms do
array_y_higher_work2[ord, term] := 0.; term := term + 1
end do;
ord := ord + 1
end do;
array_x := Array(1 .. max_terms + 2, []);
term := 1;
while term <= max_terms + 1 do array_x[term] := 0.; term := term + 1
end do;
array_y := Array(1 .. max_terms + 2, []);
term := 1;
while term <= max_terms + 1 do array_y[term] := 0.; term := term + 1
end do;
array_tmp2 := Array(1 .. max_terms + 2, []);
term := 1;
while term <= max_terms + 1 do array_tmp2[term] := 0.; term := term + 1
end do;
array_tmp1 := Array(1 .. max_terms + 2, []);
term := 1;
while term <= max_terms + 1 do array_tmp1[term] := 0.; term := term + 1
end do;
array_tmp0 := Array(1 .. max_terms + 2, []);
term := 1;
while term <= max_terms + 1 do array_tmp0[term] := 0.; term := term + 1
end do;
array_const_1D0 := Array(1 .. max_terms + 2, []);
term := 1;
while term <= max_terms + 1 do
array_const_1D0[term] := 0.; term := term + 1
end do;
array_const_1D0[1] := 1.0;
array_const_1 := Array(1 .. max_terms + 2, []);
term := 1;
while term <= max_terms + 1 do
array_const_1[term] := 0.; term := term + 1
end do;
array_const_1[1] := 1;
array_const_0D0 := Array(1 .. max_terms + 2, []);
term := 1;
while term <= max_terms + 1 do
array_const_0D0[term] := 0.; term := term + 1
end do;
array_const_0D0[1] := 0.;
array_m1 := Array(1 .. max_terms + 2, []);
term := 1;
while term <= max_terms do array_m1[term] := 0.; term := term + 1
end do;
array_m1[1] := -1.0;
iiif := 0;
while iiif <= glob_max_terms do
jjjf := 0;
while jjjf <= glob_max_terms do
array_fact_1[iiif] := 0;
array_fact_2[iiif, jjjf] := 0;
jjjf := jjjf + 1
end do;
iiif := iiif + 1
end do;
x_start := 1.1;
x_end := 5.0;
array_y_init[1] := exact_soln_y(x_start);
glob_h := 0.01;
glob_look_poles := true;
glob_max_iter := 100;
glob_h := 0.00001;
glob_look_poles := true;
glob_max_iter := 100;
glob_max_minutes := 1;
glob_last_good_h := glob_h;
glob_max_terms := max_terms;
glob_max_sec := convfloat(60.0)*convfloat(glob_max_minutes)
+ convfloat(3600.0)*convfloat(glob_max_hours);
glob_abserr := expt(10.0, glob_log10_abserr);
glob_relerr := expt(10.0, glob_log10_relerr);
chk_data();
array_y_set_initial[1, 1] := true;
array_y_set_initial[1, 2] := false;
array_y_set_initial[1, 3] := false;
array_y_set_initial[1, 4] := false;
array_y_set_initial[1, 5] := false;
array_y_set_initial[1, 6] := false;
array_y_set_initial[1, 7] := false;
array_y_set_initial[1, 8] := false;
array_y_set_initial[1, 9] := false;
array_y_set_initial[1, 10] := false;
array_y_set_initial[1, 11] := false;
array_y_set_initial[1, 12] := false;
array_y_set_initial[1, 13] := false;
array_y_set_initial[1, 14] := false;
array_y_set_initial[1, 15] := false;
array_y_set_initial[1, 16] := false;
array_y_set_initial[1, 17] := false;
array_y_set_initial[1, 18] := false;
array_y_set_initial[1, 19] := false;
array_y_set_initial[1, 20] := false;
array_y_set_initial[1, 21] := false;
array_y_set_initial[1, 22] := false;
array_y_set_initial[1, 23] := false;
array_y_set_initial[1, 24] := false;
array_y_set_initial[1, 25] := false;
array_y_set_initial[1, 26] := false;
array_y_set_initial[1, 27] := false;
array_y_set_initial[1, 28] := false;
array_y_set_initial[1, 29] := false;
array_y_set_initial[1, 30] := false;
if glob_html_log then
html_log_file := fopen("html/entry.html", WRITE, TEXT)
end if;
omniout_str(ALWAYS, "START of Soultion");
array_x[1] := x_start;
array_x[2] := glob_h;
order_diff := 1;
term_no := 1;
while term_no <= order_diff do
array_y[term_no] := array_y_init[term_no]*expt(glob_h, term_no - 1)
/factorial_1(term_no - 1);
term_no := term_no + 1
end do;
rows := order_diff;
r_order := 1;
while r_order <= rows do
term_no := 1;
while term_no <= rows - r_order + 1 do
it := term_no + r_order - 1;
array_y_higher[r_order, term_no] := array_y_init[it]*
expt(glob_h, term_no - 1)/factorial_1(term_no - 1);
term_no := term_no + 1
end do;
r_order := r_order + 1
end do;
current_iter := 1;
glob_clock_start_sec := elapsed_time_seconds();
if glob_small_float < omniabs(array_y_higher[1, 1]) then
tmp := omniabs(array_y_higher[1, 1]);
log10norm := log10(tmp);
if log10norm < glob_log10normmin then
glob_log10normmin := log10norm
end if
end if;
display_alot(current_iter);
glob_clock_sec := elapsed_time_seconds();
glob_current_iter := 0;
glob_iter := 0;
omniout_str(DEBUGL, " ");
glob_reached_optimal_h := true;
glob_optimal_clock_start_sec := elapsed_time_seconds();
while glob_current_iter < glob_max_iter and array_x[1] <= x_end and
convfloat(glob_clock_sec) - convfloat(glob_orig_start_sec) <
convfloat(glob_max_sec) do
omniout_str(INFO, " ");
omniout_str(INFO, "TOP MAIN SOLVE Loop");
glob_iter := glob_iter + 1;
glob_clock_sec := elapsed_time_seconds();
glob_current_iter := glob_current_iter + 1;
atomall();
if glob_look_poles then check_for_pole() end if;
array_x[1] := array_x[1] + glob_h;
array_x[2] := glob_h;
order_diff := 1;
ord := 2;
calc_term := 1;
iii := glob_max_terms;
while calc_term <= iii do
array_y_higher_work[2, iii] := array_y_higher[2, iii]/(
expt(glob_h, calc_term - 1)*
factorial_3(iii - calc_term, iii - 1));
iii := iii - 1
end do;
temp_sum := 0.;
ord := 2;
calc_term := 1;
iii := glob_max_terms;
while calc_term <= iii do
temp_sum := temp_sum + array_y_higher_work[ord, iii];
iii := iii - 1
end do;
array_y_higher_work2[ord, calc_term] :=
temp_sum*expt(glob_h, calc_term - 1)/factorial_1(calc_term - 1)
;
ord := 1;
calc_term := 2;
iii := glob_max_terms;
while calc_term <= iii do
array_y_higher_work[1, iii] := array_y_higher[1, iii]/(
expt(glob_h, calc_term - 1)*
factorial_3(iii - calc_term, iii - 1));
iii := iii - 1
end do;
temp_sum := 0.;
ord := 1;
calc_term := 2;
iii := glob_max_terms;
while calc_term <= iii do
temp_sum := temp_sum + array_y_higher_work[ord, iii];
iii := iii - 1
end do;
array_y_higher_work2[ord, calc_term] :=
temp_sum*expt(glob_h, calc_term - 1)/factorial_1(calc_term - 1)
;
ord := 1;
calc_term := 1;
iii := glob_max_terms;
while calc_term <= iii do
array_y_higher_work[1, iii] := array_y_higher[1, iii]/(
expt(glob_h, calc_term - 1)*
factorial_3(iii - calc_term, iii - 1));
iii := iii - 1
end do;
temp_sum := 0.;
ord := 1;
calc_term := 1;
iii := glob_max_terms;
while calc_term <= iii do
temp_sum := temp_sum + array_y_higher_work[ord, iii];
iii := iii - 1
end do;
array_y_higher_work2[ord, calc_term] :=
temp_sum*expt(glob_h, calc_term - 1)/factorial_1(calc_term - 1)
;
term_no := glob_max_terms;
while 1 <= term_no do
array_y[term_no] := array_y_higher_work2[1, term_no];
ord := 1;
while ord <= order_diff do
array_y_higher[ord, term_no] :=
array_y_higher_work2[ord, term_no];
ord := ord + 1
end do;
term_no := term_no - 1
end do;
display_alot(current_iter)
end do;
omniout_str(ALWAYS, "Finished!");
if glob_max_iter <= glob_iter then omniout_str(ALWAYS,
"Maximum Iterations Reached before Solution Completed!")
end if;
if convfloat(glob_max_sec) <=
elapsed_time_seconds() - convfloat(glob_orig_start_sec) then
omniout_str(ALWAYS,
"Maximum Time Reached before Solution Completed!")
end if;
glob_clock_sec := elapsed_time_seconds();
omniout_str(INFO, "diff ( y , x , 1 ) = y - 1.0;");
omniout_int(INFO, "Iterations ", 32, glob_iter, 4,
" ");
prog_report(x_start, x_end);
if glob_html_log then
logstart(html_log_file);
logitem_str(html_log_file, "2012-09-02T21:22:02-05:00");
logitem_str(html_log_file, "Maple");
logitem_str(html_log_file, "diff0");
logitem_str(html_log_file, "diff ( y , x , 1 ) = y - 1.0;");
logitem_float(html_log_file, x_start);
logitem_float(html_log_file, x_end);
logitem_float(html_log_file, array_x[1]);
logitem_float(html_log_file, glob_h);
logitem_integer(html_log_file, Digits);
logitem_good_digits(html_log_file, array_last_rel_error[1]);
logitem_integer(html_log_file, glob_max_terms);
logitem_float(html_log_file, array_1st_rel_error[1]);
logitem_float(html_log_file, array_last_rel_error[1]);
logitem_integer(html_log_file, glob_iter);
logitem_pole(html_log_file, array_type_pole[1]);
if array_type_pole[1] = 1 or array_type_pole[1] = 2 then
logitem_float(html_log_file, array_pole[1]);
logitem_float(html_log_file, array_pole[2]);
0
else
logitem_str(html_log_file, "NA");
logitem_str(html_log_file, "NA");
0
end if;
logitem_time(html_log_file, convfloat(glob_clock_sec));
if glob_percent_done < 100.0 then
logitem_time(html_log_file, convfloat(glob_optimal_expect_sec))
;
0
else logitem_str(html_log_file, "Done"); 0
end if;
log_revs(html_log_file, " 126 | ");
logitem_str(html_log_file,
"diff0 diffeq.mxt");
logitem_str(html_log_file,
"diff0 maple results");
logitem_str(html_log_file, "c c++ Maple and Maxima");
logend(html_log_file)
end if;
if glob_html_log then fclose(html_log_file) end if
end proc
> main();
##############ECHO OF PROBLEM#################
##############temp/diff0postode.ode#################
diff ( y , x , 1 ) = y - 1.0;
!
#BEGIN FIRST INPUT BLOCK
Digits := 32;
max_terms := 30;
!
#END FIRST INPUT BLOCK
#BEGIN SECOND INPUT BLOCK
x_start := 1.1;
x_end := 5.0 ;
array_y_init[0 + 1] := exact_soln_y(x_start);
glob_h := 0.01 ;
glob_look_poles := true;
glob_max_iter := 100;
#END SECOND INPUT BLOCK
#BEGIN OVERRIDE BLOCK
glob_h := 0.00001 ;
glob_look_poles := true;
glob_max_iter := 100;
glob_max_minutes := 1;
#END OVERRIDE BLOCK
!
#BEGIN USER DEF BLOCK
exact_soln_y := proc(x)
return(1.0 + exp(x));
end;
#END USER DEF BLOCK
#######END OF ECHO OF PROBLEM#################
START of Soultion
x[1] = 1.1
y[1] (analytic) = 4.0041660239464331120584079535887
y[1] (numeric) = 4.0041660239464331120584079535887
absolute error = 0
relative error = 0 %
Correct digits = 32
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.10001
y[1] (analytic) = 4.0041960657568813782824392560234
y[1] (numeric) = 4.0041960657568813782824392560236
absolute error = 2e-31
relative error = 4.9947604142155209009471890922747e-30 %
Correct digits = 31
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.10002
y[1] (analytic) = 4.0042261078677492510846621930079
y[1] (numeric) = 4.0042261078677492510846621930082
absolute error = 3e-31
relative error = 7.4920844107814387624143558116998e-30 %
Correct digits = 31
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.10003
y[1] (analytic) = 4.0042561502790397346761635768574
y[1] (numeric) = 4.0042561502790397346761635768579
absolute error = 5e-31
relative error = 1.2486713667534908008128759159691e-29 %
Correct digits = 30
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.10004
y[1] (analytic) = 4.0042861929907558332980724809665
y[1] (numeric) = 4.0042861929907558332980724809671
absolute error = 6e-31
relative error = 1.4983943981083600353940405848890e-29 %
Correct digits = 30
h = 1e-05
TOP MAIN SOLVE Loop
NO POLE
x[1] = 1.10005
y[1] (analytic) = 4.0043162360029005512215605402328
y[1] (numeric) = 4.0043162360029005512215605402336
absolute error = 8e-31
relative error = 1.9978442082250681538183452123001e-29 %
Correct digits = 30
h = 1e-05
TOP MAIN SOLVE Loop
NO POLE
x[1] = 1.10006
y[1] (analytic) = 4.0043462793154768927478422514846
y[1] (numeric) = 4.0043462793154768927478422514856
absolute error = 1.0e-30
relative error = 2.4972865238091872341711677512368e-29 %
Correct digits = 30
h = 1e-05
TOP MAIN SOLVE Loop
NO POLE
x[1] = 1.10007
y[1] (analytic) = 4.0043763229284878622081752739107
y[1] (numeric) = 4.0043763229284878622081752739118
absolute error = 1.1e-30
relative error = 2.7469945661739053924402154917493e-29 %
Correct digits = 30
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.10008
y[1] (analytic) = 4.0044063668419364639638607294934
y[1] (numeric) = 4.0044063668419364639638607294946
absolute error = 1.2e-30
relative error = 2.9966988613754915694510188386142e-29 %
Correct digits = 30
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 7.477e-16
Order of pole = 0.5
x[1] = 1.10009
y[1] (analytic) = 4.0044364110558257024062435034448
y[1] (numeric) = 4.0044364110558257024062435034462
absolute error = 1.4e-30
relative error = 3.4961224409376259936910324087577e-29 %
Correct digits = 30
h = 1e-05
TOP MAIN SOLVE Loop
NO POLE
x[1] = 1.1001
y[1] (analytic) = 4.0044664555701585819567125446461
y[1] (numeric) = 4.0044664555701585819567125446476
absolute error = 1.5e-30
relative error = 3.7458173682876537121668276013708e-29 %
Correct digits = 30
h = 1e-05
TOP MAIN SOLVE Loop
NO POLE
x[1] = 1.10011
y[1] (analytic) = 4.0044965003849381070667011660893
y[1] (numeric) = 4.004496500384938107066701166091
absolute error = 1.7e-30
relative error = 4.2452278328538556679858161306292e-29 %
Correct digits = 30
h = 1e-05
TOP MAIN SOLVE Loop
NO POLE
x[1] = 1.10012
y[1] (analytic) = 4.0045265455001672822176873453229
y[1] (numeric) = 4.0045265455001672822176873453247
absolute error = 1.8e-30
relative error = 4.4949133925023816728547116713623e-29 %
Correct digits = 30
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.10013
y[1] (analytic) = 4.0045565909158491119211940248995
y[1] (numeric) = 4.0045565909158491119211940249015
absolute error = 2.0e-30
relative error = 4.9943107422602223588610832960443e-29 %
Correct digits = 30
h = 1e-05
TOP MAIN SOLVE Loop
NO POLE
x[1] = 1.10014
y[1] (analytic) = 4.0045866366319866007187894128274
y[1] (numeric) = 4.0045866366319866007187894128295
absolute error = 2.1e-30
relative error = 5.2439869343573044184582804730691e-29 %
Correct digits = 30
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.10015
y[1] (analytic) = 4.0046166826485827531820872830243
y[1] (numeric) = 4.0046166826485827531820872830266
absolute error = 2.3e-30
relative error = 5.7433711694943562426938733804380e-29 %
Correct digits = 30
h = 1e-05
TOP MAIN SOLVE Loop
NO POLE
x[1] = 1.10016
y[1] (analytic) = 4.004646728965640573912747275775
y[1] (numeric) = 4.0046467289656405739127472757774
absolute error = 2.4e-30
relative error = 5.9930379941900531486305468949827e-29 %
Correct digits = 30
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.10017
y[1] (analytic) = 4.0046767755831630675424751981911
y[1] (numeric) = 4.0046767755831630675424751981936
absolute error = 2.5e-30
relative error = 6.2427010720133555080969033351384e-29 %
Correct digits = 30
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.10018
y[1] (analytic) = 4.0047068225011532387330233246744
y[1] (numeric) = 4.0047068225011532387330233246771
absolute error = 2.7e-30
relative error = 6.7420665723382612954529601434235e-29 %
Correct digits = 30
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 7.477e-16
Order of pole = 0.5
x[1] = 1.10019
y[1] (analytic) = 4.0047368697196140921761906973832
y[1] (numeric) = 4.004736869719614092176190697386
absolute error = 2.8e-30
relative error = 6.9917202829758899587308805573588e-29 %
Correct digits = 30
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.1002
y[1] (analytic) = 4.004766917238548632593823426701
y[1] (numeric) = 4.0047669172385486325938234267039
absolute error = 2.9e-30
relative error = 7.2413702468349123723826282371734e-29 %
Correct digits = 30
h = 1e-05
TOP MAIN SOLVE Loop
NO POLE
x[1] = 1.10021
y[1] (analytic) = 4.0047969650579598647378149917092
y[1] (numeric) = 4.0047969650579598647378149917123
absolute error = 3.1e-30
relative error = 7.7407170127415807929648175438815e-29 %
Correct digits = 30
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.10022
y[1] (analytic) = 4.0048270131778507933901065406621
y[1] (numeric) = 4.0048270131778507933901065406653
memory used=3.8MB, alloc=2.9MB, time=0.36
absolute error = 3.2e-30
relative error = 7.9903576096306431300173900710953e-29 %
Correct digits = 30
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 7.477e-16
Order of pole = 0.5
x[1] = 1.10023
y[1] (analytic) = 4.004857061598224423362687191465
y[1] (numeric) = 4.0048570615982244233626871914683
absolute error = 3.3e-30
relative error = 8.2399944598348884906066156125198e-29 %
Correct digits = 30
h = 1e-05
TOP MAIN SOLVE Loop
NO POLE
x[1] = 1.10024
y[1] (analytic) = 4.0048871103190837594975943321555
y[1] (numeric) = 4.004887110319083759497594332159
absolute error = 3.5e-30
relative error = 8.7393224917172319805740996069689e-29 %
Correct digits = 30
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.10025
y[1] (analytic) = 4.0049171593404318066669139213877
y[1] (numeric) = 4.0049171593404318066669139213914
absolute error = 3.7e-30
relative error = 9.2386430300329895193557928689446e-29 %
Correct digits = 30
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.10026
y[1] (analytic) = 4.0049472086622715697727807889194
y[1] (numeric) = 4.0049472086622715697727807889232
absolute error = 3.8e-30
relative error = 9.4882648934323210970541737243092e-29 %
Correct digits = 30
h = 1e-05
TOP MAIN SOLVE Loop
NO POLE
x[1] = 1.10027
y[1] (analytic) = 4.0049772582846060537473789361022
y[1] (numeric) = 4.0049772582846060537473789361062
absolute error = 4.0e-30
relative error = 9.9875723182339919434296229527057e-29 %
Correct digits = 30
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.10028
y[1] (analytic) = 4.0050073082074382635529418363751
y[1] (numeric) = 4.0050073082074382635529418363792
absolute error = 4.1e-30
relative error = 1.0237184815113554883501426124297e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.10029
y[1] (analytic) = 4.0050373584307712041817527357601
y[1] (numeric) = 4.0050373584307712041817527357643
absolute error = 4.2e-30
relative error = 1.0486793565505261214040801049280e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 7.477e-16
Order of pole = 0.5
x[1] = 1.1003
y[1] (analytic) = 4.0050674089546078806561449533619
y[1] (numeric) = 4.0050674089546078806561449533663
absolute error = 4.4e-30
relative error = 1.0986082257098579974721126388869e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.10031
y[1] (analytic) = 4.0050974597789512980285021818702
y[1] (numeric) = 4.0050974597789512980285021818747
absolute error = 4.5e-30
relative error = 1.1235681641186237910562407684536e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.10032
y[1] (analytic) = 4.0051275109038044613812587880645
y[1] (numeric) = 4.0051275109038044613812587880691
absolute error = 4.6e-30
relative error = 1.1485277278879831507573551460936e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 7.477e-16
Order of pole = 0.5
x[1] = 1.10033
y[1] (analytic) = 4.0051575623291703758269001133227
y[1] (numeric) = 4.0051575623291703758269001133274
absolute error = 4.7e-30
relative error = 1.1734869170207498744331121064606e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
NO POLE
x[1] = 1.10034
y[1] (analytic) = 4.0051876140550520465079627741321
y[1] (numeric) = 4.005187614055052046507962774137
absolute error = 4.9e-30
relative error = 1.2234133509263989727564201194722e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
NO POLE
x[1] = 1.10035
y[1] (analytic) = 4.0052176660814524785970349626041
y[1] (numeric) = 4.0052176660814524785970349626091
absolute error = 5.0e-30
relative error = 1.2483716034568986240680085793092e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.10036
y[1] (analytic) = 4.0052477184083746772967567469909
y[1] (numeric) = 4.005247718408374677296756746996
absolute error = 5.1e-30
relative error = 1.2733294813601849941699630518607e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 7.477e-16
Order of pole = 0.5
x[1] = 1.10037
y[1] (analytic) = 4.0052777710358216478398203722061
y[1] (numeric) = 4.0052777710358216478398203722113
absolute error = 5.2e-30
relative error = 1.2982869846390719203982112242347e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
NO POLE
x[1] = 1.10038
y[1] (analytic) = 4.0053078239637963954889705603477
y[1] (numeric) = 4.0053078239637963954889705603531
absolute error = 5.4e-30
relative error = 1.3482109833585689710621701580342e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.10039
y[1] (analytic) = 4.0053378771923019255370048112249
y[1] (numeric) = 4.0053378771923019255370048112304
absolute error = 5.5e-30
relative error = 1.3731675500633269636238208355247e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
NO POLE
x[1] = 1.1004
y[1] (analytic) = 4.0053679307213412433067737028868
y[1] (numeric) = 4.0053679307213412433067737028924
absolute error = 5.6e-30
relative error = 1.3981237421530649948402090998137e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 7.477e-16
Order of pole = 0.5
x[1] = 1.10041
y[1] (analytic) = 4.005397984550917354151181192155
y[1] (numeric) = 4.0053979845509173541511811921607
absolute error = 5.7e-30
relative error = 1.4230795596305969415152338208156e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.10042
y[1] (analytic) = 4.0054280386810332634531849151588
y[1] (numeric) = 4.0054280386810332634531849151646
absolute error = 5.8e-30
relative error = 1.4480350024987366897374888199292e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.10043
y[1] (analytic) = 4.0054580931116919766257964878734
y[1] (numeric) = 4.0054580931116919766257964878794
absolute error = 6.0e-30
relative error = 1.4979560041630150524200111800504e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.10044
y[1] (analytic) = 4.0054881478428964991120818066616
y[1] (numeric) = 4.0054881478428964991120818066677
absolute error = 6.1e-30
relative error = 1.5229105104917301012913289162128e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.10045
y[1] (analytic) = 4.0055182028746498363851613488175
y[1] (numeric) = 4.0055182028746498363851613488238
absolute error = 6.3e-30
relative error = 1.5728302009659234403507810147866e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.10046
y[1] (analytic) = 4.0055482582069549939482104731144
y[1] (numeric) = 4.0055482582069549939482104731208
absolute error = 6.4e-30
relative error = 1.5977837707702211559248926095077e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.10047
y[1] (analytic) = 4.0055783138398149773344597203546
y[1] (numeric) = 4.0055783138398149773344597203611
absolute error = 6.5e-30
relative error = 1.6227369659810721048545920654866e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.10048
y[1] (analytic) = 4.0056083697732327921071951139231
y[1] (numeric) = 4.0056083697732327921071951139298
absolute error = 6.7e-30
relative error = 1.6726547833679764492285850790611e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.10049
y[1] (analytic) = 4.0056384260072114438597584603438
y[1] (numeric) = 4.0056384260072114438597584603507
absolute error = 6.9e-30
relative error = 1.7225718515182772439776809144540e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
NO POLE
x[1] = 1.1005
y[1] (analytic) = 4.0056684825417539382155476498388
y[1] (numeric) = 4.0056684825417539382155476498459
absolute error = 7.1e-30
relative error = 1.7724881704376022681611818240432e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 7.477e-16
Order of pole = 0.5
x[1] = 1.10051
y[1] (analytic) = 4.0056985393768632808280169568909
y[1] (numeric) = 4.0056985393768632808280169568981
absolute error = 7.2e-30
relative error = 1.7974393053352563150289836580430e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 7.477e-16
Order of pole = 0.5
x[1] = 1.10052
y[1] (analytic) = 4.0057285965125424773806773408086
y[1] (numeric) = 4.0057285965125424773806773408159
absolute error = 7.3e-30
relative error = 1.8223900656563472481934870823007e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 7.477e-16
Order of pole = 0.5
x[1] = 1.10053
y[1] (analytic) = 4.0057586539487945335870967462948
y[1] (numeric) = 4.0057586539487945335870967463022
absolute error = 7.4e-30
relative error = 1.8473404514036890674436396376823e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.10054
y[1] (analytic) = 4.0057887116856224551909004040179
y[1] (numeric) = 4.0057887116856224551909004040255
absolute error = 7.6e-30
relative error = 1.8972543354144970589367494137676e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.10055
y[1] (analytic) = 4.0058187697230292479657711311866
y[1] (numeric) = 4.0058187697230292479657711311943
absolute error = 7.7e-30
relative error = 1.9222037847040180072381339473492e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.10056
y[1] (analytic) = 4.0058488280610179177154496321267
y[1] (numeric) = 4.0058488280610179177154496321345
absolute error = 7.8e-30
relative error = 1.9471528594291698486041691560873e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.10057
y[1] (analytic) = 4.0058788866995914702737347988617
y[1] (numeric) = 4.0058788866995914702737347988696
absolute error = 7.9e-30
relative error = 1.9721015595927666222496400690292e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.10058
y[1] (analytic) = 4.0059089456387529115044840116963
y[1] (numeric) = 4.0059089456387529115044840117044
absolute error = 8.1e-30
relative error = 2.0220130087625926563722611519500e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 7.477e-16
Order of pole = 0.5
memory used=7.6MB, alloc=3.9MB, time=0.81
x[1] = 1.10059
y[1] (analytic) = 4.0059390048785052473016134398027
y[1] (numeric) = 4.005939004878505247301613439811
absolute error = 8.3e-30
relative error = 2.0719237087464660133046823040945e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.1006
y[1] (analytic) = 4.0059690644188514835890983418101
y[1] (numeric) = 4.0059690644188514835890983418185
absolute error = 8.4e-30
relative error = 2.0968709106141321185685639495860e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
NO POLE
x[1] = 1.10061
y[1] (analytic) = 4.0059991242597946263209733663967
y[1] (numeric) = 4.0059991242597946263209733664053
absolute error = 8.6e-30
relative error = 2.1467802995561209249739192650465e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
NO POLE
x[1] = 1.10062
y[1] (analytic) = 4.0060291844013376814813328528856
y[1] (numeric) = 4.0060291844013376814813328528944
absolute error = 8.8e-30
relative error = 2.1966889393281029962048251746598e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.10063
y[1] (analytic) = 4.006059244843483655084331131843
y[1] (numeric) = 4.006059244843483655084331131852
absolute error = 9.0e-30
relative error = 2.2465968299357063363451743678081e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.10064
y[1] (analytic) = 4.0060893055862355531741828256795
y[1] (numeric) = 4.0060893055862355531741828256887
absolute error = 9.2e-30
relative error = 2.2965039713845589680304606556432e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.10065
y[1] (analytic) = 4.0061193666295963818251631492548
y[1] (numeric) = 4.0061193666295963818251631492641
absolute error = 9.3e-30
relative error = 2.3214485513007113906120703115167e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.10066
y[1] (analytic) = 4.0061494279735691471416082104849
y[1] (numeric) = 4.0061494279735691471416082104943
absolute error = 9.4e-30
relative error = 2.3463927566862633666344536848848e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
NO POLE
x[1] = 1.10067
y[1] (analytic) = 4.0061794896181568552579153109523
y[1] (numeric) = 4.0061794896181568552579153109619
absolute error = 9.6e-30
relative error = 2.3962980253076504002876618169384e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 7.477e-16
Order of pole = 0.5
x[1] = 1.10068
y[1] (analytic) = 4.0062095515633625123385432465203
y[1] (numeric) = 4.00620955156336251233854324653
absolute error = 9.7e-30
relative error = 2.4212412943338728068062167026860e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.10069
y[1] (analytic) = 4.0062396138091891245780126079485
y[1] (numeric) = 4.0062396138091891245780126079583
absolute error = 9.8e-30
relative error = 2.4461841888388752142461766142308e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.1007
y[1] (analytic) = 4.0062696763556396982009060815126
y[1] (numeric) = 4.0062696763556396982009060815226
absolute error = 1.00e-29
relative error = 2.4960875846721937359426406259235e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
NO POLE
x[1] = 1.10071
y[1] (analytic) = 4.0062997392027172394618687496271
y[1] (numeric) = 4.0062997392027172394618687496373
absolute error = 1.02e-29
relative error = 2.5459902313824062799603906823455e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
NO POLE
x[1] = 1.10072
y[1] (analytic) = 4.0063298023504247546456083914705
y[1] (numeric) = 4.0063298023504247546456083914808
absolute error = 1.03e-29
relative error = 2.5709316277349954214129697402025e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.10073
y[1] (analytic) = 4.0063598657987652500668957836137
y[1] (numeric) = 4.0063598657987652500668957836242
absolute error = 1.05e-29
relative error = 2.6208329635177617032443418606512e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.10074
y[1] (analytic) = 4.0063899295477417320705650006519
y[1] (numeric) = 4.0063899295477417320705650006625
absolute error = 1.06e-29
relative error = 2.6457734235560473530521252516875e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 7.477e-16
Order of pole = 0.5
x[1] = 1.10075
y[1] (analytic) = 4.0064199935973572070315137158383
y[1] (numeric) = 4.0064199935973572070315137158491
absolute error = 1.08e-29
relative error = 2.6956734484301281884544472928019e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.10076
y[1] (analytic) = 4.0064500579476146813547035017226
y[1] (numeric) = 4.0064500579476146813547035017335
absolute error = 1.09e-29
relative error = 2.7206129721691192431326212441808e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 7.477e-16
Order of pole = 0.5
x[1] = 1.10077
y[1] (analytic) = 4.0064801225985171614751601307907
y[1] (numeric) = 4.0064801225985171614751601308017
absolute error = 1.10e-29
relative error = 2.7455521214131559686319825640959e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 7.477e-16
Order of pole = 0.5
x[1] = 1.10078
y[1] (analytic) = 4.0065101875500676538579738761084
y[1] (numeric) = 4.0065101875500676538579738761196
absolute error = 1.12e-29
relative error = 2.7954502736079810263364810778300e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
NO POLE
x[1] = 1.10079
y[1] (analytic) = 4.0065402528022691649982998119683
y[1] (numeric) = 4.0065402528022691649982998119796
absolute error = 1.13e-29
relative error = 2.8203884865742986884398881290746e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
NO POLE
x[1] = 1.1008
y[1] (analytic) = 4.0065703183551247014213581145386
y[1] (numeric) = 4.0065703183551247014213581145501
absolute error = 1.15e-29
relative error = 2.8702853279064028597271542294941e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.10081
y[1] (analytic) = 4.0066003842086372696824343625164
y[1] (numeric) = 4.006600384208637269682434362528
absolute error = 1.16e-29
relative error = 2.8952226046100106051033866183471e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.10082
y[1] (analytic) = 4.0066304503628098763668798377826
y[1] (numeric) = 4.0066304503628098763668798377944
absolute error = 1.18e-29
relative error = 2.9451181350981551227214335747988e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.10083
y[1] (analytic) = 4.0066605168176455280901118260608
y[1] (numeric) = 4.0066605168176455280901118260728
absolute error = 1.20e-29
relative error = 2.9950129165251047394281219724609e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
NO POLE
x[1] = 1.10084
y[1] (analytic) = 4.0066905835731472314976139175787
y[1] (numeric) = 4.0066905835731472314976139175909
absolute error = 1.22e-29
relative error = 3.0449069488964878254668390053981e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.10085
y[1] (analytic) = 4.0067206506293179932649363077327
y[1] (numeric) = 4.006720650629317993264936307745
absolute error = 1.23e-29
relative error = 3.0698421658290784730800632446250e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.10086
y[1] (analytic) = 4.0067507179861608200976960977554
y[1] (numeric) = 4.0067507179861608200976960977678
absolute error = 1.24e-29
relative error = 3.0947770082967335667862061270638e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 7.477e-16
Order of pole = 0.5
x[1] = 1.10087
y[1] (analytic) = 4.0067807856436787187315775953862
y[1] (numeric) = 4.0067807856436787187315775953987
absolute error = 1.25e-29
relative error = 3.1197114763022674608642354463537e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
NO POLE
x[1] = 1.10088
y[1] (analytic) = 4.0068108536018746959323326155449
y[1] (numeric) = 4.0068108536018746959323326155575
absolute error = 1.26e-29
relative error = 3.1446455698484945188483247168045e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.10089
y[1] (analytic) = 4.0068409218607517584957807810081
y[1] (numeric) = 4.0068409218607517584957807810209
absolute error = 1.28e-29
relative error = 3.1945366061739632010353569181075e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.1009
y[1] (analytic) = 4.0068709904203129132478098230892
y[1] (numeric) = 4.0068709904203129132478098231021
absolute error = 1.29e-29
relative error = 3.2194697635240847334043950757456e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 7.477e-16
Order of pole = 0.5
x[1] = 1.10091
y[1] (analytic) = 4.0069010592805611670443758823203
y[1] (numeric) = 4.0069010592805611670443758823334
absolute error = 1.31e-29
relative error = 3.2693594890890827674548682834978e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
NO POLE
x[1] = 1.10092
y[1] (analytic) = 4.0069311284414995267715038091387
y[1] (numeric) = 4.0069311284414995267715038091519
absolute error = 1.32e-29
relative error = 3.2942917102581084764963190470620e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 7.477e-16
Order of pole = 0.5
x[1] = 1.10093
y[1] (analytic) = 4.0069611979031309993452874645746
y[1] (numeric) = 4.0069611979031309993452874645879
absolute error = 1.33e-29
relative error = 3.3192235569837753814242447296241e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 7.477e-16
Order of pole = 0.5
x[1] = 1.10094
y[1] (analytic) = 4.0069912676654585917118900209432
y[1] (numeric) = 4.0069912676654585917118900209567
absolute error = 1.35e-29
relative error = 3.3691114100843374425364867714438e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.10095
y[1] (analytic) = 4.0070213377284853108475442625395
y[1] (numeric) = 4.0070213377284853108475442625531
absolute error = 1.36e-29
relative error = 3.3940423206504852272542842144316e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.10096
y[1] (analytic) = 4.0070514080922141637585528863353
y[1] (numeric) = 4.007051408092214163758552886349
absolute error = 1.37e-29
relative error = 3.4189728567826555513706044313866e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
memory used=11.4MB, alloc=3.9MB, time=1.26
Complex estimate of poles used
Radius of convergence = 7.477e-16
Order of pole = 0.5
x[1] = 1.10097
y[1] (analytic) = 4.0070814787566481574812888026804
y[1] (numeric) = 4.0070814787566481574812888026942
absolute error = 1.38e-29
relative error = 3.4439030184836628686391007284433e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.10098
y[1] (analytic) = 4.0071115497217902990821954360059
y[1] (numeric) = 4.0071115497217902990821954360199
absolute error = 1.40e-29
relative error = 3.4937884374524102869693554709597e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
Complex estimate of poles used
Radius of convergence = 2.602e-16
Order of pole = 0.5
x[1] = 1.10099
y[1] (analytic) = 4.007141620987643595657787025531
y[1] (numeric) = 4.0071416209876435956577870255452
absolute error = 1.42e-29
relative error = 3.5436731074406384345186992454335e-28 %
Correct digits = 29
h = 1e-05
TOP MAIN SOLVE Loop
NO POLE
x[1] = 1.101
y[1] (analytic) = 4.0071716925542110543346489259728
y[1] (numeric) = 4.0071716925542110543346489259871
absolute error = 1.43e-29
relative error = 3.5686017713119344549963238991965e-28 %
Correct digits = 29
h = 1e-05
Finished!
Maximum Iterations Reached before Solution Completed!
diff ( y , x , 1 ) = y - 1.0;
Iterations = 100
Total Elapsed Time = 1 Seconds
Elapsed Time(since restart) = 1 Seconds
Expected Time Remaining = 1 Hours 19 Minutes 12 Seconds
Optimized Time Remaining = 1 Hours 17 Minutes 16 Seconds
Time to Timeout = 58 Seconds
Percent Done = 0.0259 %
> quit
memory used=11.9MB, alloc=3.9MB, time=1.31