Skip to content

Commit

Permalink
Update Lorene and its patches.
Browse files Browse the repository at this point in the history
git-svn-id: http://svn.cactuscode.org/projects/ExternalLibraries/LORENE/trunk@51 5c1b1641-b641-47ec-b3d9-0f93d4c445ee
  • Loading branch information
bmundim committed Apr 18, 2014
1 parent 14b667f commit 851435b
Show file tree
Hide file tree
Showing 4 changed files with 539 additions and 458 deletions.
Binary file modified dist/Lorene.tar.gz
Binary file not shown.
58 changes: 58 additions & 0 deletions dist/README
Original file line number Diff line number Diff line change
Expand Up @@ -19,3 +19,61 @@ This tarball LORENE.tar.gz is created in the following way:
5. Remove the cvs source tree again:

rm -rf Lorene


Note: In case the patches do not apply cleanly do the following:

1. backup the original patches so that you have them close by as a reference.

2. des.patch is supposed to comment out any call to the graphics
device. Search for des_meridian, des_coupe* to identify the pieces
of code to comment out. Comment them out and create the patch with:

cvs diff -u > ../des.patch

Fix Lorene paths in the des.patch so you can apply the patch
from the parent directory. For example replace C++/Source/...
for Lorene/C++/Source/... (Any cvs command that would do this for
you on one go?)

2. Erase the previously edited Lorene directory. Have now two original
copies of Lorene: Lorene and Lorene.orig. Apply the makesystem.patch patch
to Lorene. Fix what went wrong and create the new patch:

diff --new-file -ru Lorene.orig Lorene > makesystem.patch

Remove Lorene and Lorene.orig directories. Untar Lorene.tar.gz again
and apply the newly created patch:

patch -p0 < makesystem.patch

If applied cleanly then create a copy of Lorene with this patch:

cp -r Lorene Lorene.orig

3. Apply pgplot.patch. If you need to fix it follow the procedure in
step 2. above. Copy the patched Lorene to Lorene.orig.

4. Apply openmp.patch and if everything went cleanly copy it to Lorene.orig.
Otherwise follow step 2 to fix the issues.

5. Apply check_fopen_error.patch. If succeded then copy Lorene to Lorene.orig
if failed, fix it as in 2.

6. Once satisfied with all fixes in these patches test them if they apply
cleanly to Lorene:

tar -xzf Lorene.tar.gz
patch -p0 < des.patch
patch -p0 < makesystem.patch
patch -p0 < pgplot.patch
patch -p0 < openmp.patch
patch -p0 < check_fopen_error.patch
patch -p0 < patchtest.patch

If applied cleanly get rid of the original ones, propose the patch to the
ET Trac system for reviewing and erase lorene source tree:

rm -rf Lorene


109 changes: 62 additions & 47 deletions dist/des.patch
Original file line number Diff line number Diff line change
Expand Up @@ -4,16 +4,25 @@ RCS file: /cvsroot/Lorene/C++/Source/Bin_hor/binhor_hh.C,v
retrieving revision 1.3
diff -u -r1.3 binhor_hh.C
--- Lorene/C++/Source/Bin_hor/binhor_hh.C 9 Jan 2008 14:28:58 -0000 1.3
+++ Lorene/C++/Source/Bin_hor/binhor_hh.C 30 Nov 2009 03:47:22 -0000
@@ -892,7 +892,7 @@
// des_profile(hh1(i,j), 0., 20., M_PI/2, M_PI) ;
//des_profile(hh1(i,j), 0., 20., M_PI/2, 0) ;
+++ Lorene/C++/Source/Bin_hor/binhor_hh.C 27 Mar 2014 13:38:39 -0000
@@ -885,7 +885,7 @@
cout << hole1.mp.phi << endl ;
cout << hole1.mp.tet << endl ;

-
+ /*
//des_meridian(hh1, 0., 20., "hh1 cart", 20) ;
for (int i=1 ; i<= 3 ; i++)
for (int j=i ; j<= 3 ; j++){
@@ -894,7 +894,7 @@
//des_profile(hh1(i,j), 0., 20., 0, M_PI) ;
- des_coupe_z (hh1(i,j), 0., 5) ;
+ //des_coupe_z (hh1(i,j), 0., 5) ;
des_coupe_z (hh1(i,j), 0., 5) ;
}

-
+ */
hh1.change_triad(hole1.mp.get_bvect_spher()) ;
hh2.change_triad(hole2.mp.get_bvect_spher()) ;

@@ -908,7 +908,7 @@
hole2.tgam = tgam_2 ;

Expand All @@ -29,41 +38,45 @@ RCS file: /cvsroot/Lorene/C++/Source/Isol_hor/init_data.C,v
retrieving revision 1.28
diff -u -r1.28 init_data.C
--- Lorene/C++/Source/Isol_hor/init_data.C 19 Aug 2008 06:42:00 -0000 1.28
+++ Lorene/C++/Source/Isol_hor/init_data.C 30 Nov 2009 03:47:22 -0000
@@ -1262,10 +1262,10 @@
+++ Lorene/C++/Source/Isol_hor/init_data.C 27 Mar 2014 13:38:39 -0000
@@ -1261,13 +1261,13 @@

