git-svn-id: https://www.grenoble.prabi.fr/svn/LECASofts/ecoPrimers/trunk@221 60f365c0-8329-0410-b2a4-ec073aeeaa1d
98 lines
3.4 KiB
C
98 lines
3.4 KiB
C
/*
|
|
* galign.h
|
|
* PHunterLib
|
|
*
|
|
* Created by Tiayyba Riaz on 7/2/09.
|
|
* Copyright 2009 __MyCompanyName__. All rights reserved.
|
|
*
|
|
*/
|
|
|
|
//=============================================================================
|
|
// Module: galign.h
|
|
// Project: Cubic Project - Calculation of melting temperature and free
|
|
// energy of two DNA strands
|
|
// Type: header file - Thermodynamic Alignment.
|
|
// Language: c++
|
|
// Compiler: microsoft visual c++ 6.0, unix/linux gcc
|
|
// System/OS: Windows 32, Sun solaris, Linux, other unix systems (untested)
|
|
// Database: none
|
|
// Description: class GAlign - Thermodynamic Alignment Algorithm
|
|
// Author: leber
|
|
// Date: 01/2002 - 02/2002
|
|
// Copyright: (c) L. Kaderali & M. Leber, 01/2002 - 02/2002
|
|
//
|
|
// Revision History
|
|
// $ 00sep04 LK : created
|
|
// $ 00dec30 LK : changed to do local alignment of probe against
|
|
// one entire sequence
|
|
// $ 01feb07 LK : optimized
|
|
// #$
|
|
//=============================================================================
|
|
|
|
#if !defined(AFX_GAlign_H__1B9227F7_82AB_11D4_9FFF_000000000000__INCLUDED_)
|
|
#define AFX_GAlign_H__1B9227F7_82AB_11D4_9FFF_000000000000__INCLUDED_
|
|
|
|
#if _MSC_VER > 1000
|
|
#pragma once
|
|
#endif // _MSC_VER > 1000
|
|
|
|
//#include <iostream>
|
|
//#include <strstream>
|
|
//#include <ostream>
|
|
#include "nnparams.h" // Nearest Neighbor Parameters
|
|
//#include "../gsfxtree/gsfxtree.h" // Suffix Tree Stuff
|
|
|
|
//using namespace std;
|
|
|
|
#ifdef _pack
|
|
#pragma pack(1)
|
|
#endif
|
|
|
|
//-----------------------------------------------------------------------------
|
|
// class GAlign
|
|
//#pragma GCC visibility push(hidden)
|
|
//typedef class GAlign* GGAlign;
|
|
|
|
typedef struct GAlign_st
|
|
{
|
|
//public:
|
|
// lk01feb07: removed maxlocstuff as not requiered by thermtreealign...
|
|
float maxlocg; // maximum local dG value found
|
|
int maxloci; // i position thereof
|
|
int maxlocj; // j position thereof
|
|
int maxloct; // and type of maximum alignment!
|
|
int targetNumber; // id number of target sequence
|
|
// PGSfxLeaf probeNode; // identifier for probe sequence
|
|
//private:
|
|
char *seq1; // Sequence 1
|
|
char *seq2; // Sequence 2
|
|
int seq1len; // Length of Sequence 1
|
|
int seq2len; // Length of Sequence 2
|
|
int maxseq1len; // length of longest target...
|
|
float *dH; // Dynamic Programming Table for Entropy
|
|
float *dS; // Dynamic Programming Table for Enthalpy
|
|
PNNParams GNNParams; // Nearest Neighbor parameters
|
|
// float forbidden_entropy;
|
|
}GAlign, * GGAlign;
|
|
|
|
void galn_initGAlign(GGAlign galn, int, int, PNNParams);
|
|
void galn_finiGAlign(GGAlign galn);
|
|
//void galn_InitStrings(GGAlign galn, char*,char*,int,int,int=0);
|
|
void galn_InitStrings(GGAlign galn, char*,char*,int,int,int);
|
|
void galn_InitBorder(GGAlign galn);
|
|
//void galn_CalculateTable(GGAlign galn, int=1);
|
|
void galn_CalculateTable(GGAlign galn, int);
|
|
float galn_GetEntropy(GGAlign galn, int, int);
|
|
float galn_GetEnthalpy(GGAlign galn, int, int);
|
|
float galn_GetFreeEnergyK(GGAlign galn, int, int, float);
|
|
float galn_GetFreeEnergyC(GGAlign galn, int, int, float);
|
|
float galn_GetMeltingTempC(GGAlign galn, int, int);
|
|
float galn_GetMeltingTempK(GGAlign galn, int, int);
|
|
|
|
void galn_printEnthalpyTable(GGAlign galn, int level);
|
|
void galn_printEntropyTable(GGAlign galn, int level);
|
|
|
|
//#pragma GCC visibility pop
|
|
#endif //!defined(AFX_GAlign_H__1B9227F7_82AB_11D4_9FFF_000000000000__INCLUDED_)
|
|
|