Back to Download Form

Glut demo- Surface Finder and database

Note: several large BMP files on page, will take time to load.


This page illusrates some of the surface extraction features that are implemented independent of the viewer. The viewer contains various pieces of code to find surfaces and map out iso-potential curves for simplified force fields, but this code is designed to be faster and allow database oriented surface representations ( eventually). Two programs are used here, pdb_proc to generate the results and streaming_data to view them.

pdb_proc uses my "left to right" command line interface that gives some simple scritping capability. In this case, a variety of parameters are read from the source file and combined with command line arguments. PDB files are read sequentially and placed onto a molecule stack. In this case, only one file is read but pieces of it are selected and pushed onto the same stack. These commands select against HOH,H, and HETATOM entries to make the surface finder operand. A probe radius is selected, and the -grid command generates the surface description. Additionally, the ligand is output as solid sphere using the trailing command line arguments ("-op clear... " ).


 
$ ./pdb_proc -source 1ac4.src -v 1 -out xxx -flags 1 -grid 2  -op clear all -add type ATOM -add residue HOH -make 1 -list 0 

$ cat xxx | grep "^LINE\|^NORM\|^RAW\|COLOR" | sed -e 's/RAW//' | ../streaming_data -history 500000 -config 1ac4.scr

$ cat 1ac4.src
-color_file ../colbr.dat
-radius_file ../radii.dat
-pdb ../pdb/1ac4.pdb
-add residue HOH
-add type HETATM
-add elem H
-make 0
-cat 0
-probe_radius 1.5
-visible .5
-surf 0

$ cat 1ac4.scr
SCRIPT zoom,600
SCRIPT move,0,-300
SCRIPT rotcen,-5,57,111
 
 








pdb_proc generated the file "xxx" which streaming_data then displayed. Below is the image generated with the raw output and a short, hardcoded script to center the image.



The golf-ball appearance is due to a sampling grid problem (I'm trying to replaced the grid with an analytical solution so I'm not going to fix it :) ). The internal structure is easily probed with the surface finder and slicing capability from the molecule viewer using these commands,

$ cat 1ac4hist
 print 1ac4.bmp bmp
 near 3165
 far 3166
 zoom -300
 zoom -200
 zoom -100
 slice
 zoom -100
 print 1ac41slice1.bmp bmp
 history  1ac4hist

Note that "slice" allows the user to move the clip planes with key strokes to obtain desired slice. This illustrates the surface and small piece of ligand in cavity,



If you saw the auto-center script from another demo, you can appreciate that it would be possible to find slice bounds and automatically generate slice images with no user intervention.

The above can be repeated without the ligand to show that the cavity was automtically found. Note that the molcule viewer has, and sometime the data viewer may have, the ability to highlight or hide various groups of things.



Of course, the ultimate goal is to create a surface database. This program can also output text surface descriptions against which to compare experimental surface queries.

$ ./pdb_proc -source g1.src -pdb ../pdb/1ac4.pdb -source generic.src -v 1 -out
xxx3 -pfx "1ac4" -source g2.src
COMPND    Variation In The Strength Of A Ch To O Hydrogen Bond In An
COMPND   2 Artificial Protein Cavity (2,3,4-Trimethyl-1,3-Thiazole)
problem wiht ATOM      7  H   LEU     4      10.605  79.297 113.855  1.00  0.00
          H try name is .H.
pdb_atom 7 radius ATOM      7  H   LEU     4      10.605  79.297 113.855  1.00
0.00           H 0
No color :ATOM      7  H   LEU     4      10.605  79.297 113.855  1.00  0.00
       H
problem wiht ATOM   1131  SD  MET   119      -0.149  47.699 103.721  1.00 13.01
          S try name is .S.
problem wiht HETATM 2842 FE   HEM 1   2      -5.699  57.157 111.785  1.00 11.76
         Fe try name is .F.
No color :HETATM 2842 FE   HEM 1   2      -5.699  57.157 111.785  1.00 11.76
      Fe
 Catalog of
