Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

Coefficient of Polynomial of Differential Forms and displaying List for differential forms

The coefficient function gives us the coefficient of a polynomial. For example,

g(x)=3*x^(2)

g.coefficient(x^(2))

Just started learning differential forms, so using notation here- https://ask.sagemath.org/question/40345/differential-forms-best-package/

U = Manifold(4, 'U')

X. < x,y,z,w > = U.chart()

f = U.diff_form(4, 'f')

f[0,1,2,3]=3*x^(2)

f.display()

(f[0,1,2,3]).coefficient(x^(2))

I want to work backwards. For example, given a 4-form named Form, Form[0,1,2,3] gives me the polynomial of the form. I wish to find the coefficient of this polynomial the same way. So from above, I should be getting 3. But I get:

'ChartFunctionRing_with_category.element_class' object has no attribute 'coefficient'.

Question 1: How do I fix this?

Question 2: Suppose I have a list of 4-forms called List. From the link above, I can view every form in List by doing List[1].display().

However, how do I quickly view all the forms?

List.display() gives me an error so can I only view the forms term by term?

Question