# Singular          #### D.15.12.1 diffAlgebra

Procedure from library `difform.lib` (see difform_lib).

Side effects:
If R is the basering, the differential algebra is constructed with name Omega_R and the differential forms dx_1,...,dx_n are available. The name of the differential algebra is stored in the attribute attrib(R,"diffAlgebra").

Note:
- computations with differential forms need the structure of the differential algebra, so this procedure should be executed first.
- the variable names 'd' or 'D' should be avoided.
- the procedure also works for quotient rings

Example:
 ```LIB "difform.lib"; /////////////////////////////////////////////////////////////// // Example for a differential algebra over a polynomial ring // /////////////////////////////////////////////////////////////// ring R = 0,(a,b,c),ds; diffAlgebra(); ==> // The differential algebra Omega_R was constructed and the differential \ forms da, db, dc are available. setring Omega_R; // The differential algebra is given by: basering; ==> // coefficients: QQ ==> // number of vars : 6 ==> // block 1 : ordering dp ==> // : names Da Db Dc ==> // block 2 : ordering ds ==> // : names a b c ==> // block 3 : ordering C ==> // noncommutative relations: ==> // DbDa=-Da*Db ==> // DcDa=-Da*Dc ==> // DcDb=-Db*Dc ==> // quotient ring from ideal ==> _=Da^2 ==> _=Db^2 ==> _=Dc^2 kill R,Omega_R,da,db,dc; ///////////////////////////////////////////////////////////// // Example for a differential algebra over a quotient ring // ///////////////////////////////////////////////////////////// ring R = 0,(x,y,z),lp; ideal I = x+y+z,xyz; qring S = std(I); diffAlgebra(); ==> // The differential algebra Omega_S was constructed and the differential \ forms dx, dy, dz are available. setring Omega_S; // The differential algebra is given by: basering; ==> // coefficients: QQ ==> // number of vars : 6 ==> // block 1 : ordering dp ==> // : names Dx Dy Dz ==> // block 2 : ordering lp ==> // : names x y z ==> // block 3 : ordering C ==> // noncommutative relations: ==> // DyDx=-Dx*Dy ==> // DzDx=-Dx*Dz ==> // DzDy=-Dy*Dz ==> // quotient ring from ideal ==> _=y^2*z+y*z^2 ==> _=x+y+z ==> _=Dz*y^4+3*Dz*y^3*z+2*Dz*y^2*z^2 ==> _=Dy*z^3+2*Dz*y^3+5*Dz*y^2*z+2*Dz*y*z^2 ==> _=2*Dy*y*z+Dy*z^2+Dz*y^2+2*Dz*y*z ==> _=Dx+Dy+Dz ==> _=Dy*Dz*y^2+2*Dy*Dz*y*z ==> _=Dz^2 ==> _=Dy^2 ==> _=Dx^2 kill Omega_S,dx,dy,dz; ``` 