recs:
ATOM 2338
atoms:
C 291   CA 291  CB 265  CD 77   CD1 73
CD2 69  CE 28   CE1 38  CE2 38  CE3 6
CG 195  CG1 24  CG2 37  CH2 6   CZ 42
CZ2 6   CZ3 6   N 291   ND1 6   ND2 19
NE 10   NE1 6   NE2 15  NH1 10  NH2 10
NZ 21   O 291   OD1 44  OD2 25  OE1 29
OE2 20  OG 15   OG1 13  OH 14   OXT 1
SD 5    SG 1
resd:
ALA 85  ARG 110 ASN 152 ASP 200 CYS 6
GLN 81  GLU 180 GLY 104 HIS 60  ILE 80
LEU 201 LYS 205 MET 40  PHE 198 PRO 105
SER 90  THR 91  TRP 84  TYR 168 VAL 98
chan:
 2338
elem:
C 1492  N 388   O 452   S 6
find_surface_molecules.h258 making grid with flags: no patches,  no whole atoms,
  use atom+probe radius,  save hits to list
find_surface_molecules.h326 Grid output 14473 entries uniq 1143 (0) out of 2338
avarging 12.6623
point_list_stuff.h130 Adding ATOM to type for total size of 1
point_list_stuff.h130 Adding HOH to residue for total size of 1
pdb_proc.h157 Added  of size 51 to pdb stack size 3

using the scripts ( you have to guess which goes with which name :) ):


$ cat g*.src
-color_file ../colbr.dat
-radius_file ../radii.dat

-v 1
-flags 8
-grid 2
-enclaves 0
-op clear all
-add type ATOM
-add residue HOH
-make 1
-list 0

-add residue HOH
-add type HETATM
-add elem H
-make 0
-cat 0
-probe_radius 1.5
-visible .5
-surf 0

The generated records in file xxx3 contain simple geometrical relationships specific to the surface that can provide details or summary information. The first few entries are shown along with a summary of surface neighbor ( not bonds, the program defines "neighbor" ) configurations,


$ head xxx3
1ac4 2 CA LEU   8 N LEU  1.45423 43 0.0954307
1ac4 2 CA LEU   16 N VAL  2.40967 11 -0.235353
1ac4 2 CA LEU   9 O LEU  2.4321 12 0.563767
1ac4 2 CA LEU   6 CG LEU  2.60019 2 0.339505
1ac4 2 CA LEU   5 CD2 LEU  3.13595 61 -0.191533
1ac4 2 CA LEU   4 CD1 LEU  3.8746 14 0.513156
1ac4 2 CA LEU   17 O VAL  4.26341 25 -0.199978
1ac4 2 CA LEU   586 CB ASN  4.38096 7 1.05685
1ac4 2 CA LEU   590 ND2 ASN  4.58418 14 0.863597
1ac4 2 CA LEU   581 O ASP  4.62384 3 0.845991

Administrator@TESTBED01 
$ more xxx3  | grep "^1ac4" | awk '{if ($3<$6) {print $3" "$6}else{print $6" "$3 }}' | sort | uniq -c | sort -g -r  | head
    622 CB O
    554 CA O
    548 CA CB
    464 CB N
    454 CB CG
    396 CG O
    378 N O
    370 CA N
    360 CA CG
    308 CB CB

The program also provides facilities for sensitivity testing. Rotation shouldn't effect anything but adding a small random component ("-shake") causes difference. It turns out that rotation DOES matter to the CODE. The below test seemed exciting since it implied EXACT rotational invariance for any angles. It turned out to be a programming error as the angles got internally zeroed out.

$ ./pdb_proc -source g1.src -pdb ../pdb/1ac4.pdb -angles 3 10 10 -center -5 57 11001 -mutate 0 -source generic.src -v 1 -out xxx4 -pfx "1ac4" -source g2.src

$ diff xxx3 xxx4 | wc
      0       0       0
      
$ ./pdb_proc -source g1.src -pdb ../pdb/1ac4.pdb -angles 3 10 10 -center -5 57 11001 -shake .0000005 -mutate 0 -source generic.src -v 1 -out xxx4 -pfx "1ac4" -source g2.src

$ diff xxx3 xxx4 | head
19c19
< 1ac4 4 CD1 LEU   6 CG LEU  1.50961 2 0.658611
---
> 1ac4 4 CD1 LEU   6 CG LEU  1.50961 2 0.65861
53c53
< 1ac4 6 CG LEU   4 CD1 LEU  1.50961 14 0.458579
---
> 1ac4 6 CG LEU   4 CD1 LEU  1.50961 14 0.458578
55c55
< 1ac4 6 CG LEU   2 CA LEU  2.60019 4 0.0985823