Presentation is loading. Please wait.

Presentation is loading. Please wait.

What is shape function ? shape function is a function that will give the displacements inside an element if its displacement at all the node locations.

Similar presentations


Presentation on theme: "What is shape function ? shape function is a function that will give the displacements inside an element if its displacement at all the node locations."— Presentation transcript:

1 What is shape function ? shape function is a function that will give the displacements inside an element if its displacement at all the node locations of the element are known. Shape functions for a beam element : The shape function (N) is given by_ N = b1 0 0 b2 0 0 0 b3 b4 0 b5 b6 Here, b1 = (1- x/L) b2= x/L b3 = 1-3x 2 /L 2 +2x 3 /l 3 b4 = x-2x 2 /L+x 3 /L 2 b5 = 3x 2 /L 2 -2x 2 /L 3 b6 = -x 2 /L 2+ x 3 /L 2 x =length from one end at which shape function is to be found L= length of beam element

2 Flowchart: TO CALCULATE THE VALUE OF THE SHAPE FUNCTION FOR A GIVEN BEAM ELEMENT. Start Float l,x,b1,b2,b4,b5,b6,b[2][7] input l,x b1=1.0-(x/l); b2=x/l; b3=1.0-(3.0*x*x/(l*l)+(2.0*x*x*x/(l*l*l))); b4=x-(2.0*x*x/l)+(x*x*x/(l*l)); b5=(3.0*x*x/(l*l)-(2.0*x*x*x/(l*l*l))); b6=-(x*x/(l))+(x*x*x/(l*l)); b[1][1]=b1;b[1][2]=0.0;b[1][3]=0.0;b[1][4]=b2;b[1][5]=0.0;b[1][6]=0.0; b[2][1]=0.0;b[2][2]=b3;b[2][3]=b4;b[2][4]=0.0;b[2][5]=b5;b[2][6]=b6; The shape function is as follows i=1 to 2 i++ Output b[ i ][ j ] Stop j=1 to 6 j++ true false true false

3 EXPLAINTION: Start program Define data type enter the length of beam element l enter length from one end at which shape function is to be found(X) Calculate: bending element b1,b2,b3,b4,b5,b6 Define shape function matrix Show calculated shape function End of program i is a variable used for rows of matrix, i varies from 1 to 2, in each step i varies by 1 j is a variable used for columns of matrix, j varies from 1 to 6, in each step i varies by 1 If this condition is true If this condition is false If this condition is true If this condition is false

4 Program: /*Compute the value of shape function for a given beam element*/ /*include header files*/ #include /*define data type of programming variables*/ float l,x,b1,b2,b4,b5,b6,b[2][7]; double b3; int i,j; /*main program starts here*/ void main() { clrscr(); /*input values*/ printf("enter the length of beam element l in cms\n"); scanf("%f",&l); printf("enter length from one end at which shape function is to be found in "); printf("centimeters\n"); scanf("%f",&x); /*calculate beam element*/ b1=1.0-(x/l); b2=x/l; b3=1.0-(3.0*x*x/(l*l)+(2.0*x*x*x/(l*l*l))); b4=x-(2.0*x*x/l)+(x*x*x/(l*l)); b5=(3.0*x*x/(l*l)-(2.0*x*x*x/(l*l*l))); b6=-(x*x/(l))+(x*x*x/(l*l));

5 /*matrix of beam element*/ b[1][1]=b1;b[1][2]=0.0;b[1][3]=0.0;b[1][4]=b2;b[1][5]=0.0; b[1][6]=0.0; b[2][1]=0.0;b[2][2]=b3;b[2][3]=b4;b[2][4]=0.0;b[2][5]=b5; b[2][6]=b6; printf("the shape function is as follows\n"); /*calculate shape function*/ for(i=1;i<=2;++i) { for(j=1;j<=6;++j) { printf("%10.3f",b[i][j]); } printf("\n"); } getch(); return; }


Download ppt "What is shape function ? shape function is a function that will give the displacements inside an element if its displacement at all the node locations."

Similar presentations


Ads by Google