aboutsummaryrefslogtreecommitdiff
path: root/Sunder.f
diff options
context:
space:
mode:
Diffstat (limited to 'Sunder.f')
-rwxr-xr-xSunder.f24
1 files changed, 24 insertions, 0 deletions
diff --git a/Sunder.f b/Sunder.f
new file mode 100755
index 0000000..8bf956b
--- /dev/null
+++ b/Sunder.f
@@ -0,0 +1,24 @@
+
+ subroutine sunder (amol,i1,i2)
+c******************************************************************************
+c This routine breaks up molecule amol into leftmost atom i1 and
+c the rest of the molecule i2
+c******************************************************************************
+
+ implicit real*8 (a-h,o-z)
+ dimension itest(5)
+ data itest/100000000,1000000,10000,100,1/
+
+ im = nint(amol)
+
+ do i=1,5
+ i1 = im/itest(i)
+ if (i1 .eq. 0) cycle
+ i2 = im - i1*itest(i)
+ exit
+ enddo
+
+ return
+
+ end
+