for (int mer=0; mer<niter; mer++) {


- des_meridian(psi_j, 1, 10., "psi", 0) ;
- des_meridian(nn_j, 1, 10., "nn", 1) ;
- des_meridian(theta_j, 1, 10., "Theta", 2) ;
- des_meridian(chi_j, 1, 10., "chi", 3) ;
+ //des_meridian(psi_j, 1, 10., "psi", 0) ;
+ //des_meridian(nn_j, 1, 10., "nn", 1) ;
+ //des_meridian(theta_j, 1, 10., "Theta", 2) ;
+ //des_meridian(chi_j, 1, 10., "chi", 3) ;
-
+ /*
des_meridian(psi_j, 1, 10., "psi", 0) ;
des_meridian(nn_j, 1, 10., "nn", 1) ;
des_meridian(theta_j, 1, 10., "Theta", 2) ;
des_meridian(chi_j, 1, 10., "chi", 3) ;
arrete() ;
-
+ */


@@ -1409,8 +1409,8 @@
//========
// Sources
@@ -1408,11 +1408,11 @@

// Iteration in theta/chi
for (int i=0 ; i<niter ; i++) {

- des_meridian(theta_i, 1, 10., "Theta", 2) ;
- des_meridian(chi_i, 1, 10., "chi", 3) ;
+ //des_meridian(theta_i, 1, 10., "Theta", 2) ;
+ //des_meridian(chi_i, 1, 10., "chi", 3) ;
-
+ /*
des_meridian(theta_i, 1, 10., "Theta", 2) ;
des_meridian(chi_i, 1, 10., "chi", 3) ;
arrete() ;
-
+ */


//Sources
Index: Lorene/C++/Source/Time_slice/tslice_conf_init.C
===================================================================
RCS file: /cvsroot/Lorene/C++/Source/Time_slice/tslice_conf_init.C,v
retrieving revision 1.10
diff -u -r1.10 tslice_conf_init.C
--- Lorene/C++/Source/Time_slice/tslice_conf_init.C 4 Dec 2008 18:22:49 -0000 1.10
+++ Lorene/C++/Source/Time_slice/tslice_conf_init.C 30 Nov 2009 03:47:23 -0000
@@ -223,7 +223,7 @@
retrieving revision 1.11
diff -u -r1.11 tslice_conf_init.C
--- Lorene/C++/Source/Time_slice/tslice_conf_init.C 20 Oct 2010 07:58:09 -0000 1.11
+++ Lorene/C++/Source/Time_slice/tslice_conf_init.C 27 Mar 2014 13:38:39 -0000
@@ -225,7 +225,7 @@
maxabs(psi_jp1.laplacian() - source_psi,
"Absolute error in the resolution of the equation for Psi") ;

Expand All @@ -72,7 +85,7 @@ diff -u -r1.10 tslice_conf_init.C

// Resolution of the Poisson equation for the lapse
// ------------------------------------------------
@@ -236,7 +236,7 @@
@@ -238,21 +238,21 @@
maxabs(nn_jp1.laplacian() - source_nn,
"Absolute error in the resolution of the equation for N") ;

Expand All @@ -81,41 +94,43 @@ diff -u -r1.10 tslice_conf_init.C

// Resolution of the vector Poisson equation for the shift
//---------------------------------------------------------
@@ -244,12 +244,14 @@
Vector beta_jp1 = source_beta.poisson(0.3333333333333333, ff,
method_poisson_vect) ;
-
+ /*
des_meridian(beta_jp1(1), 0., ray_des, "\\gb\\ur\\d", ngraph0+2,
graph_device) ;
des_meridian(beta_jp1(2), 0., ray_des, "\\gb\\u\\gh\\d", ngraph0+3,
graph_device) ;
des_meridian(beta_jp1(3), 0., ray_des, "\\gb\\u\\gf\\d", ngraph0+4,
graph_device) ;
+ */

-
+ */
// Test:
Vector test_beta = (beta_jp1.derive_con(ff)).divergence(ff)
+ 0.3333333333333333 * (beta_jp1.divergence(ff)).derive_con(ff) ;
Index: Lorene/C++/Source/Time_slice/tslice_dirac_max_evolve.C
===================================================================
RCS file: /cvsroot/Lorene/C++/Source/Time_slice/tslice_dirac_max_evolve.C,v
retrieving revision 1.16
diff -u -r1.16 tslice_dirac_max_evolve.C
--- Lorene/C++/Source/Time_slice/tslice_dirac_max_evolve.C 4 Dec 2008 18:22:49 -0000 1.16
+++ Lorene/C++/Source/Time_slice/tslice_dirac_max_evolve.C 30 Nov 2009 03:47:23 -0000
@@ -673,6 +673,7 @@
retrieving revision 1.20
diff -u -r1.20 tslice_dirac_max_evolve.C
--- Lorene/C++/Source/Time_slice/tslice_dirac_max_evolve.C 24 Jan 2013 12:55:18 -0000 1.20
+++ Lorene/C++/Source/Time_slice/tslice_dirac_max_evolve.C 27 Mar 2014 13:38:39 -0000
@@ -688,7 +688,7 @@
beta_new = relax * beta_new + (1.-relax) * beta() ;
beta_evol.update(beta_new, jtime, ttime) ;
}
+ /*
des_meridian(beta()(1), 0., ray_des, "\\gb\\ur\\d", ngraph0+6,
-
+ /*
des_meridian(vec_X()(1), 0., ray_des, "\\gb\\ur\\d", ngraph0+6,
graph_device) ;
des_meridian(beta()(2), 0., ray_des, "\\gb\\u\\gh\\d", ngraph0+7,
@@ -695,6 +696,7 @@
des_meridian(vec_X()(2), 0., ray_des, "\\gb\\u\\gh\\d", ngraph0+7,
@@ -713,6 +713,7 @@
graph_device) ;

arrete(nopause) ;
+ */

+ */
}

par_A.clean_all() ;
Loading

0 comments on commit 851435b

Please sign in to comment.