- Skyscrapers are of various shapes.
- Skyscrapers are various shapes.
Why do we use of in the sentence above?
Is there any difference in meaning between the two sentences?
Ellipsis occurs in many constructions in English.
Words considered non-vital are often omitted.
Here, the post-modifying adjectival prepositional phrase 'of various shapes' is seen to be ellipted by the omission of the preposition:
The use of a preposition is optional in the following sentences.
Prepositions are often omitted from temporal adverbials / whatever temporal 'additives' go with be:
I'd say it doesn't make sense for 'two hours' in the elided last example to be analysed as a direct object. There is a name for such DO-lookalikes, noun groups functioning adverbially and/or locatively / directionally / temporally: adverbial objectives.
The Rohirrim went north. Is John home yet? Today I came a different way. Elms stood either side of the street. Let's go some place. He lives next door.
Similarly, though the corresponding adjectival usage is, I feel, very rare, I'd class 'various shapes' in OP's elided example as an adjectival rather than a DO:
Though the 'adjectival objective' (don't quote me! - at least for a while) is very uncommon, the few examples that do exist seem to be increasing in popularity, as this Google Ngram seems to indicate. On the first page of Google hits for "are different shapes", 5 are obviously this usage as opposed to 2 which are obviously other constructions (following existential 'there' . . .).
In some cases, the 'of', complete, version, would sound ridiculous:
but obviously 'the same shape' / 'the same size' can't be taken as DOs.
I suppose that there is the slight possibility of confusion:
Version 1 ambiguously implies that skyscrapers is a subset of shapes, as in "squares, circles, triangles, X-skycrapers, and Y-skyscrapers, are all shapes."
Version 2 implies that skyscrapers resemble various shapes, not that skyscrapers are shapes.
As an example, the following sentence uses "of" to form an adjective clause.
1) Skyscrapers are of various shapes: using "of" in this sentence indicates that skyscrapers can take any shape. They can either be built in rectangle,square,pyramid,etc.
2) Skyscrapers are various shapes: Here not using "of" completely changes the meaning. This sentence says that skyscrapers are a part of different shapes. This sentence simply means just like ellipse,circle,pentagon are different shapes, skyscraper is also a shape.